Fonts

To convert MS Office documents correctly into PDF/SVG, all font files used in the original documents should be installed in the environment where Rainbow PDF Server Based Converter V3.0 is operated. The location of font files should be specified in the Font Configuration File.

In addition, when an actual font file cannot be prepared, you must replace it with another font that can be used. Font substitutions can be specified using the -fontalias option in the Command-line Interface, or Option Setting File.
In a Windows environment, a font that doesn't exist is automatically replaced with another font. If the substitutions is inadequate and needs to be replaced, you can specify it by using the -fontalias option in the Command-line Interface, or Option Setting File.

The Font Configuration File is for setting the details of the font environment.
In Linux and Solaris version: Although the initial file is prepared, you need to set it in accordance with your font environment.
In the Windows version: The font configuration file may be used as is. Note that If a font file other than the standard Windows font file has been installed in your environment you will need to revise the file.

Rainbow PDF Server Based Converter V3.0 also supports EUDC, (end user defined character) for Private Use Characters.

See also Font in the INX Output.
See also Font Output in the XPS Output.

Supported font formats

Rainbow PDF Server Based Converter V3.0 supports the following types of fonts.

Font Configuration File

To configure the font environment for Rainbow PDF Server Based Converter V3.0, you must make a Font Configuration File.

The Font Configuration File is a simple structured XML file and is usually located in the [Install directory]/etc on Solaris / Linux and [Install directory] on Windows.

The Font Configuration File should be set in the Environment Variables AH_FONT_CONFIGFILE . The name font-config.xml is set as default.

In the Font Configuration File, the most important element is <font-folder>. If you want to use more than the PDF Standard 14 Fonts on Solaris / Linux, you must locate the font files in the some directory and add the <font-folder path="..."> element to the configuration file.

Rainbow PDF Server Based Converter V3.0 automatically detects the font files in the specified directory at the <font-folder path="...">. However, there are a few cases where the font name cannot be resolved, only in such cases it is necessary to describe the font file. Normally it is not necessary to specify each file to be used.

Initial Font Configuration File

The following is the initial Font Configuration File. After you have finished the installation of Rainbow PDF Server Based Converter V3.0 Solaris / Linux version, this file will be located at [Install directory]/etc.

<?xml version="1.0" encoding="UTF-8" ?>
<!-- DOCTYPE font-config SYSTEM "font-config.dtd" -->
<font-config>
  <font-folder path="[Install directory]/fonts">
    <glyph-list file="ZapfDingbats-glyphname.txt" afm="ZapfDingbats.afm"/>
  </font-folder>
  <!-- add your font folder here -->
  <!-- font-folder path="/home/user-name/fonts" -->
  <!-- /font-folder -->
</font-config>

In Rainbow PDF Server Based Converter V3.0 Windows version, the following Font Configuration File is installed on [Install directory]. The Windows font directory is set to [System font directory].

<?xml version="1.0" encoding="UTF-8" ?>
<!-- DOCTYPE font-config SYSTEM "font-config.dtd" -->
<font-config>
  <name-processing-mode mode="windows-name"/>
  <font-folder path="[System font directory]">
  </font-folder>
</font-config>

In Windows version, when there is no Font Configration File, the Font Configration File of this content will be assumed.

Font Configuration File elements and attributes

The following table is a summary of the elements and attributes in the Font Configuration File.

Element Location Attribute Description
<font-config> root element

Root element of the Font Configuration File of Rainbow PDF Server Based Converter V3.0.

<name-processing-mode> child of <font-config> mode

Specifies whether to map Type1 font names to font file using only Windows names (.PFM+.PFB). Specifies the value "default" or "windows-name" to the "mode" attribute. The initial value is "default". The environment which "windows-name" is specified is called WindowsName mode.

<name-processing-mode mode="windows-name"/>

This element must be specified before <font-folder> and only one can be specified.

<font-folder> child of <font-config> path

Indicates the font folder using the "path" attribute.

<font-folder path="/home/user-name/fonts">
  ....
</font-folder>

This element can be specified as many times as necessary.

<glyph-list> child of <font-folder> file

Indicates the glyph-list file for Type1 fonts using the "file" attribute. Type1 font files should be specified using "afm" attribute. Glyph-list defines Unicode to glyph-name mapping rule for Type1 fonts. For more information about glyph-list file, refer to the Glyph list file.

<glyph-list file="carta.txt" afm="CR______.AFM"/>

This element can be specified as many as necessary.

afm
<skip-glyphname-mapping> child of <font-folder> afm

Indicates to skip Unicode to glyph-name or Unicode to character code mapping for the Type1 fonts. Corresponding Type1 font file should be specified using "afm" attribute. For more information about this parameter, refer to the Skipping the glyph name mapping.

<skip-glyphname-mapping afm="CR______.AFM"/>

This element can be specified as many as necessary.

<font-exclude> child of <font-folder> file

Excludes font files from being used with Rainbow PDF Server Based Converter V3.0. The font file should be specified using the "file" attribute.

<font-exclude file="times.ttf"/>

This element can be specified as many times as necessary.

<font-alias> child of <font-folder> file

Indicates the alias name of the font family name. The source font file should be specified using the "file" and "entry" attributes. "file" attribute should specify font files. For Type1 fonts, specify the font files that have the .AFM or .PFM extensions. For TrueType or OpenType fonts, you can specify the font files that have the .TTF or .TTC or .OTF extensions. The "entry" attributes should be the number of the fonts in the .TTC (TrueType Collection) file. The number should be a numeric value of 1 or more. If the "entry" attribute is omitted, the value is considered as 1. If the font is not .TTC, the value is ignored.

<font-alias file="simsun.ttc" entry="1">
  ....
</font-alias>

To define the alias names, enumerates the <alias> element within this element. This element can be specified as many times as necessary.

entry
<alias> child of <font-alias> family-name

Indicates the actual alias name for the font described in the "font-alias" element. The alias information is specified using "family-name", "weight", "italic" attributes. "family-name" attribute is the alias font family-name. Newly defined names should not match any other existing font-family names. "weight" attribute is the alias font weight class. This attribute can be specified using a numeric value between "100" and "900" or the keyword "normal", "bold". If omitted, the value is considered as "normal". "italic" attribute indicates the font-style for italic. It should be specified using the keyword "true" or "false". If omitted the value is considered as "false". You can specify multiple alias definition for one font file. This element can be specified as often as necessary.

It's possible to display the font file specified by <font-alias file> using the name and style specified here.

<font-alias file="ARIALI.TTF">
  <alias family-name="MyArial"/>
</font-alias>
<font-alias file="ARIALBI.TTF">
  <alias family-name="MyArial" weight="bold"/>
</font-alias>

In the example above, font-family="MyArial" font-weight="normal" should display "ARIALI.TTF", font-family="MyArial" font-weight="bold" should display "ARIALBI.TTF" differently. Please note the following points.

  • When the italic font is originally specified, and even if font-style="normal" is specified, it doesn't become normal.
  • When the bold font is originally specified, and even if font-weight="normal" is specified, it doesn't become normal. Even if font-weight="bold" is specified, it doesn't become bolder.

When <alias> is specified, the file set in <font-alias file> is selected by the name and style and displayed. For instance, when font-style="italic" is specified and there is no <alias> with italic setting, normal is adopted.

weight
italic
<windows-registry> child of <font-folder> reference

Effective only with Windows version. Specifies whether to get the information of EUDC from the Windows registry or not. If the "reference" attribute is "enable", it refers to the registry. If the "reference" attribute is "disable", it doesn't. If the attribute is omitted, it's detected as enable.

<eudc-processing> child of <font-config> mapping

Specifies whether to process EUDC. If the "mapping" attribute is "enable", it processes EUDC. IF the "mapping" attribute is "disable", it doesn't. If the attribute is omitted, it's detected as enable.

<eudc-range> child of <eudc-processing> start

Specifies the range of EUDC by Unicode.

<eudc-range start="57344" end="63743" />

Numeric value is specified. This sample indicates as 57344 = U+E000, 63743 = U+F8FF. If there is no numeric value specified, and the registry reference is effective with Windows version, it follows the instruction of the registry. If not, the PUA range is detected as (U+E000 to U+F8FF). When end is omitted, it is considered the same value as start. Multiple ranges can also be specified.

end
<eudc-system-default> child of <eudc-processing> file-path

Specifies the EUDC font file of the system default. It is adopted when there is no supported glyphs in the specified EUDC font. If there is no EUDC font file specified, and the registry reference is effective with Windows version, it follows the registry setting. At that time, the code page 932 is referred. If not, EUDC font of the system default is detected as nothing.

<eudc-map> child of <eudc-processing> family-name

Specifies the EUDC file by the "file-path" attribute, which is used when the character code of the EUDC range is specified to the font specified by the "family-name" attribute. If the registry reference is effective with Windows version, it is also taken into consideration. If there are the same "font-family" specified, the previous appearance takes precedence and the Font Configuration File takes precedence over the registry. This element can be specified as often as necessary.

file-path

The DTD of Font Configuration File is as follows:

<!ELEMENT font-config ( name-processing-mode?, 
                        font-folder+,
                        windows-registry?, eudc-processing? ) >

<!ELEMENT name-processing-mode EMPTY >
<!ATTLIST name-processing-mode mode (default|windows-name) "default" >


<!ELEMENT font-folder ( glyph-list
                      | skip-glyphname-mapping
                      | font-exclude
                      | font-alias
                      )* >
<!ATTLIST font-folder path CDATA #REQUIRED >

<!ELEMENT glyph-list EMPTY >
<!ATTLIST glyph-list file CDATA #REQUIRED
                     afm  CDATA #REQUIRED >

<!ELEMENT skip-glyphname-mapping EMPTY >
<!ATTLIST skip-glyphname-mapping afm CDATA #IMPLIED
                                 pfm CDATA #IMPLIED >

<!ELEMENT font-exclude EMPTY >
<!ATTLIST font-exclude file CDATA #REQUIRED >

<!ELEMENT font-alias (alias)* >
<!ATTLIST font-alias file  CDATA #REQUIRED
                     entry CDATA #IMPLIED >

<!ELEMENT alias EMPTY >
<!ATTLIST alias family-name CDATA #REQUIRED
                weight (normal|bold|100|200|300|400|500|600|700|800|900) #IMPLIED
                italic (true|false) #IMPLIED >

<!ELEMENT windows-registry EMPTY >
<!ATTLIST windows-registry reference (enable|disable) #IMPLIED >

<!ELEMENT eudc-processing ( eudc-range*, eudc-system-default?, eudc-map* ) >
<!ATTLIST eudc-processing mapping (enable|disable) "enable" >

<!ELEMENT eudc-range EMPTY >
<!ATTLIST eudc-range start NUMBER #REQUIRED
                     end   NUMBER #IMPLIED >

<!ELEMENT eudc-system-default EMPTY >
<!ATTLIST eudc-system-default file-path CDATA #REQUIRED >

<!ELEMENT eudc-map EMPTY >
<!ATTLIST eudc-map family-name CDATA #REQUIRED
                   file-path   CDATA #REQUIRED >

Adobe Type1 font

This section describes general information for Adobe Type1 fonts and how Rainbow PDF Server Based Converter V3.0 supports them. It has tips on how to use Adobe Type1 fonts more conveniently in your environment. .

Font organization and necessary condition

Adobe Type1 fonts are organized using the following font files.

File extension Description
.PFB (Printer Font Binary) Contains binary compressed font outline.
.AFM (Adobe Font Metrics) Contains general font information and font metrics information. This is a text file. Mainly used in UNIX with .AFM+.PFB pairs.
.PFM (Printer Font Metrics) Contains general font information and font metrics information. It also specifies the Windows font menu name. This is a binary format file. Mainly used in Windows with .PFM+.PFB pairs.

Rainbow PDF Server Based Converter V3.0 supports both types of combinations: .AFM+.PFB, .PFM+.PFB files.

Type1 font considerations.

  • The current version of Rainbow PDF Server Based Converter V3.0 does not support font outline files with .PFA (Printer Font ASCII) extension. Most Type1 font products are shipped in the .PFB format, which is supported by Rainbow PDF Server Based Converter V3.0.
  • Type1 font metrics data which has the .MMM extension is not supported. This metrics file is used for the Multiple Master Type1 fonts.
  • Both.PFB and .PFM that maps to .PFB must exist in the same directory. Fonts may be installed in different directories by using ATM (Adobe Type Manager). Such fonts cannot be used for embedding with Rainbow PDF Server Based Converter V3.0.

Embedding Adobe Type1 fonts

Rainbow PDF Server Based Converter V3.0 supports embedding the Type1 font into PDF files. The followings are required to embed fonts:

  • The .AFM+.PFB or .PFM+.PFB font files must be in the folder specified in the <font-folder> of the font configuration file.

If you do not embed fonts, only .AFM or .PFM files are needed. If fonts are not embedded in the PDF the user will need the actual fonts on their system when they read the PDF file.

Rainbow PDF Server Based Converter V3.0 embeds only what is being used among the glyphs of a Type1 font.

Unicode and glyph mapping using the .AFM file

To use Adobe Type1 font with .AFM files, it is important to know how Unicode characters are mapped into Type1 font glyphs. The following is a brief explanation of how Type1 fonts are treated in PDF files.

  • In the PDF file, letters which are associated with Type1 fonts are stored using 0..255 value character codes.
  • Each Type1 font in the PDF file has the encoding parameters, which defines the character code to the corresponding glyph-name.
  • The PDF reader application (typically Adobe Acrobat or Reader) converts the character codes to glyph-names using encoding parameters. Then reader then gets the Type1 glyph outline using the glyph-name as a key index. Finally the glyph is rendered using this outline data.
If you want to know more about encoding details, please refer to the D Character Sets and Encodings of the PDF Reference.

Example: if the encoding parameter of the Type1 font is Adobe Standard Encoding, and we want to write a "•" (U+2022 BULLET) to a PDF file, we must select character code 0xB7(183) because the glyph-name of this character is "bullet" and it is defined as 0xB7 in the Adobe Standard Encoding.

Before we can write a character code to the PDF file we must first get the glyph-name from the Unicode. This process is described in the Adobe web site document Unicode and Glyph Names. The most important mapping rule is described in AGL (Adobe Glyph List) file. AGL is a simple text file that defines the Unicode to glyph name mapping rules for over 800 Latin characters. Rainbow PDF Server Based Converter V3.0 uses this data to map the Unicode to glyph name. Following is a brief description of how Rainbow PDF Server Based Converter V3.0 maps the Unicode value to glyph name and writes a character code to the PDF file.

  1. Rainbow PDF Server Based Converter V3.0 using the AGL data gets the glyph name from this Unicode character.
  2. Consulting the .AFM file, determines the encoding parameter for this Type1 font.
  3. Also consulting the .AFM file gets the character metrics information and character code from the glyph name.
  4. Writes the obtained character code and encoding information to the PDF file.

Unicode and glyph mapping using the .PFM file

If you are using Adobe Type1 fonts with .PFM files, Rainbow PDF Server Based Converter V3.0 maps Unicode to glyphs differently than above, which does not use glyph names.

First, .PFM file has the only one encoding data in the dfCharSet field of PFM header. This one byte field contains the value known as character set. In the Windows environment, there are following character sets are defined in WINGDI.H header file.

dfCharset Symbol Value Code Page
ANSI_CHARSET01252
GREEK_CHARSET1611253
TURKISH_CHARSET1621254
VIETNAMESE_CHARSET1631258
EASTEUROPE_CHARSET2381250
RUSSIAN_CHARSET2041251
BALTIC_CHARSET1861257

Microsoft mapping can be found at the Unicode to code page mapping data. Rainbow PDF Server Based Converter V3.0 uses this mapping data and converts the Unicode to the character code to write it to the PDF file. This mapping data has a maximum of 256 entries because the code page offers only 8-bit character width. You cannot use glyphs which are not defined in the code page data unless it exists in font the outline data.

Sometimes code page mapping and actual encoding in the font file do not match. Because of this it is not recommended to use principally Type1 fonts as .PFM+.PFB pairs principally. If you must use this combination, please use as a supplementary step.

Changing the glyph name mapping

As mentioned in Unicode and glyph mapping using the .AFM file, AGL offers the Unicode to glyph name mapping rules. It covers commonly used Latin characters. But there are special fonts which do not fit the AGL. For instance, the Adobe Type1 product Carta (CR______.AFM, CR______.PFM, CR______.PFB) has 189 pictorial glyphs and non-standard glyph names. If we look up the glyph names into the AGL, we will get the result that only 14-glyph names match and the others do not match with the AGL. If we leave it as it is, we cannot use most of the glyphs in the Carta with the .AFM+.PFB combination.

To solve such problem, Rainbow PDF Server Based Converter V3.0 offers two solutions. One is to make a glyph list file for this font. Another is to specify the <skip-glyphname-mapping> in the font configuration XML file.

Glyph list file

The glyph list file is a simple text file, which describes the Unicode to glyph name mapping for a particular font. The format is the same as AGL.

  • First field is the Unicode value represented using 4 uppercase hexadecimal digits.
  • Second field is the glyph name defined in the .AFM file.
  • Third field is the Unicode character name. This field is optional.
  • All fields must be separated using semicolons. Lines starting with character "#" are assumed comments.

The following is a sample glyph list file. This glyph list file maps Unicode private user areas to the Carta glyph name with some exceptions. (Space and digits remain as is.)

# Carta sample glyphlist file
# file name:carta-glyphname.txt
0020;space;
E000;circle;
E001;lookoutcontrol;
E002;triangle;
E003;diamond;
E004;hexagon;
E005;explode2;
E006;lookout;
E007;IRBM;
E008;ICBM;
E009;explode1;
E00A;ruin;
E00B;goldbar;
E00C;lighthouse;
E00D;mining;
E00E;gaging;
0030;zero;
0031;one;
0032;two;
0033;three;
0034;four;
0035;five;
0036;six;
0037;seven;
0038;eight;
0039;nine;
E00F;boundary;
...

Once the glyph list file has been made, the next step is to add the glyph list file entry to the font configuration file. If the Carta font is located in the /home/resource/fonts directory, the following <glyph-list> entry should be made.

<font-config>
  <font-folder path="[Install directory]/fonts">
    <glyph-list file="ZapfDingbats-glyphname.txt" afm="ZapfDingbats.afm"/>
  </font-folder>
  <font-folder path="/home/resource/fonts">
    <glyph-list file="carta-glyph-list.txt" afm="CR______.AFM"/>
  </font-folder>
</font-config>

Skipping the glyph name mapping

Another way to use the Carta font is to specify the <skip-glyphname-mapping> in the font configuration XML file for Rainbow PDF Server Based Converter V3.0 per for following example:

<font-config>
  <font-folder path="[Install directory]/fonts">
    <glyph-list file="zapfdingbats-glyphname.txt" afm="ZapfDingbats.afm"/>
  </font-folder>
  <font-folder path="/home/resource/fonts">
    <skip-glyphname-mapping afm="CR______.AFM"/>
  </font-folder>
</font-config>

If this option is specified for the .AFM file, all of the associated Unicode characters in document file are mapped to the characters in the PDF file as long as they are in the range of the font encoding. For instance, if the Unicode character is U+0021, this character will be written directly to the PDF file because Carta's encoding defines decimal value 33 as "circle". The Unicode character U+0101 will cause a missing glyph error, because it is not defined in the Carta's encoding. We can confirm which Unicode characters are available by consulting the .AFM files. Following is part of the Carta's .AFM file. If the Unicode character is equal to the number, which is to the right of the "C" character, it is available to use.

EncodingScheme FontSpecific
StartCharMetrics 189
C 32 ; WX 280 ; N space ; B 0 0 0 0 ;
C 33 ; WX 560 ; N circle ; B 30 150 530 650 ;
C 34 ; WX 620 ; N lookoutcontrol ; B 15 60 605 741 ;
...
C 250 ; WX 1042 ; N boat ; B 30 0 1012 280 ;
C 251 ; WX 852 ; N portofentry ; B 30 123 822 677 ;
C 252 ; WX 946 ; N whwycounty ; B 0 -58 946 857 ;
C 253 ; WX 1154 ; N whwytridown ; B 0 -100 1154 899 ;
C 254 ; WX 1072 ; N whwytriright ; B 0 -121 1073 919 ;
EndCharMetrics

Define the alias name of the font family

Some Type1 font family names are troublesome when installed. For instance, if you install Adobe product Eurostile Type1 font in .AFM+.PFB pair, there occurs a font selection problem depending on the font file combination. The following table describes the font family name problem for some font file combinations.

PFB name PFM information AFM information
WindowsName dfWeight dfItalic FullName FamilyName Weight ItalicAngle
EU______.PFB Eurostile 400 0 Eurostile Medium Eurostile Medium 0
EUB_____.PFB Eurostile Bold 400 0 Eurostile Bold Bold 0
EUEX____.PFB Eurostile ExtendedTwo 400 0 Eurostile Extended #2 Roman 0
EUBEX___.PFB Eurostile ExtendedTwo 700 0 Eurostile Bold Extended #2 Bold 0

If you use these fonts with .PFM+.PFB combination, there are no problems because the .PFM file exposes all the different font family names. In contrast, if you install these fonts with .AFM+.PFB combination, all of the font family names are Eurostile only. Furthermore, there are plural fonts that have the same weight value. The Weight value Medium and Roman are interpreted as font-weight="400" and Bold is interpreted as font-weight="700".

To avoid this problem, define a new family name using the alias element in the font configuration file. The following example defines the .PFM with like family name alias.

<font-config>
  <font-folder path="[Install directory]/fonts">
    <glyph-list file="ZapfDingbats.txt" afm="ZapfDingbats.afm"/>
  </font-folder>
  <font-folder path="/home/resource/fonts">
    <!-- Set the family-name and weight to the PFM definition -->
    <font-alias  file="EU______.AFM">
      <alias family-name="Adobe Eurostile"/>
    </font-alias>
    <font-alias  file="EUB_____.AFM">
      <alias family-name="Adobe Eurostile Bold" weight="normal"/>
    </font-alias>
    <font-alias  file="EUEX____.AFM">
      <alias family-name="Adobe Eurostile ExtendedTwo"/>
    </font-alias>
    <font-alias  file="EUBEX___.AFM">
      <alias family-name="Adobe Eurostile ExtendedTwo" weight="bold"/>
    </font-alias>
  </font-folder>
</font-config>
The newly defined family-name attribute of the font-alias element should be different from any other alias name in the font file. In addition, weight and italic combinations should be unique in the same family name groups.

WindowsName mode

Rainbow PDF Server Based Converter V3.0 Windows version can print the formatted results without generating a PDF file. Windows functionality is used to do this, thus the font usage is based on Windows. In other words, Windows accesses the fonts using WindowsName in the .PFM file. For this reason, there is a possibility mapping will fail if you use the FamilyName in the .AFM file. This problem can be avoided by specifying <name-processing-mode mode="windows-name"/> in the Font Configuration File. In this case you need to define the alias name for .AFM file because the .AFM file cannot be specified directly.

As a general rule Windows does not normally use/include the .AFM file, so this is not a common problem.

PDF Standard 14 Fonts

In non-Windows version, the following Adobe Type1 fonts are installed.

  • Courier.afm
  • Courier-Bold.afm
  • Courier-Oblique.afm
  • Courier-BoldOblique.afm
  • Helvetica.afm
  • Helvetica-Bold.afm
  • Helvetica-Oblique.afm
  • Helvetica-BoldOblique.afm
  • Times-Roman.afm
  • Times-Bold.afm
  • Times-Italic.afm
  • Times-BoldItalic.afm
  • Symbol.afm
  • ZapfDingbats.afm

Because .AFM or .PFM is not included in these, it is not possible to embed it in PDF. Please refer to the bundled MustRead.html before you use.

These fonts can be downloaded from PDF core font information.

TrueType font, OpenType (TrueType outline) font

This section describes Rainbow PDF Server Based Converter V3.0 implementation for TrueType and OpenType (TrueType outline) fonts. Tips on how to use these fonts in your environment are provided.

Font organization and necessary condition

TrueType fonts were originally developed by Apple Computer and have been used in the Windows environment. OpenType fonts were jointly developed by Adobe and Microsoft as cross-platform fonts. Due to the origin, OpenType fonts have two flavors/kinds. One has the TrueType outline. The other has the PostScript outline. OpenType font files that have the TrueType outline have the file extension .TTF or .TTC. OpenType font files that have the PostScript outline have the extension .OTF. This section treats original TrueType fonts and OpenType (TrueType outline) fonts together. From now on, we will use the term TrueType fonts as the contraction of TrueType font and OpenType (TrueType outline).

TrueType fonts are composed of a single file which has the extension .TTF or .TTC. TTC is the abbreviation of the TrueType Collection. It contains plural TrueType fonts in a single file structure. It is sometimes used in the CJK fonts.

TrueType font requirements:

  • Font must have the cmap table which enables mapping the Unicode to glyph index. (Almost TrueType fonts have the cmap table available.)
  • Some older TrueType fonts do not have Code Page information in the OS/2 table (ulCodePageRange1, 2) which can negatively influence Rainbow PDF Server Based Converter V3.0's font selection algorithms. For this reason we recommend not using old TrueType fonts.
Please visit the following sites to get more details about TrueType font (cmap table, etc)

Embedding TrueType fonts

Rainbow PDF Server Based Converter V3.0 supports embedding the TrueType font into PDF. One big difference is the embedding license. TrueType font has the license information in OS/2 table fsType field. Rainbow PDF Server Based Converter V3.0 respects this licensing information which will cause embedding errors when you specify font embedding against fonts with restrictions on embedding. In addition, only the used glyphs are embedded with the TrueType fonts.

The "PDF Reference" says that TrueType fonts should be embedded to get predictable behavior across all viewer applications. If you don't embed TrueType fonts into the PDF file, Adobe Acrobat or Reader sometimes reports errors for particular Unicode character and font combinations. For instance, if you do not embed TrueType fonts, which are used with Thai characters, Adobe Acrobat or Reader will report the "font not found" error when opening the PDF file, even if the actual font exists. In contrast, the fonts which are used with Arabic characters do not cause errors when not embedded.

OpenType (PostScript outline) font

This section describes how Rainbow PDF Server Based Converter V3.0 implements OpenType (PostScript outline) fonts. Tips on how to use OpenType fonts more conveniently in your environment are provided.

Font organization and necessary condition

OpenType (PostScript outline) is one flavor of OpenType fonts as described in Font organization and necessary condition. OpenType (PostScript outline) font files have an extension .OTF and consists of only a single file. In addition, OpenType(PostScript outline) is classified into two categories. One is OpenType (PostScript) CID font and the other is OpenType (PostScript) non-CID font. The following table gives a brief description of these categories.

TypeContentsTreatment in PDF
Non-CID font Mainly contains Latin character glyphs. Glyphs are indexed using glyph name. It is the same as Type1 font. Type1
CID fontMainly contains CJK ideograph glyphs. Glyphs are indexed using CID. Type0 (CIDFontType0)

OpenType is a new format standard requiring no special conditions to use it from Rainbow PDF Server Based Converter V3.0.

How to use OpenType (PostScript outline) fonts

The usage and family-name, font-weight, font-style mapping conditions are the same as for TrueType fonts. Please refer to the Font organization and necessary condition for details.

Some OpenType (PostScript outline) has the font-weight value which is not a multiple of 100. Rainbow PDF Server Based Converter V3.0 round off the font-weight value.

Embedding OpenType (PostScript outline) fonts

Font embedding is the same as for TrueType fonts. Please refer to the Embedding TrueType fonts for details.

Integrate the family name using the alias name

Some OpenType (PostScript outline) CID fonts have a family name defined per font file. Originally these fonts belonged to the same family and each font file has a different font-weight value.

Font file Family-name Weight Italic
HeiseiKakuGoStd-W3.otf "Heisei Kaku Gothic Std W3" 300 Normal
HeiseiKakuGoStd-W5.otf "Heisei Kaku Gothic Std W5" 500 Normal
HeiseiKakuGoStd-W7.otf "Heisei Kaku Gothic Std W7" 700 Normal
HeiseiKakuGoStd-W9.otf "Heisei Kaku Gothic Std W9" 900 Normal

In the Windows environment it is not allowed to have more than three weight-values in the same family name. (Macintosh does allows such combinations.) As a result, these fonts have different family name per font file. This makes it inconvenient to use these fonts using the different family name. To integrate the family names, the following alias descriptions to the font configuration file should be added.

<font-config>
  <font-folder path="[Install directory]/fonts">
    <glyph-list file="ZapfDingbats.txt" afm="ZapfDingbats.afm"/>
  </font-folder>
  <font-folder path="/home/resource/fonts">
    <!-- Integrate the four OTF font's family name to
         "Heisei Kaku Gothic Std"-->
    <font-alias  file="HeiseiKakuGoStd-W3.otf">
      <alias family-name="Heisei Kaku Gothic Std" weight="300" />
    </font-alias>
    <font-alias  file="HeiseiKakuGoStd-W5.otf">
      <alias family-name="Heisei Kaku Gothic Std" weight="500" />
    </font-alias>
    <font-alias  file="HeiseiKakuGoStd-W7.otf">
      <alias family-name="Heisei Kaku Gothic Std" weight="700" />
    </font-alias>
    <font-alias  file="HeiseiKakuGoStd-W9.otf">
      <alias family-name="Heisei Kaku Gothic Std" weight="900" />
    </font-alias>
  </font-folder>
</font-config>

EUDC

EUDC: End User Defined Character is available with Rainbow PDF Server Based Converter V3.0.

Since the information on EUDC is acquired from the registry, it is not necessary to create EUDC information to the Font Configuration File with Windows version. However when EUDC information is described by the Font Configuration File, it is also taken into consideration. With no-Windows version, it is necessary to create EUDC information to the Font Configuration File in order to use EUDC.

<font-config>
 <name-processing-mode mode="windows-name"/>
 <windows-registry reference="enable"/>
 <font-folder path="c:\Windows\Fonts"/>
 <eudc-processing mapping="enable">
  <eudc-range start="57344" end="63743">
  <eudc-system-default file-path="c:\Windows\Fonts\EUDC.TTE"/>
  <eudc-map family-name="MS Mincho" file-path="c:\Program Files\east\jinmei3\FEJPMIN.TTG"/>
  <eudc-map family-name="MS PMincho" file-path="c:\Program Files\east\jinmei3\FEJPMIN.TTG"/>
 </eudc-processing>
</font-config>

A user does not need to be conscious of utilizing EUDC. Rainbow PDF Server Based Converter V3.0 changes the font automatically by the character code.