-
Why a font editor, aren't there enough fonts
already?
-
Well... no. Otherwise I wouldn't be writing this.
-
There are lots of latin fonts. There are far fewer greek, cyrillic, indic,
thai, chinese, japanese, korean, unicode...
-
Researchers into old writing systems often need to design their own fonts
-
Even for latin, traditionally each new style of art and architecture has
an associated style of fonts. New fonts are always being created to reflect
the esthetics of the times.
-
Computer font technology is constantly changing. A font-format that was useful
10 years ago may not be so now.
-
Even if you are satisfied with the fonts that do exist they may not be complete
-
Missing ligatures
-
Missing accented glyphs
-
No matching cyrillic or greek glyphs
-
Everybody wants a font of his/her own handwriting.
-
Playing with fonts is fun.
FontForge has uses beyond simply creating and modifying fonts. It can convert
from one format to another. It can extract information from the font file.
Or it can simply show you what the font looks like without having to install
it.
-
Why did I write it?
-
-
Because it was fun
-
Because MacroMedia stopped development on Fontographer, and Fontographer
was lacking features that I wanted.
-
Why do I give it away?
-
-
Because I approve of free software and hope that the availability of good
products on a good operating system will encourage people not to use proprietary
systems.
-
Because programming is a lot more fun than marketing and giving things away
is easier than selling them.
-
Because I'd have to spend more time doing QA if I sold it
-
Why is FontForge based on a non-standard widget
set?
-
I wanted a widget set that would handle Unicode reasonably well. In particular
I thought support for bidi text was important for hebrew and arabic typography.
As I was unaware of any widget sets that did that, I wrote my own.
I also wanted a widget set where I could actually figure out whether the
checkbox was checked or not checked. In far too many cases my eyes can't
work out which is which...
-
Why isn't FontForge written in C++ (or Why C++ is
not my favorite language)?
-
I've been a little surprised to be asked this question, I had not realized
my choice of language needed justification, but it appears to do so...
Basically because I don't find object-oriented practices helpful in most
cases, and because I find C++ far too complex and badly designed, and because
I can't debug it easily.
-
I grew up with SIMULA and dabbled with SmallTalk and found after a few years
that there were very few problems where an object oriented approach seemed
natural to me. In most cases it just seemed to impose unneeded complexities
on the problem.
-
The semantics of a C++ program cannot be specified. The compiler is free
to generate temporaries as it wishes. In C this is not a problem, but in
C++ the creation of a temporary can involve calling a constructor and a
destructor which may have untold side-effects. I find this frightening.
-
The order of execution of external constructors is unspecified. I have seen
many inexplicable bugs caused by this
-
I find it extremely difficult to debug C++. Stepping through a statement
often involves many unexpected procedure calls (some of which are inlined
and not obvious). This distracts from my main purpose in debugging.
-
Finally I find the language badly specified and too complex. Its various
concepts do not fit well together. Each compiler seems to do things slightly
differently.
I first met C++ in about 1981 when it was called C with Classes. I wrote
the C++ front end for Green Hills Software's compiler suite from 1987 to
1994 and I tracked each new version of the language from 1.1 to ANSI.
Each version added new features which did not sit well with the old ones.
Each version was badly specified. The reference implementation was wildly
different from the standard. For example the behavior of virtual functions
inside constructors was not specified until version 2 of the language and
since this behavior was different from naive expectations this caused bugs.
My favorite confusion occurred in (I think it was) the version 2.1 specification
where on one page, within a few paragraphs, the following two sentences occurred:
"Unions may contain member functions." and "Unions may not contain member
functions.".
The above are my personal opinions based on my experience and are explain
why I do not use C++. Your opinions may differ, few people have spent
5 years writing C++ compilers.
-
Is it legal to modify a font? Is it ethical?
-
Legal matters vary from country to country (and perhaps within countries).
You really should consult a lawyer for a definitive answer. Here are some
guide lines:
Look at the license agreement you received with the font and see what it
has to say on this issue.
TrueType (and OpenType and potentially CID-keyed fonts) have a field in the
OS/2 table called FSType which allows the font designer to place restrictions
on what other people can do with the font. If this field prohibits modification
fontforge will ask you to make sure you have an agreement with the font designer
which supersedes this field.
My understanding of US law (but check with a lawyer before relying on this)
is that:
-
There is no legal protection for font designs. So legally in the US glyph
images may be traced. Obviously this is not ethical if the font designer
is currently alive.
-
Font programs (such as a postscript or truetype font file, but not a bitmap
font file) may be copyrighted.
-
Font names may be trademarked.
My understanding is that in most European countries there are laws against
copying the design (the shape) of a font.
I would welcome any additions or corrections here, as well as info on the
laws governing fonts in other countries.
-
What is a 12 point font? (What measurement
of the font determines the point size?)
-
A font is
12 points high if the distance between the baselines of two adjacent lines
of (unleaded) text is 12 points.
The pointsize is not based on the sizes of any of the glyphs of the font.
Back when fonts were made out of metal, the pointsize of the font was the
height of the metal slugs used for that font.
In some sense this is not a very good measure of the size of a font (some
fonts may allow more room for accents or ascenders or descenders than others
meaning that the height of the actual glyphs will be smaller).
There is also a measurement scheme based on the x-height of the glyphs.
In England and the US a point has traditionally meant the pica point (1/72.27th
of an inch), while in Europe the point has been the didot point (1/67.54th
of an inch). The Europeans have a slightly larger point, but the glyphs of
English and European fonts appear the same size. English does not use accents
(except in very rare cases) while most European languages do, and the slight
increase in the size of the point allows more room for accents.
(Of course now most Europeans are probably forced to use the pica point by
their desktop software, while must computer fonts now contain accented glyphs,
so the distinction and the reason for it may have vanished).
-
How do I set the line spacing on a font?
-
It depends on the kind of font you are generating, the operating system under
which you are running, and luck.
-
For Type1 fonts there is no way to set the line spacing. Applications will
often take the values specified in the font's bounding box and use those
to set the line spacing. This is a really bad idea on their part, but it
is common practice.
-
For True/Open Type fonts the answer is complicated.
-
How do I install the fonts once I've made
them?
-
Well it rather depends on what system you are working on, and what type of
font you've got:
-
Unix & X (but not KDE)
-
I'd suggest that you look at the
linux
font HOWTO file, and the
font
deuglification HOWTO as good starting points. But I'll run over the
highlights
Essentially you designate one (or several) directories as a "font directory".
You move your fonts to that directory. You build up certain data structures
that X needs, and you tell X to include this directory in your font path.
Sadly different versions of X and the X font server use slightly different
conventions. You may need to alter these procedures a bit.
For example, if you want to install a bdf font called frabnuts-13.bdf
then you might:
$ mkdir my_fonts
$ mv frabnuts-13.bdf my_fonts
$ cd my_fonts
$ bdftopcf frabnuts-13.bdf >frabnuts-13.pcf
$ mkfontdir
$ xset fp+ `pwd`
and your fonts should be installed. After that, whenever you start X you
need to remind it of where your fonts live, so you should add
$ xset fp+ /home/me/my_fonts
to your .xsession (or equivalent).
If you want to install postscript fonts
You should generate them as postscript binary (.pfb) files, then move both
the .pfb and the .afm file into (one of) your font directory(ies) and run
type1inst
in it.
type1inst will probably complain that your font doesn't have a foundry and
will probably get the encoding wrong. You can either:
-
Ignore it and nothing bad will happen
-
Manually edit fonts.scale after running type1inst to fix these entries
-
Make your font's Copyright be reasonable, and then edit type1inst and add
your foundry (directions for this are in type1inst itself)
If you want to install truetype fonts
You move the .ttf file into your font directory and run mkttfdir and
mkfontdir.
(mkttfdir
has a small problem with fonts created by FontForge, it will almost invariably
complain that it doesn't recognize the foundry. You can safely ignore this,
but if it bothers you then add a line to ttmkfdir.c at 936
{ "PFED", "FontForge"
},
Some versions of X (ie, those shipped by redhat) rely on the x font server
to do font work rather than the X server itself. You may need to use chkfontpath
to add your new directory to the font server's font path (rather than xset
fp).
You may also need to insure that the font directory (and all its parent
directories) are readable to world. (the font server runs as a non-privileged
user)
I haven't seen anything that says X supports opentype fonts yet,
but since freetype does (and I think X's rasterizer uses freetype) then X
might support them too. Installing them will require manual editing of
fonts.scale though (mkttfdir uses freetype1 which doesn't support otf files).
That sounds really confusing. I apologize, I'm not a good writer and there
are too many choices in configuring X...
-
KDE
-
(I don't know KDE very well, so take my experience with a grain of salt)
Under KDE there is a tool called
kfontinst
which is supposed to do all the configuration work for you. I was only able
to get it to work as root and had to reconfigure my system to follow its
conventions, but once that was done it installed X fonts quite handily. I
never did figure out how to get it to install ghostview fonts. (I experimented
with version 0.9.2)
-
TeX
-
TeX has its own (platform independent) system for installing fonts. I've
described my experiences so far
elsewhere in this
document.
-
Windows
-
You install truetype fonts on windows by dropping them into the \Windows\Fonts
directory on your machine. You may need to set the execute permission bit
on the font before installing it.
Do NOT generate the font directly into
\Windows\Fonts, this doesn't seem to work (at least on under
my XP machine). You must generate the font into another directory and drag
& drop it to \Windows\Fonts .
If you want to use type1 fonts you will need to install adobe type manager
and follow its instructions.
If you want to install opentype fonts then on old systems (before windows
2000, I think) you need to install ATM, on more recent systems opentype should
work the same way truetype does.
-
Macintosh OS 9
-
Oh dear. The mac sticks fonts into resource forks and wraps them up in its
own headers. Mac fonts aren't compatible with anybody else's. FontForge can
create a resource fork if it wraps the font up in a macbinary encoding. See
the following question for more information.
I've also written some
utilities designed to convert from one format to another and they may
prove useful.
University
of Oregon has some links that might be helpful.
Once you've converted your fonts you just drop them into the System Folder
and they should be available after that.
-
Macintosh OS X
-
On OS/X fonts should be placed either in the top-level Library/Fonts directory
(By default
/Mac OS X/Library/Fonts/
), in the System/Library/Fonts
directory, or in the user's appropriate fonts sub-directory
(~/Library/Fonts
).
Either a resource font (unwrapped from its macbinary wrapper) or a dfont
may be used. You can also use straight ttf and otf files (ie. the same file
you might use on Unix or MS).
As far as I can tell the old NFNT bitmap resources do not work on my OS 10.2.
If you want to use bitmap fonts wrap them up in a ttf file or an sfnt. However
if you want to use a Type1 resource font, you must generate a (useless) bitmap
font and install them both.
-
Why won't FontForge's fonts install on some
MS Windows machines?
-
Do NOT generate a font directly
into the \windows\fonts directory. Generate the font into a different directory
and then use windows drag and drop to install the font. (Windows appears
to do magic when it moves the font into that directory).
I am told that fonts produced by old versions of FontForge will not install
on Windows 2000 (and XP) systems.
I believe this problem is fixed now (as of 20-Oct-2003). If you have an older
version please upgrade.
If you are copying a font from another machine make sure the execute bit
is set in the permissions of the font file (I don't know how to do this with
the Windows UI, under cygwin you say $ chmod +x foo.ttf
-
How do I edit fonts from my macintoy?
-
-
Mac OS/9 (or less)
-
Traditionally the macintosh has stored fonts in the resource fork of files
(after about OS/8.5 I believe the mac also supported bare .ttf files). This
causes problems for any machine other than a mac, because the very concept
of a resource fork is lacking.
There are several programs whose job it is to store all of a macintosh file
in one package that can be manipulated on other systems (mac binary and binhex
are the most common). FontForge knows how to read both of these formats and
can extract a postscript or truetype font from either. FontForge can also
create fonts in macbinary format (I see no reason to support both output
formats, and macbinary is slightly simpler).
So to edit a font on your mac:
-
Find the file in the System Folder:Fonts folder
-
Copy the file over to your unix machine
-
Use Fetch and specify macbinary format
-
Or use some tool like binhex which can create the file directly
-
Open it in FontForge
-
Edit it
-
Save it back in macbinary format
-
Copy it back to your mac
-
Fetch will automatically undo the macbinary wrappers and make it be correct
-
Or various other tools can unwrap it.
-
Drop it back into your system folder (where it is automagically moved to
Fonts)
Note: make sure you either replace the original font files,
or that you rename the font within fontforge and (for postscript fonts) that
you give it a new unique id. See the Font
Info dlg.
Caveat: A postscript font is useless on a macintosh unless
it is accompanied by at least one bitmap font. If you generate a postscript
font make sure you also generate an NFNT as well (this has the FOND).
Caveat: The mac is picky about the filename used to contain
a postscript file. It is based on the postscript font name but suffers a
transformation. Don't try to rename this file. Basically the rules are (see
Adobe
Technical Note 0091):
-
The fontname is broken into chunks where each chunk starts with a capital
letter.
-
The first chunk may have four lower case letters following the initial capital
-
Subsequent chunks may only have two lower case letters following the capital.
-
Non-letter glyphs (or at least hyphens) vanish.
So TimesBold => TimesBol, Helvetica-BoldItalic => HelveBolIta,
NCenturySchoolbook => NCenSch
-
Mac OS/X
-
On Mac OS/X you can run FontForge
directly (if you've got XDarwin
installed). OS/X has several font formats, some fonts are stored in the
old format (see above), while others are stored as data fork resources. The
data fork font files generally have the extension ".dfont". On a Mac FontForge
is able to edit both formats directly. OS/X also supports normal .otf and
.ttf font files.
Mac OS/X does not seem to support the old NFNT bitmap format, but it still
requires that an bitmap font in NFNT format be present before it will use
a resource-based postscript font. (It is probably not the NFNT resource which
is required, but the FOND which goes along with it. But I'm not going to
write something to produce a bare FOND resource).
-
How do I create a mac font family? (How do I get
the mac to group my fonts so that the italic and bold styles work)?
-
For the Style menu in most mac applications to work on your fonts, you must
create a font family. You do this with the
File->Generate Mac
Family command.
All the fonts in a family must have the same Family name (See the
font info dialog). Font Families
are handled rather differently under Carbon (the old font handling mechanism
used in OS 9) and under ATSUI (on OS/X).
Under Carbon, the font family is limited by the design of the Mac 'FOND'
resource, which reflects the computer font technology of the early 1980s.
Modern computer fonts often have variants that can't be expressed in it.
FONDs support any combination (except one containing both Extend and Condense)
of the following styles:
-
Bold
-
Italic
-
Condense
-
Extend
-
Underline
-
Shadow
-
Outline
Mac FONDS do not support "Black", "DemiBold", "Light", "Thin" or
"Extra-Condensed" variants.
Under ATSUI, on the other hand, a family seems to consist of all fonts in
a given resources file which have the same FamilyName.
In order that a family be useful under both systems, Apple appears to several
FONDs inside such a font file. Each FOND contains a sub-family of related
fonts. The 'FOND's appear to be distributed as follows:
Suppose you have a family of fonts with the following styles:
Regular, Bold, Italic, Bold-Italic, Condense, Condense-Italic, Oblique, Light,
Light-Italic, Black
Then you should create a font family with the styles that the FOND does support,
which in this case would be
Regular, Bold, Italic, Bold-Italic, Condense, Condense-Italic
For each of these use
Element->Font
Info->Mac to set the FondName field to the font's family name.
Change the fondname of the other styles, so that the Oblique style has Oblique
in the fond name, the two Light styles have Light in the fond name, and so
on. Set the Mac Style
on the "Light" variant of the font to be Regular (everything unselected)
and set the style of the "Light-Italic" variant to be "Italic" -- that is,
forget about the "Light", the FOND can't handle it, that's why we moved it
into its own family.
Having done this setup, the Generate
Mac Family command should be able to put all the fonts into appropriate
FONDs, and then place all the FONDs into one file, which the Mac should interpret
correctly.
-
Why doesn't ATM work on my fonts?
-
Insure that the font has an encoding of Macintosh Latin when you generate
it.
This is really a limitation on ATM's part and there's nothing FontForge can
do about it.
If you generate a font with an encoding other than Macintosh Latin, then
the Mac's default behavior is to force the postscript font to have a Macintosh
Latin encoding. There is a mechanism to turn this behavior off, but if it
is turned off then ATM won't work at all.
-
How do I edit fonts on MS windows?
-
To run FontForge under MS windows you must first install the
cygwin environment.
If you want to be able to build FontForge under cygwin, you will need to
grab some other cygwin components, like gcc, the image processing libraries,
freetype, etc.
-
Why don't my fonts work on windows?
-
Here's one possibility: Windows sometimes (and I don't know when) insists
on having a name for the font in the appropriate language (ie. a Japanese
entry for a SJIS font). Try going to
Element->Font Info->TTF
Names and adding a set of strings for your language.
Another possibility is discussed
here.
-
When I load an otf or a type1 font most of my
references have been replaced by inline copies. How do I get my references
back?
-
It is very difficult to figure out old references when loading postscript
fonts. Instead FontForge has a special command,
Edit->Replace With
Reference, that will search for potential reference candidates in the
font and replace them with references.
-
Does FontForge read in the old kerning information
from fonts?
-
This question needs to be broken down into cases:
-
TrueType and OpenType fonts
-
Yes. The kerning information is stored in either the 'kern' or 'GPOS' tables
of these fonts and FontForge can read the most common formats (Apple has
made a number of extensions beyond the original truetype spec, and FontForge
does not handle all the Apple formats).
-
PostScript Type1 fonts anywhere other than the Mac.
-
The kerning information is not stored in a Type 1 font file. Instead it is
stored in a file with the same filename as the font file but with the extension
".afm". When FontForge reads a PostScript font it will check for an associated
afm file, and if found will read the kerning information from it.
-
PostScript Type1 fonts on the Mac.
-
No. Again the kerning information is not stored in the font file (it is stored
in a bitmap font file), but on the mac it is impossible to guess what name
to use for the associated bitmap file, and FontForge does not even try.
See the info below on how to load kerning from a
FOND.
-
AFM and TFM files.
-
FontForge can read kerning information directly from these files and apply
those data to a font. See the
File->Merge Kern Info
menu command.
-
Mac resource files containing FOND resources.
-
The mac stored kerning information in the FOND resource
associated with a bitmap font (it is not stored in the file with the postscript
font). If you wish kerning data for a mac postscript font, you must find
a font file containing a bitmap font with the same family and style as the
postscript. FontForge can read kerning information directly from these files
and apply those data to a font. See the
File->Merge Kern Info
menu command.
-
How do I convert from one outline format
to another?
-
This is easy, simply open an existing font, and then use
Element->Generate Fonts to generate
the desired output.
-
How do I convert from one bitmap format to
another?
-
This is also easy, open a bitmap font, and then use
Element->Generate Fonts to generate
the desired output.
-
How do I convert from an outline format to a
bitmap format?
-
Load the outline font. Then use
Element->Bitmaps
Available to generate bitmap strike(s) of the appropriate size(s). This
process is called rasterization, at small pixel sizes it is difficult for
a computer to do well. You might be advised to examine the results of the
rasterization in the bitmap window
(with Window->Open Bitmap
Window), possibly fixup the bitmap as you go. Then when done select
Element->Generate Fonts, turn
off outline font generation (unless you also want an outline font, of course),
and select the desired bitmap format.
-
How do I convert from a bitmap format to an outline
format?
-
Unless you have a very large bitmap font (such as a TeX font) the following
procedure will not produce good results.
-
Before you do anything else make sure you have either the
potrace or autotrace programs
installed on your system
-
Create a new font
-
Use the File->Import
command to import your bitmap font into this new font
-
Be sure to check the
[] Into Background
checkbox
-
Edit->Select All
-
Element->Autotrace
-
Element->Add Extrema
-
Element->Simplify
At this point you will probably want to look at your outline glyphs and clean
them up.
-
File->Generate Fonts
-
How do I make FontForge use hint substitution?
-
It happens automagically.
-
How do I make FontForge use flex hints?
-
It happens automagically. FontForge will generate flex hints in situations
where it is appropriate to do so. You don't need to do anything. If flex
hints are used then the necessary subroutines will be added to the font.
If they are not needed then the subroutines will not be added.
-
How can I tell if it is going to use flex hints?
-
If you want to see whether FontForge is going to use flex hints, turn on
the UpdateFlex preference item and open
a view on the glyph. FontForge displays a green halo around the center point
of a flex hint.
-
My glyphs are all perfectly hinted, why do some stems
have different widths (or appear fuzzy, or fade away completely)?
-
Both PostScript and TrueType require that glyphs be drawn in a clockwise
fashion. Some rasterizers don't care. But other rasterizers will have
difficulties with counter-clockwise paths and produced stems of different
widths when they should be the same, or fuzzy stems, or even nothing at all.
The solution to this is to run Element->Correct Direction on all your
glyphs before generating a font.
But sometimes the poor rasterizer just can't do the right thing...
-
How do I set a particular bit in the OS/2 table (or any
other)?
-
FontForge does not do this, but I have written a companion program,
mensis (Latin for: "to or for, by, with
or from tables") which gives you bit access to tables. It provides both UI
and scripting access.
-
How do I mark a font as monospaced?
-
You don't. Just insure that all the glyphs in the font have the same width
and then FontForge will automatically mark it as monospaced for you. (If
you mark it as monospaced incorrectly some rasterizers will give strange
results).
If you are unsure whether all the glyphs in your font have the same advance
width use Element->Find
Problems->Random->Check Advance.
-
How I do tell fontforge about a new
encoding
-
First ask yourself if you really need a new encoding? If you are using OpenType
or TrueType fonts you can usually get by with the standard unicode encoding.
But if you really need a new one here is a rough idea of what to do:
Figure out what your encoding looks like. Often this will involve searching
around the web to find an example of that encoding. For instance if you want
a devanagari encoding you might look at
a
site which shows the ISCII encodings
These encodings only show the top 96 characters, presumably the others are
the same as US ASCII. Look at the images and figure out how they map to unicode
(or more precisely what the appropriate postscript names are for those
characters).
Create a file (call it "Devanagari.ps" in this case). It should start with
a line:
/Devanagari {
This tells FontForge that the encoding is called "Devanagari", then follow
this with a list of all the character names (preceded by a slash). We start
with ASCII which starts with 32 .notdef characters, then space, etc.
/Devanagari {
/.notdef
/.notdef
...
/.notdef
/space
/exclam
/quotedbl
...
/braceright
/asciitilde
/.notdef
...
/.notdef
/uni0901
/uni0902
...
/uni096F
}
Now load this file into FontForge's list of encodings with Element->Font
Info->Encoding->Load, and then apply it to whatever fonts you want.
-
How do I add a glyph with a new name?
-
Let's say you wanted to add a "dotlessi" glyph to an ISO-8859-1 font (this
encoding does not include dotlessi). There are two ways to approach the problem:
-
Bring up
Element->Font Info
Select the Encoding
tab
Increment the Number of Glyphs
field by one (probably to
257
)
Press OK
Scroll down to the end of the font and find the new glyph
Select it
Bring up Element->Glyph Info
Type your new name into the Unicode Name
field (in this case
you'd type in dotlessi
)
Press the Set From Name
button
Press OK
Now draw a dotlessi in the glyph.
-
Bring up
Element->Font Info
Select the Encoding
tab
Change the Encoding
to ISO-10646-1 (Unicode)
Press OK
Bring up View->Goto
Type in dotlessi
Press OK
Now draw the dotlessi glyph in the selected glyph slot
Bring up Element->Font Info
again
Change the Encoding
back to whatever it was
-
Why isn't my Open Type font much smaller than the
.pfb file?
-
This is probably because you didn't round to int before saving the font.
FontForge will save the font using fixed point numbers which take up a lot
more space than normal integers.
-
What's the difference between OpenType and
PostScript (or TrueType) fonts?
-
Both PostScript and TrueType define a file format and a glyph format. OpenType
uses the TrueType file format with a PostScript glyph format (actually OpenType
includes the TrueType glyph format as well, but the OpenType definition says
such fonts should still be called TrueType fonts so I ignore that aspect).
The PostScript used in OpenType is slightly different from that used in .pfa
and .pfb files. pfa/b files are Type1 fonts while OpenType uses Type2 fonts.
Type2 is almost a superset of Type1 with a few minor changes and many extensions.
Adobe's subroutine based extensions to Type1 (flex hints, hint substitution,
counter hints) have been added to Type2 as direct instructions.
-
After I generate a font and quit, why does FontForge
ask if I want to save the font? I didn't change anything.
-
There are two reasons why this might be happening.
-
Even though you haven't changed anything in this session, FontForge may need
to (re)generate hinting information on one or several glyphs (if, for example
those glyphs have been changed (in an earlier session) but no hints have
been generated for them since). These new hints will mark the font as changed.
-
If your font has an XUID field in the Font Info, then FontForge will increment
the final number in the XUID each time a postscript font is generated --
and this also counts as a change. (Why does FontForge do this? Because Adobe
says it should. A minor annoyance, but it avoids some problems with font
caching when you change an old version of the font for a new one).
-
Why doesn't TeX work with my fonts?
-
I'm a total novice with TeX. I am told that TeX (or some part of the TeX
chain, dvips perhaps) expects fonts to be encoded in TeX base Encoding --
sometimes called "Adobe Standard" by the TeX docs, but it isn't it's TeX
base. So if you are having printing problems, missing glyphs, etc. try changing
the encoding of your font to TeX Base (Go to Element->Font Info, select
the Encoding tab, select TeX Base from the pulldown list).
-
Why doesn't FontForge let me edit an '.mf'
file?
-
As Knuth said "(the problem with WSYWYG is that...) What you see is
all you get." FontForge suffers from this.
Let us take a simple example. Suppose we have a point defined by
top1y2 = CapHeight
And the user tries to drag point 2 to a new y location. How should FontForge
interpret this? It could:
-
Change
CapHeight
-
Change the width of pen 1
-
Change the equation to something like:
top1y2 = CapHeight - 30
-
Or to something like:
top1y2 = (CapHeight +
XHeight)/2
-
Or to half a dozen other things.
So FontForge's method for moving a point around is ambiguous. And I haven't
been able to come up with any reasonable way for disambiguating it. Suggestions
are welcome (but there's no guarantee they'll be implemented).
-
Why does my window get iconified when I want
to minify the view?
-
Some window managers (gnome-sawtooth for one) steal meta (alt) clicks from
FontForge. So you can't use meta-middle-click to minify a glyph, you have
to use the View menu->Zoom Out instead.
-
Why isn't there a character named "mu" in my greek
font?
-
Adobe was thinking more of backwards compatibility than sense when they assigned
the names of the greek letters in their unicode encoding. Thus the name "mu"
refers to the Micro Sign (U+00B5) and not to the letter mu. They also assigned
Delta to Increment, and Omega to Ohm Sign.
Adobe has also decided that the character at U+03D6 (said by the Unicode
consortium to refer to "GREEK PI SYMBOL") should be named "omega1", when
"pi1" seems more appropriate.
-
Why doesn't Edit->Copy copy glyph names as
well as glyph info?
-
Firstly because I believe that any attempt to copy a glyph's name will almost
certainly be better done by defining a custom
encoding.
Secondly because most of the time you don't want the name copied.
Thirdly because it is esthetically better that copy should only work with
data and not meta-data.
HOWEVER... enough people have asked this question that I've enabled a mode
in Edit->Copy From->Char
Name which allows you to change the default behavior.
-
Why does Edit->Paste complain about name
duplication?
-
Because you have Edit->Copy From->Copy Metadata checked. Uncheck it.
-
What on earth are cidmap files and should I care about
them?
-
Some background:
When postscript was invented every glyph in a font was given a name, and
an encoding which was specified by a 256 element array mapping character
codes to names.
Then they started thinking about CJK fonts (and perhaps Unicode), which have
huge glyph sets, and coming up with reasonable ASCII names for 10,000 glyphs
was a) a waste of space, b) fairly meaningless.
So then adobe created CID-keyed fonts which have no glyph names and no encodings.
Every glyph has an index (a CID), which is just a number, and this is sort
of treated as a name. Then external to the font is an additional resource
(a cmap) which provides the encoding for the font (and can support really
grungy encoding schemes like SJIS), by mapping a sequence of input bytes
to a CID.
Adobe provides certain standard cmap resources (ie. one for SJIS, one for
JIS, one for Extended Unix whatever). Because these files are fairly painful
to write Adobe has assigned standard meanings to CIDs so that everyone can
use the same cmap file. -- Well actually there are 5 or 6 different standards,
Japanese (JIS208), Japanese (JIS212), Korean, Chinese (Hong Kong, Taiwan),
Chinese (Mainland, Singapore), Identity (Unicode) -- So CID 1 might be space,
CID 2 might be "!", CID 935 might be "Katakana ka", etc.
My cidmap files just give me a mapping between Adobe's CIDs and Unicode.
This allows FontForge to know what glyph it is working on. If they aren't
present things should work ok, but FontForge would fill the font view with
"?" rather than the appropriate glyph. And FontForge wouldn't be able to
reencode the font into Unicode or anything else.
So the cidmap files are only useful for people working on CID keyed CJK fonts.
So many europeans/americans won't need them.
-
Does the simplify command lose accuracy?
-
Yes it does.
But not much.
It is designed to replace a set of splines with another spline that nowhere
differs from the original by more than one unit in the local coordinate
system.
If this level of accuracy is not good enough then (In the outline view):
-
Edit->Select All
-
Element->Transform
-
Scale Uniformly: 1000%
-
OK
-
Simplify
-
Element->Transform
-
Scale Uniformly: 10%
-
OK
This will replace a set of splines with a spline that differs from the original
by no more than .1 unit.
-
How does FontForge convert a cubic spline into
a quadratic spline for truetype?
-
Again this can involve a loss of accuracy.
First FontForge checks to see if the spline happens to be a quadratic already
(this would happen if you'd just read in a truetype font, or if a miracle
occurred when you generated the spline).
Otherwise FontForge will divide the original spline into smaller chunks and
try to find a set of quadratic splines that differ from the cubic by no more
than one unit anywhere. (Once you have picked two end-points and know the
slope at those end-points there is only one quadratic spline possible between
the two).
-
How does FontForge convert a quadratic spline
into a cubic (when reading truetype)?
-
This is easy since any quadratic spline can already be represented as a cubic,
it will just happen that the cubic term is always 0.
-
Why does fontforge say "Error loading dynamic library"
when trying to import an image file?
-
FontForge depends on certain dynamic libraries to load images. It does not
check for the existance of these libraries until you actually try to load
an image. If the library has not been installed on your system it will give
the above error (and fail to load the image).
The Dependencies section
of the main page describes how to find these libraries.
If the libraries are installed and you still get this message try setting
your LD_LIBRARY_PATH variable to the directory containing the library in
question (On the mac this is DYLD_LIBRARY_PATH).
-
Why does fontforge say "EPS file is too complex
to be understood"?
-
Most programs which load eps files treat them as black boxes. They will read
the file into memory and output it, unchanged, to a postscript printer.
Unfortunately FontForge cannot do this. FontForge needs to understand and
then convert the eps file into a simpler format (fonts can use far fewer
operations than an eps file). So unlike most programs FontForge must interpret
each eps file -- but interpretting all of PostScript is a huge job and ff
is limited in what it understands. Sometimes it will find a file it can't
handle.
-
How do I set the default glyph of a font?
-
If the glyph at encoding 0 is named ".notdef" and if it contains some splines
(but no references) then it will be used as the default glyph (that is the
glyph used when an unencoded glyph is called for).
-
I loaded a ttf font, made a few changes and generated
a new font. The changed glyphs don't look anywhere near as nice as the originals.
Why?
-
Unfortunately FontForge does not hint truetype fonts at all well. And when
FontForge reads in a truetype font it saves all the hinting (instructions)
that were present in the original. But if you change a glyph in any significant
way those instructions are no longer valid (they depend intimately on the
details of the outlines), so FontForge removes them when you make a change.
The result is that changing a glyph with FontForge will degrade its appearance
in most truetype fonts (not all, some have no hints).
FontForge can hint vertical and horizontal stems, but not diagonals. In many
glyphs FontForge's attempt at hinting makes things worse (because the diagonals
don't match the horizontals/verticals). So if you want this to happen you
must explicitly call the Hints->AutoInstr command.
-
I generated an opentype font and windows wouldn't
install it. Why not?
-
Unfortunately Apple and MicroSoft (and Adobe) do not agree on the proper
format for open and truetype fonts. FontForge has a check box on the Generate
Font dialog labelled [] Apple. Make sure this is checked when you are generating
a font for the mac. Make sure this is not checked when generating a font
for Windows (and probably for unix too, though unix tends to be less picky).
The major differences I've stumbled onto so far are:
-
The postscript name entry in the NAME table.
-
The names of the tables containing bitmap fonts
-
The way scaled references are stored
-
And the tables containing advanced typographical features are completely
different
-
I looked at kaiu.ttf or mingliu.ttf and the outlines
looked nothing like the correct glyphs. What's wrong?
-
Some truetype fonts (kaiu and mingliu) do not store the correct outline.
Instead they rely on using the instructions to move points around to generate
the outline. The outline does not appear to be grid-fit at all, just positioned.
FontForge will not process the instructions as it reads the font. In most
fonts this would be the wrong thing to do, and I don't know how I could tell
when it needs to be done...
-
When I use Element->Build Accented Glyph to
build one of the Extended Greek glyphs (U+1F00-U+1FFF) FontForge picks the
wrong accents. Why?
-
For some reason Unicode has unified greek and latin accents even though they
don't look at all alike. When FontForge follows the simplistic unicode
definitions it will probably pick a latin accent for greek glyphs. Fortunately
Unicode also contains code points for the greek accents starting around U+1FBD,
if you fill these code points with the appropriate accents then FontForge
will use these rather than the latin accents.
-
When I use Element->Build Accented Glyph to build
accents over "u" or "y" I get the accent over one of the stems not centered
on the glyph. Why?
-
One of your stems is a little taller than the other. FontForge centers accents
over the tallest point on the glyph. If there are several points with the
same height, then an average is used.
If you make all your stems be the same height then the accent should be properly
centered.
-
Why does ttf2afm crash on FontForge ttf files?
-
I don't know. The ttf2afm that was distributed with my redhat 7.3 linux certainly
did crash. When I downloaded the source from
pdftex
area of ctan and built it (with debug) the resultant program did not crash.
Therefore I believe this is a bug in ttf2afm and that bug has been fixed.
The afm files produced by ttf2afm don't conform to
Adobe's
specifications.
-
Why is FontForge so unstable?
-
I don't bother much with doing QA. This is a problem. I don't enjoy doing
it, and no one is paying me to do it, so little gets done.
If you would like to volunteer to do
QA let me know.
It's a thankless job, but important!