Difference between revisions of "Font-FAQ"
(→What is this Font Fallback in OpenOffice.org 2: very short intro) |
|||
| Line 56: | Line 56: | ||
== How does Font Fallback work == | == 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. | ||
| + | |||
| + | '''''FIXME: (is this corerct?)''''' | ||
| + | |||
| + | OOo uses 2½ ways to find a suitable replacement: | ||
| + | |||
| + | * hard-coded list of fallback-fonts, from VCL.xcu (tried first) | ||
| + | if that fails: | ||
| + | * fallback by font-attributes (e.g. does it have CJK-characters, is it a Symbol-font) or style (serif/non-serif, proportional/non-proportional) | ||
| + | if that fails as well: | ||
| + | * use a default font | ||
| + | |||
== Where is the VCL.xcu in OpenOffice.org 2 == | == Where is the VCL.xcu in OpenOffice.org 2 == | ||
== How does the VCL.xcu work == | == How does the VCL.xcu work == | ||
Revision as of 22:23, 5 February 2006
This is the place where the work on the Font-FAQ for OOo 2.x (*nix) will happen... 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 OpenOffice.org 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
/opt/openoffice.org2.0/share/fonts/truetype/
- only for one single user of OOo, put the fonts into the directory
~/.openoffice.org2/user/fonts/
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 "OpenOffice.org Printer Administration" launcher in your desktop's menu, you can lauch it manually by executing
/opt/openoffice.org2.0/program/spadmin
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
~/.fonts/
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:
/etc/fonts/fonts.conf
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
/etc/fonts/local.conf
Let's say you decided to copy your fonts to the directory "/usr/local/share/myfonts", then you would add
<dir>/usr/local/share/myfonts</dir>
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 OpenOffice.org 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 http://corefonts.sourceforge.net/) 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:
- Gentium http://scripts.sil.org/gentium/
- Charis SIL http://scripts.sil.org/CharisSILFont or Doulos SIL http://scripts.sil.org/DoulosSILfont
- Galatia SIL http://scripts.sil.org/SILgrkuni
- Ezra SIL http://scripts.sil.org/EzraSIL_Home
Font Fallback
What is this Font Fallback in OpenOffice.org 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.
FIXME: (is this corerct?)
OOo uses 2½ ways to find a suitable replacement:
- hard-coded list of fallback-fonts, from VCL.xcu (tried first)
if that fails:
- fallback by font-attributes (e.g. does it have CJK-characters, is it a Symbol-font) or style (serif/non-serif, proportional/non-proportional)
if that fails as well:
- use a default font