Oktober 21, 2013

Awesome Window Manager (3.5.2) and Java 7 GUI Problem

Some complaints have been reported about Java GUI (AWT/Swing) that does not behave correctly under Java GUI. This problem come in the form of empty contents in Java GUI window and also some weird behaviour in Java GUI menu (wrong cursor pointer position, menu doesn't want to display its contents without click and hold mouse button).

This problem usually only happens in some exotic non-reparenting window manager such as awesome, dwm, subtle, and probably others. I use only awesome so this is my experience in awesome window manager. Even when since release 3.5.x, awesome has become a reparenting window manager, the weird behaviour above still exists (the menu problem). Uncommit source code is not an option for me.

If you experience this, there are two things that can be done:
  1. Change JDK from Oracle JDK to OpenJDK. I tested with OpenJDK 2.4.2 (IcedTea) and Awesome 3.5.2. This works very well without any extra steps.
  2. Use wmname and execute "wmname LG3D" from shell before running Java GUI application. This option is needed if we use Oracle JDK. I tested this with Oracle JDK 1.7.0_u45.
If you want to use OpenJDK and are so awfully lazy to compile it by yourself (just like myself), you may grab the latest binary for Linux in OpenJDK unofficial build. This works very well.

0 comments:

Poskan Komentar