A couple of months back I tried out a very nice opengl based x server called XGL. I followed the instructions outlined at http://www.ubuntuforums.org/showthread.php?t=131267 and had it working in record time. However there was one catch. Java applications would not render properly. For instance when I would start intelliJ Idea all the dialogs , menu items etc would display properly but the main screen would remain gray. I tried playing around with some vm switches for a while but eventually gave up and dismissed XGL for the time beeing. Last week a coworker brought up xgl again and it triggered me to take another look. As it turns out there is a bug in the sun jvm that causes this behaviour. The issue is described in this post and one of the developers was kind enough to provide a workaround. So I applied the patch, rebuild the deb file and it worked. In case anyone is interested i uploaded the patched deb here or if you feel like building it yourself these are the basic steps

sudo apt-get install dpkg-dev build-essential
sudo apt-get source xserver-xgl
sudo apt-get build-dep xserver-xgl
cd xserver-xgl-7.0.0
patch -p0 < ~/xgl-java-wmhack.bin dpkg-buildpackage -b -uc cd.. dpkg -i xserver-xgl_7.0.0-0ubuntu4_i386.deb