There is a bug in Sun Java's Swing. It doesn't like certain window managers. Something about reparenting and not reparenting or something like that. Whatever. The point is, when trying to run a program you wrote using Swing, all you get is a big white nothing. Nothing draws in the window. Ahhh! What's wrong?! Yeah, I had some trouble with my Java class because of that one. Well, unfortunately, my favourite WM, Compiz/Beryl, is a problem child with this. However, there is an easy fix for it. Open your .bashrc (that in ~). If you don't know how, do this in the terminal:
vi ~/.bashrc
Add this line to it:
export AWT_TOOLKIT=MToolkit
Now try to run your program again. Now everything works. Yay!
Tested on OpenSuse 11.0 for SQuirrel SQL, Eclipse, Adempiere. For application that running from menu, you can try add line in file /etc/profile.
If you run the Java application from eclipse you also should add the parameter in Run menu | Java Application | [application name] | Environment and click New button and add
Variable Name: AWT_TOOLKIT
Value: MToolkit
NOW you can run your Java Application and use Desktop Effect (Compiz/Beryl/KDE Desktop Effect) on the same time. Cheers.
Source: ubuntulinuxtipstricks