I work on a site to analyze and visualize data. For one part I built an applet to display a summary of data. The user needed to be able to do a lot of interaction with the display so I used an applet. Unfortunately no one had tried it with Mac OS X 10.7 or 10.8 until recently and we realized there is a problem.
If run on Mac OS X with the Oracle JRE 1.7.0_x plugin the top part of the applet when it loads scrambles the display. I seems to grab the desktop or parts of other open applications and scramble it(usually inverting it as well) The GUI for the applet is offset a few inches below the mess it creates at the top.
Once it loads I can move the mouse over the scrambled mess and the gui below that reacts. So I can see a checkbox change indicating the mouse is over it even though its displayed 2 inches below the mouse and I can check it and the GUI below that reacts appropriately, so it seems to work but the display is completely messed up. I'm happy to post code, but it seems like it has to be something with the new Oracle JRE for Mac 10.7+. Has anyone seen this or have suggestions.
I've tried launching from an applet tag instead of the deploy script and jnlp file. It doesn't matter if I'm in Firefox or Safari. It works with 1.7 on Windows without any issue and runs on Mac 10.6 just fine with Apple JRE 1.6.
If you want to see what it does you can go to http://phenogen.ucdenver.pvt/PhenoGen and click on Detailed Transcription Information, then enter "agt" for the gene and select Rattus Norvegicus and click Get Transcription Details. An image will load and right below that the applet loads.
Any help is greatly appreciated I've spent about a day and a half trying to figure out what is going on and so far all I can tell is that it seems to be isolated to Oracle JRE for Mac.
This affects our applet too and I have been investigating. I have put a summary of my findings on my website here: http://www.chrisnewland.com/applet-graphics-corruption-in-java-7-update-10-on-mac-osx-309
It is related to the size of the applet and is 100% reproducable. I have submitted a bug report but that is still in review (ID 2406665).
It looks like Java 7 update 10 broke the way memory is used for double buffering in applets and if the applet is bigger than the browser height then this corruption occurs.
Thank you. That helps a lot. Since update 9 seemed to cause problems with webstart I had been focusing on trying different methods to start it. It never occurred to me to try changing the size. Although with a smaller size I'm still getting random graphics artifacts(short red lines and dots through out as well as combo boxes that don't show up and tabs where the text shows but not the tab), but it still requires scrolling so I'll try opening it in a page by itself to avoid any scrolling and see if it looks more normal. This applet is using double buffering because its drawing genes, heat maps, sequences that users can zoom in and out and navigate so it just didn't look great without double buffering.
Everything that you describe seems to fit with what I'm seeing. Thank you for figuring it out and submitting a bug report. I hope they'll fix it soon.
I'm seeing the exact the same issue. If the applet is larger than the browser screen the content gets shifted down by about 400px and the top is random garbage from the video buffer. Some of our users found that using the Zoom In/Zoom Out commands can get the applet to render at a size that is usable. Obviously it's not ideal.
We've seen it on 10.8.2 using Java 7u10 and 7u11. I tried disabling double buffering using the RepaintManager on the JApplet but it doesn't seem to help.
I got around the problem by shrinking the size of the applet and adding a scroll bar (i.e. a JScrollPane). It looks pretty ugly but it is better than an unusable applet.
I think the problem is related to the Java plugin loading animation. If you clear your cache and go to a page with an applet, you can reject the applet (don't allow it to run) and you'll see a blank square at the top and the rejected applet under it. It looks like the blank square is where the loading animation should have been but for some reason it isn't rendering (or rendering random garbage from the video buffer) if the applet would scroll off the bottom of the browser window.
It appears to be related to the applet size parameters.
If you applet is less than 1152x864 I do not see the corruption. Once you pass some magic size, it really looks like the top or origina of the back buffer is pointing to the wrong spot (some bad pointer math).
For me some of the corruption includes the data from the java console I have up trying to debug. The bottom of the applet is also clipped. I have not been able to verify the size of how it is clipped but it is that fact plus the corruption at the top that makes me think the back buffer pointer is just wrong.
I have the Java 7 update 17 and I still see this issue. I have reduced the size of the applet and it seems to fix the issue. I have set the size of the applet to 800 and it works. After reading the previous posts I have no idea why setting to 800 worked.