Sunday, May 4, 2008

NetBeans IDE - Default Font Size

When we set out to search for the tips regarding how to change the default font and default look and feel for NetBeans IDE we get related information in seconds through any decent search engine.

Even then I am adding the same information again here with some fresh screenshots with the intension that,after this the user can find the information even sooner than I got it.

The default font size used by NetBeans IDE 6.1 is small and decent.

Some users may have different needs and want the font size to be bigger. NetBeans IDE has the facility to change the default font size through the configurations settings just like Look and feel setting.

In the netbeans.conf configuration file for NetBeans IDE which can be found in

C:\Program Files\NetBeans 6.1\etc\netbeans.conf

for the default Windows XP NetBeans IDE installation we can add the fontsize option to the netbeans_default_options string value

--fontsize 18

so make the configuration look like

netbeans_default_options="<old-options> --fontsize 18"

where <old-options> are the values already there which we will keep as they are and will add the new settings --fontsize.

This setting will make the default font size bigger and look like:

See how bigger the fonts can be seen now. Even the menus look like:


NetBeans IDE Hacks part 2 font-size
NetBeans IDE Hacks part 2 laf

with regards
Tushar Joshi, Nagpur


  1. I am working on Kubuntu with netbeans 6.1 and the font directive doesn't work.

  2. Oh, I am sorry. I have forgotten the double quotes to set at the end of the line.

  3. I want to share with you a plugin designed to edit startup settings like that, inside netbeans. No need to hand edit them, and worry about quotes.

  4. Hi,
    My name is James Branam and I'm the NetBeans Community Docs Manager. Your blog entry would make a fantastic tips & tricks entry for our Community Docs wiki ( Would you be willing to contribute it? If you need any help or have any questions, please contact me at I look forward to hearing from you.

  5. You can also create a shortcut with the fontsize option. I do it this way because I need to switch back and forth between font sizes because I use a projector for demonstrations.

    Right-click on the shortcut and change the target to:
    "C:\Program Files\NetBeans 6.1\bin\netbeans.exe" --fontsize 20

  6. Hi - this is useful.
    However, I would like to know how I can affect the actual font itself? I am running NetBeans over X from one Linux box to another and the resulting fonts are AWFUL. Really scratchy and hard to read.... How can I fix this?

  7. You may wish to try putting the following options to your "netbeans_default_options" variable in the netbeans.conf:

    "--laf com.jgoodies.looks.plastic.Plastic3DLookAndFeel --fontsize 18 -J-Dswing.aatext=true -J-DPlastic.controlFont="Verdana-plain-12" -J-DPlastic.menuFont="Verdana-plain-12" --cp:p /path/to/your/looks-2.2.0.jar"

    where looks-2.2.0.jar can be downloaded from (JAR found in JGoodies Looks ZIP file)

    This look&feel works pretty good on my Kubuntu box x64, 1920x1200, where other Swing LAFs such as Metal look really awful. (Verdana was optimal for me, however it's works just fine with any other font..)

  8. This advice does not change the font size of the text in the source editor window, which is where I really need it. Does anyone know how to do that?

  9. zubax, please change the editor fond from the NetBeans Tools > Options menu where you will find a Font and Colors section.

    with regards

  10. Hi, I'm working on Ubuntu with NetBeans 6.1. When I set the font size in the config only the Task List entries are affected. Anyone who knows why?

  11. Thank you so much! It really works and helped me.