Hmmm, wish I had done that before straining my eyes (even
with magnify!) to see the actual pixels .....
f_run ''
nl 3
+-------+---------+-----+---+
|f_close|f_g_paint|f_run|see|
+-------+---------+-----+---+
see ''
*
*
*
******
* *
* *
* *
*****
*
-----
So looks like I did get it "right" ...
Yes, my second (and subsequent) runs of your script
I used (essentially) the same commands as you find
convenient - but I avoid <cmd>w out of "finger memory"
(and I agree with Brian that I wish it closed the open
window) -- on the other hand, it is almost as easy to
save a script file by editing .jhistory ...
I will incorporate IFCONSOLE/IFJAVA into my version
verb - but it still begs how I can get output from
running "java -version" since that output is somewhere
lost in jw ... e.g.
2!:0 'java -version'
(empty result)
Any ideas how to improve that??
- joey
At 13:01 -0400 2006/08/24, Eric Iverson wrote:
The drawing you report looks wrong, but it also looks like it
possibly comes with some magnifier/eye/transcription problems.
Please run it again and cut/paste the result from the see verb. But
it does look like it is wrong the same way Oleg reports. This could
be a problem with Mac 10.4 vs 10.3 or with java 1.4 vs 1.5 or with
Jwdp vs the world. It is hard to see how any of the layers could get
something as simple as the upper left corner of a rectangle wrong. I
will dig deeper.
In the IDE I find: cut from email message, J cmd+n, cmd+v, cmd+w to
be acceptably convenient and it is now easy to edit, rerun, and to
save as a named script for future sessions.
Standard profile for both Jconsole and Jwd defines IFCONSOLE and
IFJAVA. You'd have to get the Java version from java -version.
----- Original Message ----- From: "Joey K Tuttle" <[EMAIL PROTECTED]>
To: "Beta forum" <[email protected]>
Sent: Thursday, August 24, 2006 12:37 PM
Subject: Re: [Jbeta] mac rectangle location
Eric,
On my G5 iMac (using ColorSynch Utility >> Calculate >>
magnifier - thanks for motivating me to find/use that
interesting tool!) putting in your script (and being
reminded how tedious using IDE is compared to just cut/
paste from an email into jconsole... ;) -
version ''
Binary: j601binubeta_darwin
Library: j601libubeta
Help: j601hlpubeta
Engine: j601/beta/2006-08-16/22:30
ProductName: Mac OS X
ProductVersion: 10.4.7
BuildVersion: 8J135
java version "1.5.0_06"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.5.0_06-112)
Java HotSpot(TM) Client VM (build 1.5.0_06-64, mixed mode, sharing)
f_run ''
NB. creates a graphics pane with (only) the following pixels
*
*
*
******
* *
* *
* *
*****
*
------
Even with the magnify tool, it is tricky to see just how
many pixels are involved. The above starts in the upper
left most corner of the graphics window and I'm pretty
sure (99%) about the number/location of pixels - but even
more sure they don't look like your display below...
The java version information above was pasted in because
when I tried to add that to my "version" verb, it doesn't
work from a jw session - I think because the result from
"java -version" is standard error output, and that doesn't
get passed back to my session in jw.
It (standard error) does get passed back in my normal
jconsole environment - so yet another reason to prefer
that...
- joey
At 09:50 -0400 2006/08/24, Eric Iverson wrote:
Oleg,
Here is a slightly modified drawing and a see verb. On my systems:
jwdw, jwdp-windows, jwdp-linux, and jwdp-mac the see result is
identical and is as follows:
*
*
*
** *
*****
* *
* *
* *
*****
If displayed with a fixed pitch font the right side of the
rectangle lines up and is under the pixel at 4 3. The results are
correct and identical on all my platforms, including the Mac.
Please try it on your Mac and confirm that you get a different
result. Results from other Mac users appreciated.
My Mac is: 10.3.2 with java -version is 1.4.2_03-117.1.
*** glrect_location.ijs
coinsert 'jgl2' [ require 'gl2'
f_run=: 3 : 0
wd 'pc f;xywh 0 0 50 50;cc g isigraph;pas 0 0;'
NB. initialize form here
wd 'pshow;'
)
f_close=: wd bind 'pclose'
f_g_paint=: 3 : 0
glpixel 0 0,1 1,2 2,3 3,4 3,8 3,:4 8
glrect 4 4 5 5
)
see=: 3 : 0
' *'{~0=10 10$glqpixels 0 0 10 10
)
***
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm