Bug 283 : First line of the exported applet not displayed on Java 1.4 and later on Mac OS X
Last modified: 2010-06-05 09:29




Status:
RESOLVED
Resolution:
WONTFIX -
Priority:
P3
Severity:
normal

 

Reporter:
pvk
Assigned To:
fry

Attachment Type Created Size Actions
Example of good behaviour of the applet on Opera Mac image/png 2006-02-05 18:54 16.50 KB
Example of bad display of the applet on Safari MacOSX image/png 2006-02-05 18:55 41.21 KB
Screenshot Safari with smooth() image/png 2006-04-10 09:55 10.27 KB
Screenshot Opera using noSmooth() image/png 2006-04-10 09:56 4.51 KB
Screenshot Processing 99 using noSmooth() image/png 2006-04-10 10:00 17.05 KB

Description:   Opened: 2006-02-05 18:53
When displaying an exported java applet, the first horizontal line of the applet is not displayed
in MacOSX Safari.
To illustrate the issue, I use the following applet :
http://escience.anu.edu.au/lecture/comp2750/lab/lab1/lab1_4/applet/index.html
This is an applet produced with processing.org
The applet is supposed to draw 4 squares in each corner of the applet. Because the shape of
the squares is in bright red, it is efficient to illustrate the issue
The first line appears properly on Opera Mac, IE PC, processing.org IDE Mac, Firefox PC, but
does not appear on Safari (2.0.3), Firefox Mac, and Appletviewer.
I am using the version 0103 Mac of processing.org IDE to produce the applet
Additional Comment #1 From pvk 2006-02-05 18:54
edit]
Example of good behaviour of the applet
Additional Comment #2 From pvk 2006-02-05 18:55
edit]
Example of bad display of the applet on Safari MacOSX
Additional Comment #3 From fjen 2006-04-10 09:54
i don't think this is a browser problem in the first place.

opera by default uses smooth drawing. if you look closely at the first two attachments you will
find that the lines at the top and left border are only half as thick as the others.

add "smooth()" / "noSmooth()" to the code and you will have the same results on both
browsers (see attachments).

so i think this is a problem in processing when drawing in P2D with noSmooth() / aliasing,
since a rect starting at (0,0) actually draws it's border at (-1,-1) ...
Additional Comment #4 From fjen 2006-04-10 09:55
edit]
Screenshot Safari with smooth()

adding smooth() to the code shows same result in safari as in opera.
Additional Comment #5 From fjen 2006-04-10 09:56
edit]
Screenshot Opera using noSmooth()

same problem as in safari when using noSmooth()
Additional Comment #6 From fjen 2006-04-10 10:00
edit]
Screenshot Processing 99 using noSmooth()

I'm quite sure it's not a browser-(html)-bug since the same problem pops up
inside Processing (99).

As noted above i think it's a (aliasing?) problem with borders being drawn at
(-1,-1) instead of (0,0).
Additional Comment #7 From REAS 2006-09-25 14:33
I'm reassigning this to fry. I'm wondering if it's a Processing problem or
a Java2D problem.
Additional Comment #8 From fry 2006-09-25 17:21
the differences between the different browsers on the mac are that some are
using Java 1.3, others are using Java 1.4 or 1.5.

it appears that the problem started with Java 1.4 on the mac and continues
to more recent reelases. i'm not sure whether it's another rounding error
in how Java2D handles things like bug #203. or it may be similar to the bug
seen on linux where the drawing surface is sized incorrectly, bug #341.
Additional Comment #9 From fry 2008-08-09 11:19
Can someone check to see if this persists in release 0135 and/or 0143?
Additional Comment #10 From fry 2010-06-05 09:29
assuming this is either fixed, out of our control, or at least no longer
relevant since we're not supporting java 1.4 anymore.