Sophie

Sophie

distrib > Mandriva > 8.2 > i586 > by-pkgid > efc75c1dcfa45d4b2a545c38cda30759 > files > 108

pfaedit-020312-2mdk.i586.rpm

<HTML>
<HEAD>
  <!-- Created with AOLpress/2.0 -->
  <!-- AP: Created on: 6-Dec-2000 -->
  <!-- AP: Last modified: 5-Feb-2002 -->
  <TITLE>The Font View</TITLE>
</HEAD>
<BODY>
<H1 ALIGN=Center>
  Font View
</H1>
<P>
<IMG SRC="AmbrosiaFV.png" WIDTH="423" HEIGHT="226">
<P>
The font view is a list of all the characters available in the given font.
<P>
You may chose to display it at various sizes, by default it will be displayed
with the outline font rasterized on a 24 pixel em square. You may display
it at 36 and 48 pixel sizes as well. You may also choose to look at an
anti-aliased greymap (the above image is anti-aliased). These are slower
to generate but look nicer (<A HREF="AA-Comparison.html">Comparison</A>).
<P>
If you look at a bitmap version of the font, and it does not contain a character
for which there is an outline character (ie. the font needs its bitmaps
regenerated) then the missing character will be outlined in red to bring
it to your attention more easily.
<P>
If one of your characters has something in its background layer then this
will be indicated visually (currently by darkening the background of the
character label).
<P>
Small bitmap fonts will be magnified. If the pixelsize of the font is less
than 10 it will be shown 3 times normal size, if less than 20 twice normal
size.
<P>
Underneath the menu bar is some information on the last character selected.
First is the encoding of the character in the current font expressed in decimal.
Next is the unicode code point for the character (or ???? if it is not a
unicode character). Next the postscript name for the character, and finally
the unicode name. Not all unicode characters will have unicode names (the
CJK characters do not for example)
<P>
You may also display any of the bitmap fonts you have generated from the
outline characters. Simply go to the View menu and select the one you want.
<P>
You may select any number of characters in the font by dragging through them.
You may use shift-click to select (or deselect) additional characters. You
may also use the arrow keys to move around (and shift-arrow to select).
<P>
The [Tab] key will move to the next character with something in it, and
Shift-[Tab] will move to the previous character with something interesting.
<P>
You can perform various operations on the selected characters:
<UL>
  <LI>
    Apply a general transformation (ie. move 20 units right and then rotate
    180&#176;)
  <LI>
    Expand all paths to be stroked paths
  <LI>
    Clean up areas where several paths intersect
  <LI>
    Simplify paths
  <LI>
    Build Accented Characters
  <LI>
    Regenerate bitmaps
  <LI>
    Autohint
  <LI>
    Control various metrics settings
</UL>
<P>
And, of course, you can cut and paste. Normally copying a character will
copy that character and any bitmaps associated with it, but you can use the
Edit-&gt;Copy From menu item to change this so that only entries from the
currently displayed font are copied. So if a 12 pixel font is being displayed
then only the bitmaps from the 12 pixel bitmap font will be copied in this
mode. Cut and Clear will clear those things which would be copied.
<P>
Paste is a little more complicated. In general it will paste whatever is
in the clipboard, regardless of the copy mode. So if the clipboard contains
a 12pixel bitmap and the font view is displaying outlines, then pasting it
will paste it into the 12pixel font none the less. There is one exception
to this. If the clipboard contains a 12 pixel bitmap and the font view is
currently display a 17pixel bitmap then the paste will go into the displayed
bitmap.
<P>
A Paste from the font view will delete whatever splines were in the character
beforehand (while a paste in the outline character view will merge the new
set of splines with the old). Paste from the font view will also set the
width of the character.
<P>
You can scroll the display to any particular character by typing that character.
There is also a dialog which allows a slightly more general way of jumping
around. You may type in the character's name (all characters in a font will
be named), its encoding value, its unicode encoding value, or (for 2 byte
fonts) its ku ten specification.
<P>
Pressing the right mouse button invokes a popup menu.
<H2>
  <A NAME="Encodings">Encodings and Character Sets</A>
</H2>
<P>
A Character Set is a set of characters (for example all the letters of the
alphabet would be one character set). An encoding is a function that takes
a number (often between 0 and 255) and maps it to a character. Often these
two are used synonymously as an encoding generally implies a given character
set. (strictly speaking a character set is an unordered collection with no
implied encoding, and some encodings work with multiple character sets).
<P>
All fonts in pfaedit have both a character set and an encoding. The character
set is just the set of characters in the font. The encoding is the way those
characters are ordered (or sometimes, the way the first 256 are ordered).
The font info dialog allows you to chose the encoding (and character set)
you wish for a font. Often a font will have a few extra characters that don't
fit into the character set specified by the encoding, these characters will
be placed at the end of the font and when the font is output (ie. postscript
is generated, or a bitmap font created) the characters will be included in
the font but they will not be encoded (this can be useful, especially in
postscript where it is possible to reencode a font at run time. Thus a font
might have all the characters needed both for a cyrillic character set and
for a latin one, but only one character set at a time would be encoded).
<P>
You may also create a custom encoding. (Custom encodings may not have more
than 256 encoded characters). You may change the name of any character in
the font with the Element-&gt;Char Info command. This will force the font
to have a custom encoding.
<P>
There are many standard encodings built in to the program. There are 14 ISO
8859 encodings, the encoding used by the Macintosh for the US and Western
Europe, the encoding used by MS Windows for the US and Europe (which is a
slight extension of ISO 8859-1). There are also 7 2-byte encodings built
in. Two of these are unicode whose goal is to specify every character currently
used by humans. There are 4 CJK (Chinese, Japanese, Korean) 94x94 encodings
(two bytes where each byte ranges over the 94 ASCII printable characters
excluding the space character). And there are big5 (Taiwanese) and johab
(korean) which aren't 94x94. You can also add your own encodings with the
<A HREF="fontinfo.html">Element-&gt;Font Info</A> dialog. A brief description
of what's in the encodings also appears <A HREF="fontinfo.html#Encodings">on
that page</A>.
<P>
There may be some slight differences between one vendor's definition of an
encoding and another. I try to follow those encoding specified by the Unicode
consortium. I notice that the Symbol encoding used by Microsoft differs from
the Unicode one (usually just be substituting synonyms, Omega for Ohm sign
for instance).
<P>
Adobe did not choose their naming conventions very well for Greek letters.
They assigned the name "mu" to Micro Sign, "Delta" to Increment and "Omega"
to Ohm Sign. So the Greek alphabet has ugly nameless holes in it. I have
cheated by reassigning "Delta" and "Omega" so that they refer to the letters,
but "mu" is part of Adobe's Latin1 encoding and I can't change that.
<P>
CID fonts (see <A HREF="#CID">below</A>) have no encodings. Instead they
are designed to be associated with one or several cmap files which provide
encodings in a general way. cmap files are beyond the scope of PfaEdit. Adobe
has defined many which are freely
<A HREF="http://www.adobe.com/products/acrobat/acrrasianfontpack.html">available</A>.
<H3>
  <A NAME="Unicode">Unicode</A> (ISO 10646)
</H3>
<P>
PostScript&reg; assigns a name to every unicode character. Some of these
names are fairly obvious like "A" for the first letter of the latin alphabet,
others are more obscure like "afii57664" for hebrew alef, while others are
just "uni8765" for the unicode character at 0x8765.
<P>
PostScript Unicode encoding does not quite mesh with the unicode standard.
This is probably because PostScript deals in glyphs and Unicode deals with
characters so PostScript sees no distinction between space and nobreak space
(and so does not encode the latter) while Unicode does.
<P>
According to the <A HREF="http://www.unicode.org/">unicode website</A> the
first 256 character positions of unicode and ISO 8859-1 (ISO Latin1) are
the same. However the PostScript encoding of ISOLatin1 is slightly different
from that specified for unicode. I cannot explain the reasoning behind this.
PfaEdit does not use PostScript's ISOLatin1 Encoding vector, instead it uses
the first 256 code positions of the unicode encoding vector (slightly modified
by me to conform to Unicode conventions rather than PostScript. So I include
nobreak space and the soft-hyphen).
<P>
PfaEdit supports two slightly different unicode encodings. The first contains
only the first 65536 characters of unicode (those in the
<A HREF="http://www.unicode.org/roadmaps/bmp-3-1.html">Basic Multilingual
Plane</A>, or BMP), while the second can contain as many characters as you
have memory for. Very few characters have been defined outside of the BMP
so at the moment you probably want to use just the BMP (the full encoding
isn't completely supported yet anyway). Currently there are only definitions
for plane 0 (BMP, U+0000-U+ffff), Plane 1
(<A HREF="http://www.unicode.org/roadmaps/smp-3-1.html">SMP, Secondary
Multilingual Plane</A>, U+10000-U+1ffff), Plane 2
(<A HREF="http://www.unicode.org/roadmaps/sip-3-0.html">SIP, Supplementary
Ideographic Plane</A>, U+20000-U+2ffff), and Plane 14
(<A HREF="http://www.unicode.org/roadmaps/ssp-3-1.html">SSP Supplementary
Special-purpose Plane</A>, U+e0000-U+effff).
<H2>
  <A NAME="CID">CID keyed fonts</A>
</H2>
<P>
The standard mechanisms that postscript provides work reasonably well for
alphabets and syllibaries, but the massive number of characters needed for
CJK (Chinese, Japanese or Korean) fonts require more complex machinations.
Adobe's current solution is the CID-keyed font, a font consisting of several
subfonts each a collection of glyph descriptions with no encoding imposed
on them and no names given to them.
<P>
If PfaEdit loads in a CID keyed font it will enable a special menu called
<A HREF="cidmenu.html">CID</A> which (among other things) displays the list
of all the sub-fonts in the font. When it starts up PfaEdit will pick
(practically at random) a sub-font to display in the font view. You may change
which font is displayed by the CID menu.
<P>
The CID menu also allows you to turn a normal font into a CID keyed font.
It creates a collection containing just the original font (you may add other
fonts, or blank fonts, later). But before it can create a collection PfaEdit
needs to know what character set you will be using. A character set is just
a collection of characters, and you may define your own if you wish (but
if you do you have to define your own cmap files, etc and it's probably not
worth it). Adobe has defined character sets for Japanese (actually there
are two, one corresponding to JIS208 and one to JIS212), Korean (Wansung
&amp; Johab), Traditional Chinese (Big5) and Simplified Chinese (GB2312).
Although these character sets are based on the standards mentioned, they
each have many additional characters. Adobe also defines a charset that works
for Unicode, but it is called "Identity" instead. PfaEdit does not have these
character sets built in to it, each must be loaded the first time it is used.
I provide one file for each of the above character sets, they have an extension
of ".cidmap", and you may download them all <A HREF="cidmaps.tgz">from
here</A>.
<P>
(There are also a few other character sets floating around but they aren't
in the public domain and I haven't been able to get my hands on them).
<P>
Adobe identifies each character set by a three values: a registry, an ordering
and a supplement. The registry is the name of the organization that is defining
the character set (Adobe calls itself Adobe), an ordering identifies the
character set (Japan1, Korea1, etc.) and the supplement indicates how many
times the ordering has been revised. Characters may only be added to an ordering,
never removed, so an old font will be perfectly described by a newer character
set, while a new font described by an old character set will have some
unavailable characters. So a full cidmap name will look like:<BR>
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
Adobe-Japan1-4.cidmap<BR>
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; Adobe-Korea1-2.cidmap
<P>
<FONT COLOR="Red"><STRONG><BIG>Warning:</BIG></STRONG></FONT> CID keyed fonts
(actually any CJK font) use massive amounts of memory. I am able to work
on many of them (but not all) on my 256M machine with 384M of swap space.
TrueType fonts tend to use more memory when converted to PostScript (which
is essentially what PfaEdit does when it reads in a TrueType font) than would
a native PostScript font for the same thing.
<P>
The <A HREF="editmenu.html#Remove-Undoes">Remove Undoes </A>command will
allow you to free up memory if you think you may be running short. PfaEdit
is not always able to protect itself against running out of memory, sometimes
the OS just sends it a SIGKILL signal.
<H2>
  <A NAME="Vertical-Metrics">Vertical Metrics</A>
</H2>
<P>
CJK fonts generally should have vertical metrics. Latin (Cyrillic, Greek)
fonts generally should not. If PfaEdit reads in a font with vertical metrics
it will retain those metrics, but when PfaEdit creates a new font then that
font will not have vertical metrics enabled.
<P>
To enable vertical metrics for a font go to
<CODE><A HREF="fontinfo.html#vertical">Element-&gt;Font Info</A></CODE> and
select the <CODE>PS General</CODE> tab and check the <CODE>[*] Has Vertical
Metrics </CODE>checkbox. This will allow you to set the vertical origin for
the font and it will give every character a default vertical advance of the
emsize of the font (ascent+descent).
<P>
The vertical origin is the y height (in the design coordinate system) of
the origin for vertical metrics.
<P>
In the outline character view you will be able to adjust the vertical metrics
just as you adjust the horizontal metrics.
<P>
<P ALIGN=Center>
-- <A HREF="editexample.html">Prev</A> -- <A HREF="overview.html">TOC</A>
-- <A HREF="charview.html">Next</A> --
</BODY></HTML>