views:

70

answers:

3

Hello.

I'm creating Java Web Applet in NetBeans and I want my final application to have design named "Metal". I can set it, it's OK. But when I'm editing the GUI using "NetBeans GUI editor" I must work with typical Windows design. Is it possible to use "Metal" skin in editor too? Each design has different sizes of buttons, fonts etc.. So I'd love to see the final layout during editing. Not only after compiling.

I know that I can right-click and select "Design preview / Metal" but I do not want this. For ilustration I'm attaching an image:

http://racky.wz.cz/netbeansgui.bmp

I saw this question in a few forums, but nobody understood it well (and nobody answered), so I'm asking my own question.

A: 

Try configuring Netbeans to use the Metal look and feel by editing netbeans.conf.

netbeans_default_options="... --laf javax.swing.plaf.metal.MetalLookAndFeel"

Note: After a normal Netbeans installation there's already a netbeans_default_options setting in the configuration file. Be careful not delete them unless you know what you are doing. Just append the --laf option.

DR
Thanks, it worked. But <snip> caused an error message, so I added to "netbeans_default_options" only this: "--laf javax.swing.plaf.metal.MetalLookAndFeel". Side effect was, that whole NetBeans now have Metal design. But I like it, so why not.
Racky
The <snip> means that I cut away all the other options normally added to that line.
DR
A: 

Thanks, it worked. But <snip> caused an error message, so I added to

"netbeans_default_options" only this:

"--laf javax.swing.plaf.metal.MetalLookAndFeel"

Side effect was, that whole NetBeans now have Metal design. But I like it, so why not.

Racky
See my comment, I just wrote `snip` to say that there might be other parameters which I didn't quote in my answer to keep it short
DR
A: 

1) This question was once answered at http://stackoverflow.com/questions/231738/force-look-and-feel-on-netbeans-6-5 Please take a look there also.

2) Some years ago I have written a detailed tutorial for Look and Feel changes in NetBeans. Please also have a look at http://netbeanside61.blogspot.com/2008/05/netbeans-ide-look-and-feel.html

with regards
Tushar Joshi, Nagpur

Tushar Joshi