views:

202

answers:

1

Is it possible to use bitmap (.fon) fonts in Netbeans? I have a font I particularly like (Raize font) and I don't see it anywhere on the list when I try to set it as the editor font. I can use it in other editors (Notepad++, pspad, visual c++ express etc). I can't use it in jedit either. Is this issue java related?

+2  A: 

According the Java API Specification for the java.awt.font package, which is used to add font support to Java, mentions that the following types of fonts are supported:

  • Type 1 fonts
  • Type 1 Multiple Master fonts
  • OpenType fonts
  • TrueType fonts

It appears that Microsoft bitmap fonts (.fon) are not supported, at least from the information I was able to find.

On a related note, to get a listing of all the Fonts which are installed in Java at the current time, one can make a call to GraphicsEnvironment.getAllFonts which will return a Font[] of all the fonts which can be used.

(Note that the GraphicsEnvironment class cannot be instantiated, but an instance can be obtained by the GraphicsEnvironment.getLocalGraphicsEnvironment method.)

coobird