From Apache OpenOffice Wiki
Revision as of 03:09, 3 April 2007 by Pmsyyz (Talk | contribs)

Jump to: navigation, search

This is the place where the work on the Font-FAQ for 2.x (*nix) will happen. Eventually it will replace the Font Trouble Shooting Guide prepared for OOo 1.x.

Feel free to fill out missing items, suggest new ones or correct mistakes and fix typos! If you have other suggestions, feel free to use the discussion-page.


Adding Fonts

How do I add fonts to 2 exclusively

There are two choices: Either for all users of OOo or only for one single user. If you intend to add the fonts...

  • for all users of OOo (but only within OOo, put the fonts into the directory
  • only for one single user of OOo, put the fonts into the directory

Instead of moving around the fonts manually, you can as well use the Printer Administration tool "spadmin" to install the fonts. If you cannot find a " Printer Administration" launcher in your desktop's menu, you can lauch it manually by executing


How do I add fonts to one user's desktop exclusively

When using fontconfig (which is the case for virtually every modern/current distribution out there), it is sufficient to place the fonts in the directory


If it doesn't exist already, create it. After adding or removing fonts, you should regererate the font-cache of that directory by running

fc-cache ~/.fonts/

How do I add fonts system wide

To make the fonts available system-wide, you have to add the fonts to a directory that is included in the global configuration file(s). Usually, you can find that file (fonts.conf) here:


As stated in the file itself, you should not modify that file. Instead, modify the file local.conf instead (create it in the same directory if it doesn't exist already). But have a look at the default one for the syntax, etc. If you don't want to add your font to one of the already listed directories, then just create the directory and add that one to


Let's say you decided to copy your fonts to the directory "/usr/local/share/myfonts", then you would add


to "/etc/fonts/local.conf"

As when adding the fonts for a single user only, you should create the font-cache to speed up font-lookup. Keeping with the example, you would run

fc-cache /usr/local/share/myfonts/

and you're done.

Where can I find fonts for 2

You can install a bunch of fonts using the wizard "File|Wizards → Install Fonts from the Web". This includes the "Core Fonts" from Microsoft (can be obtained from and many others.

If you're looking for fonts that cover a special language, I'm sure you'll find these links useful:

SIL has a couple of high-quality fonts as well, some of them are worth mentioning individually:

Font Fallback

What is this Font Fallback in 2

Font-Fallback kicks in whenever a font is requested that is not installed on the system. (Not installed means: not available to OOo).

OOo then tries to use a different font from the ones that OOo knows about that matches the requested one as close as possible.

How does Font Fallback work

For font-fallback to produce satisfying results, OOo somehow has to know about similarities of fonts. OOo must know that it can for example substitue Arial by Helvetica, but not with Comic Sans. This task is not as easy as it sounds, since there are very many fonts out there and OOo cannot know about all of them.

OOo uses several ways to find a suitable replacement:

  • font alias information provided by the system (e.g. from a fonts.dir file)
  • hard-coded list of fallback-fonts, from VCL.xcu (tried first)
  • alternative font name spellings
  • font-attributes (e.g. does it have CJK-characters, is it a Symbol-font) or style (serif/non-serif, proportional/non-proportional)

if all that fails as well:

  • use a default font

Where is the VCL.xcu in 2

You'll find the VCL.xcu in


(where "/opt/openoffice.org2.0/" is the default prefix of your installation)

How does the VCL.xcu work

The VCL.xcu includes both the default font-lists as well as the substitiution lists for fallback. The replacement-lists are in <node oor:name="FontSubstitutions">

Let's look at an example:

 [..lots of lines...]
 <node oor:name="FontSubstitutions">
     [...lots of lines...]
     <node oor:name="thorndale" oor:op="replace">
       <prop oor:name="SubstFonts">
       <prop oor:name="SubstFontsMS">
         <value>Times New Roman</value>
       <prop oor:name="SubstFontsPS">
       <prop oor:name="SubstFontsHTML">
       <prop oor:name="FontWeight">
       <prop oor:name="FontWidth">
       <prop oor:name="FontType">
     [..lots of lines...]

The first think you notice is that the fontnames listed in that section are all normalized, that means only lowercase letters with all numbers, spaces and other characters removed.

Second thing you notice is that there is not only one item with a list of replacement fonts, but also some other properties like SubstFontsMS, SubstFontsPS, SubstFontsHTML,...

So what does all these mean?

     <node oor:name="thorndale" oor:op="replace">

starts a new section, a new set of replacements for the font "Thorndale" the property

       <prop oor:name="SubstFonts">

describes the list of fonts that could be used instead of Thorndale, when Thorndale is not installed. In the example, this would include "Times New Roman", "Times", "Times Roman",... and finally "Palatino"

This list works the other way as well, so when you request e.g. Palatino but don't have that one installed, Thorndale is a possible replacement.

The other properties are optional and describe the font in more detail or for special circumstances. If you export the document to a Microsoft Office Format, the font given in

       <prop oor:name="SubstFontsMS">

(in this case "Times New Roman") would be specified as alternative in the document, if you print to a postscript printer, the font would be replaced by "Times" (most likely built-into the printer), when you export to HTML, it would be specified as a "serif" font, etc.

How can I configure 2 to perform a specific font substitution

If you're not happy with the replacement that OOo does, you can override the replacement and define a new one of your choice by using

Tools|Options → → Fonts

check "[x] Apply Replacement Table" and type in the name of the font you want to replace, and select a font that should be the replacement from the list.

check [x] always if you want the font to be replaced, even when it is installed check [x] screen if you want the font to be replaced on screen only

My document using a popular Windows font looks different than on Windows

Many systems have fonts that claim to look like Windows fonts (e.g. Arial, Times New Roman or Courier New ) but actually don't. It helps considerably to download and install the real fonts from Corefonts.

My document using TNR looks awful

How can I find out what font 2 really uses

Glyph Fallback

Some documents contain text that is not supported by the font specified for this text. This happens often when e.g. symbols or extended latin characters are involved. In order to display something reasonable the characters missing in the specified font are substituted by glyphs from other fonts.

My extended latin characters look different than the rest of my text

This happens when the font selected for text containing these extended latin characters doesn't support them. Guessing how these unsupported characters would have looked if the font's designer had added them is almost impossible. It is about as difficult as guessing how van Gogh would have painted an image of the Chinese wall.

I see "square boxes" instead of regular characters

The text contains characters that are not supported by the selected font. OOo also didn't find a suitable alternative font for these characters.

How can I find out if Glyph Fallback works in my 2

Select a Latin font e.g. Arial, then type something Chinese => the Chinese text looks readable even though Arial doesn't support any Chinese


What is freetype2

Is freetype2 supported in 2

What does freetype2 provide

Isn't Xorg rendering my fonts

What types of fonts are supported in 2

Are OTF fonts supported in 2

Not yet if they are postscript fonts (as virtually all of them are). The best you can do currently is to convert them from .otf to .ttf using something like fontforge The fontforge conversion is very good but not lossless with splines (the outlines of the font definition) being converted from cubic to quadratic splines. All the hinting, however, will be lost irrevocably. The automated hinting in fontforge for truetype .ttf files is bad and worse than not using it at all. What this means is that the converted fonts will be less legible at small sizes, but print quality will not be adversely affected except on low resolution printers. PDF and PS files generated for on screen viewing will be affected. The hinting from cubic splines is not compatible with ttf fonts so it can never be ported across to the quadratic form (which all ttf fonts must have).

If you have a small font less than 256 characters (so none of the complex Chinese, Japanese or Korean fonts) you can convert the font to a postscript type one file (.pfb) and retain the origianl hints with fontforge. This is a better choice than converting it to .ttf as the splines and hints remain unchanged (therefore the change is lossless). You cannot do this reliably with larger fonts (with more than 256 characters or glyphs). To do this, these are the steps:

If the opentype font is a cid keyed font (most new adobe fonts are), choose to flatten the cid map.

Re-encode it to ISO 8859-1.

Select all from the "edit" menu. Then in the "hints" menu select Don't Autohint.

Choose to generate a font as PS type 1 (binary).

Choose the options and make sure hints, flex hints and output afm are enabled.

Save the font and you can install it directly into the openoffice usable fonts by running the "spadmin" executable in the openoffice/program/ directory or globally by whatever other mechanism you would normally use.

Are none-Unicode fonts supported in 2


What is AntiAliasing

Is AntiAliasing supported in 2

What are the minimum system requirements to make AntiAliasing work

Where can I configure AntiAliasing in 2

What are embedded bitmaps in fonts

How can I tweak 2 to ignore embedded bitmaps


What is Fontconfig

Is Fontconfig supported in 2

What are the limitations in 2's Fontconfig support

What font is 2 using for the user interface

How can I change 2's user interface font

Go to Tools > Options then select the Fonts category. Check "Apply replacement table" and type in "Andale sans UI" in the "Font" box and select a font in the "Replace with" box. Click the check button and enable the "Always" checkbox. Click OK to finish.

The "Replace with" font you select has to support the locales selected for your system. You need to type in "Andale sans UI" because it is not selectable from the drop-down menu.

If I don't use Gnome 2.6, how can change the user interface font though

What is font aliasing

A few number of my fonts isn't antialiased, why

Which fonts on my desktop are provided by Fontconfig


Where are all the fonts installed on my system

How do I find out what fonts are installed on my system

What is a scalable font

A scalable font (also known as outline font) is a font where the individual characters are stored in vector format. The curves and lines that the glyph consists of are described relative to each other. This has the advantage that the font can be scaled to any fontsize without loss of quality.

The scaling has a minor disadvantage as well: At (very) small font-sizes or zoom-factors, the individual lines may not be drawn properly on a computer monitor because of the monitor's limited resolution. Since all is scaled down equally, thin lines can "disappear" because they will be scaled to be smaller than one pixel of your monitor. High-Quality fonts include hints for the rendering applications on what strokes/lines are important to recognize the character. The application now knows that it must display these lines and not make them disappear (by not scaling them down to a size smaller than a pixel of your monitor). This is called "hinting" (Postscript-fonts) or "instructing" (TrueType Fonts). A (rather technical) description is available at Fontforge. This is not a problem when printing, since printers usually operate at a much higher resolution than a computer monitor.

If you have the choice, you should prefer scalable fonts over bitmap fonts.

See also the article on wikipedia:

What is a bitmap font

A bitmap font (also known as raster font) is a font where the individual characters are stored by individual pixels - a "picture" of each character is stored. This has the big disadvantage that the font only looks good at the font-sizes it was designed for.

When you choose a different fontsize, the pixmaps need to be scaled, what leads to visible artifacts (jagged lines) - just the same as when you scale your bmp or jpeg Image. This effect is compensated to a small extend by the means of anti-aliasing, but especially at bigger fontsizes the fonts will not look as good as outline (scalable) fonts.

See also the wikipedia-article at

What is a proportional font

What is a fixed-width font

What are these long font names

Scrolling the font combo-box freezes 2

What can I do if scrolling the font combo-box crashes 2

Personal tools