18

Is it possible to change the default font in netbeans? The documentation says:

The font Monospaced is maped to different fonts on different systems. On Windows it is mapped to "Courier ", on Linux it is mapped to "Lucida Typewriter".

http://ui.netbeans.org/docs/ui/editor_fonts_colors/Editor_fonts_and_colors.htm

I'm on windows and want to map Monospaced font to 'Consolas' instead of 'Courier'.

P.S. I know that fonts can easily be changed from options, but when I change it in this way, I can no longer use unicode characters. Guess I need to do what they call 'mapping' the monospaced font to other font.

King Julien
  • 10,981
  • 24
  • 94
  • 132

6 Answers6

12

Tools > Options > Fonts and Colors

Set the category "Default", and to the right of that, the font you want to use.

If this does not fix it, try adding:

--laf Nimbus -J-Dswing.aatext=true -J-Dawt.useSystemAAFontSettings=lcd

or

-J-Dswing.aatext=true -J-Dawt.useSystemAAFontSettings=lcd --laf Metal

to the file : netbeans.conf. You can find it in $NETBEANS_HOME/etc/ folder. Make your application font smaller from system preferences.

TT--
  • 2,956
  • 1
  • 27
  • 46
Andy Dingfelder
  • 2,090
  • 2
  • 18
  • 30
  • Set my default font to consolas, tried to add both of the configuration lines but still when I try to type using unicode characters I get some unknown symbols instead... – King Julien Sep 01 '12 at 13:22
7

To change the font size outside of the editor you can configure by editing the Net Beans conf file, you can find it here: C:\Program Files\NetBeans 8.0.2\etc\netbeans.conf

Then edit this line: netbeans_default_options="..."

by adding this at the end:

--fontsize 18

I hope it helps :-)

Roberto Rodriguez
  • 3,179
  • 32
  • 31
3

Life becomes more easier now. Just from Tools menu choose Options and then follow steps on the following screen shot and take care with step 3 and 4 which they are making the default font for all languages:

enter image description here

SaidbakR
  • 13,303
  • 20
  • 101
  • 195
2

I have a NetBeans plugin called 'UI-Editor' which allows you to customize virtually any Swing property, including font sizes, colors, and types. Go to Tools->Plugins and search for 'UI-Editor' or go here: http://plugins.netbeans.org/plugin/55618/?show=true

jdb1015
  • 127
  • 6
0

also don't not forget to change the font to the one that support Arabic like Arial for example i am not sure of some one mention that i just tried it

isslam akkilah
  • 418
  • 1
  • 11
  • 23
-2

As far as I can tell there's no way to do this. jEdit (http://jedit.org) also uses Swing and DOES do font substitution for all fonts - there's a "automatic font substitution" checkbox in Global Options > Text Area, along with a list of preferred fonts. But jEdit is otherwise not as capable as Netbeans.

Bink
  • 171
  • 4