Programmatic control of console area

2 views
Skip to first unread message

Michael Dalby

unread,
Jun 20, 2008, 4:18:40 PM6/20/08
to guess-discuss
Hi Eytan,

Is there a simple way, programmatically in scripts (not just by mouse
manipulation), to control the height of the console area (e.g., on
startup)? In searching the guess class in guess.jar, it looks as if it
is called tpjc, but is not available for manipulation -- but maybe
that's wrong or I've missed something.

The idea would not only to be more convenient on startup but also to
accommodate various sizes of charts and button arrangements.

Or, for that matter, is there a complicated way?

Thanks.

Michael

Eytan Adar

unread,
Jun 20, 2008, 6:08:37 PM6/20/08
to guess-...@googlegroups.com
Easy enough, and I had a couple of bugs that I was just fixing for release...
 
 
and you can do:
 
ui.setHDividerLocation(...)
ui.setVDividerLocation(...)
and
 
ui.getHDividerLocation()
ui.getVDividerLocation()
to set and get as appropriate...
 
-Eytan

Michael Dalby

unread,
Jun 21, 2008, 4:15:32 PM6/21/08
to guess-discuss
Thank you, Eytan! Eager to use...

I've encountered a problem, however, in installing the revision of the
of guess.jar. Namely, after substitution of the downloaded (new)
guess.jar file in place of the installed (old) one, I get "Exception
in thread "main" java.lang.UnsupportedClassVersionError: Bad version
number in .class file" when the new guess.jar is substituted into the
current guess environment. As far as I know there is no difference in
the dispatch from guess.sh.

In the new download, the guess.jar/com/hp/hpl/guess/ Version.class
reads

public static String MAJOR_VERSION = "1.0.4beta";
public static String MINOR_VERSION = "20080620-0305";

I have been running the download (8/13/07) version of the entire
program.

So the conflict makes sense -- the version I was running, in the
analogous class, read

public static String MAJOR_VERSION = "1.0.3beta";
public static String MINOR_VERSION = "20070813-1150";

This certainly looks like the source of the exception. However, just
to check I downloaded the referenced guess install from the website
and from Sourceforge (which still downloads 1.0.3 / 20070813-1150) and
tried installing the revised guess.jar there, with similar results.

Is there a fix for this, or can you steer me to what I'm doing wrong
-- e.g., to update the MAJOR_VERSION? Thanks.

Michael

On Jun 20, 3:08 pm, "Eytan Adar" <eytana...@gmail.com> wrote:
> Easy enough, and I had a couple of bugs that I was just fixing for
> release...
>
> download this:http://graphexploration.cond.org/guess.jar
>
> and you can do:
>
> ui.setHDividerLocation(...)
> ui.setVDividerLocation(...)
> and
>
> ui.getHDividerLocation()
> ui.getVDividerLocation()
> to set and get as appropriate...
>
> -Eytan
>
> On Fri, Jun 20, 2008 at 1:18 PM, Michael Dalby <michaeltda...@gmail.com>

Eytan Adar

unread,
Jun 21, 2008, 7:40:00 PM6/21/08
to guess-...@googlegroups.com
That error is actually a java version complaint.  I compiled the jar file using the latest 1.6 jdk I think (it's at work, so I don't remember for sure).  What version are you using?  (you can type java -version to find out).  I can probably recompile under 1.5, but if you're willing to upgrade your java, that might fix it.
 
-Eytan

Michael Dalby

unread,
Jun 22, 2008, 10:22:36 AM6/22/08
to guess-discuss
Aha! I'm using Mac OS 10.5.2, on a Power Mac G5 (a PPC). The jdk 1.6
is notoriously not yet available, to the best of my ability to track
down, for the PPC Mac. For those GUESS faithful Mac users who do have
Intel (i.e., newer) Macs, look at http://rorblog.techcfl.com/2008/02/26/installing-the-jdk-16-on-mac-os-x/
for a way to install 1.6. A bit involved, but the instructions on that
page are very clear.

I would ordinarily upgrade the Java in a snap, but implication is a
new machine. If you can recompile an alternate version under 1.5, I'd
be very grateful -- and in return happy to try to answer questions
from people on Macs. I've run into every imaginable issue (or so I
thought) using GUESS on Macs.

Best regards and thanks,

Michael

On Jun 21, 4:40 pm, "Eytan Adar" <eytana...@gmail.com> wrote:
> That error is actually a java version complaint.  I compiled the jar file
> using the latest 1.6 jdk I think (it's at work, so I don't remember for
> sure).  What version are you using?  (you can type java -version to find
> out).  I can probably recompile under 1.5, but if you're willing to upgrade
> your java, that might fix it.
>
> -Eytan
>
> On Sat, Jun 21, 2008 at 1:15 PM, Michael Dalby <michaeltda...@gmail.com>

Eytan Adar

unread,
Jun 22, 2008, 1:13:29 PM6/22/08
to guess-...@googlegroups.com
 
Sorry that it's such a hassle on the Mac

Michael Dalby

unread,
Jun 22, 2008, 7:50:27 PM6/22/08
to guess-discuss
Thanks a million. That recompilation really, really helps.

Three of the console sizing commands work fine, but
ui.getVDividerLocation() returns

Traceback (innermost last):
File "<string>", line 1, in ?
AttributeError: getVDividerLocation

I can live with it, since the "sets" work fine, but you might want to
know about it.

Thanks again.

Michael

On Jun 22, 10:13 am, "Eytan Adar" <eytana...@gmail.com> wrote:
> try it now...http://graphexploration.cond.org/guess.jar
>
> Sorry that it's such a hassle on the Mac
>
> On Sun, Jun 22, 2008 at 7:22 AM, Michael Dalby <michaeltda...@gmail.com>
Reply all
Reply to author
Forward
0 new messages