PDA

View Full Version : netbeans gui designer



Revvion
November 11th, 2008, 08:55 PM
Oke so I am using netbeans to create a java applet. When i design the applet in netbeans with the gui desigener i see it with my system theme. However when running the applet you just see it with the default metal theme, now my question is how do i change the look in the netbeans gui designer so it also displays it with the metal theme.

loell
November 12th, 2008, 12:21 AM
if i'm not mistaken java applets do not inherit desktop environment themes on any platform. it has always been that dull silver/grey look.

tinny
November 12th, 2008, 10:32 AM
Oke so I am using netbeans to create a java applet. When i design the applet in netbeans with the gui desigener i see it with my system theme. However when running the applet you just see it with the default metal theme, now my question is how do i change the look in the netbeans gui designer so it also displays it with the metal theme.

Java applets just leverage off Swing. I would suggest you look into swing look and feels.

To give your swing applications a "native" look and feel set the look and feel like so before initializing your UI (maybe in your main method)


UIManager.setLookAndFeel(UIManager.getSystemLookAn dFeelClassName());