I’ve been trying to Google this answer with no results. I keep on finding answers on how to make Netbeans run in a GTK skin …. this is NOT what I want.
I have a Java Swing application. I can preview it under GTK+, C/X Motif perfectly fine when I right click the JPanel Form –> Preview. However, whenever I try to run the program (build + run), the resulting GUI is a Java Swing look and feel.
How do I permanently enable GTK+ for this program?
You have to set the Look and Feel according to the native look and feel.
The following code must be ran when your app starts up.