1. Independent font files
There are three types:
Type 1 Font
TrueType font
Opentype font
Type 1
Developed by Adobe, It is a postscript-based font, which is generally described by two separate files:
1. Adobe font metrics [Adobe]/Printer Font metrics [Microsoft]
Used to describe the space used by each glyph
2. PostScript font binary
Used to draw each glyph.
14 special types of fonts are selected as default fonts supported by PDF. They are calledStandard type1 Fonts, Each PDF viewer should provide these 14 fonts by default. Therefore, PDF files using these fonts do not need to be embedded into the PDF file, reducing the size of the PDF file.
TrueType
It was developed by Apple to combat the type 1 Font. However, this font type has just been released and the type 1 standard has also been published.
TrueType is a standard font file for Windows operating systems.
Comparison of Type 1 and TrueType font advantages and disadvantages, refer to: http://www.pdf-tech.com /? P = 981
Type1 uses a cubic besell curve to describe the shape, while TrueType uses a quadratic besell curve to describe the shape. Therefore, type1 fonts are more precise and beautiful than TrueType fonts. One misunderstanding is that type1 fonts occupy more space than TrueType fonts. This is because we also describe a circle. The Quadratic besell curve only requires eight key points and seven quadratic curves. The cubic besell curve requires 12 key points and 11 cubic curves. However, in general, type1 is about 10% less than TrueType. This is because TrueType must use more key points for slightly complex glyphs to maintain smoothness. Most modern printers use PDL as the printing Description Language. Therefore, true1 fonts do not produce deformation during printing, which is fast. TrueType needs to be translated into PDL due to curve equation changes, it also produces some deformation, which is not as beautiful as type1.
In this case, type1 should be more advantageous than TrueType. Why is TrueType more widely used on today's computers than type1?
This is because first: because of the complexity of the font equation of type1, it takes a lot of time to render the screen. The solution is that most type1 fonts are embedded with dot matrix fonts, which makes rendering faster, however, the edges are not smooth and ugly. Many PS documents and PS-converted PDF documents are like this. The font is ugly when browsing on the computer, but the print is beautiful. TrueType rendering is faster and can be smoothly displayed on the screen.
The second reason is the high usage fee of type1, which makes type1 not supported by all operating systems. In the Windows family, only OS/2 and Windows 2000 and later versions support type1. Due to this problem, Adobe has to embed Adobe Type Manager (ATM) in all its products as a rendering engine.
To sum up, the type 1 font is more precise and suitable for printer devices supporting PDL, while TrueType is more suitable for rendering on the screen, which is fast and beautiful.
Opentype font
OpenType is the final product of the competition between type1 and TrueType. In 1995, Adobe and Microsoft joined hands to develop a type compatible with type1 and TrueType, which truly supports Unicode fonts. Later on, they were officially named OpenType. OpenType can be embedded into type1 and TrueType, which has both the characteristics of both. Whether it is on the screen or printing, the quality is very good.
OpenType is a more compatible method, compatible with the above two fonts; in addition, Unicode is also its biggest highlight.
The OpenType file containing type 1 is the. otf suffix, And the OpenType file containing TrueType is the. TTF suffix.
OpenType can also contain a set of TrueType fonts, that is, the. TTC file.
2. Font types supported by PDF
In addition to the Type 1 and TrueType fonts, PDF also supports a font type described by the graphics operator of the PDF, named type 3.
In addition, to support languages with super-large character sets, such as Chinese character sets, PDF also supports a Type 0 font called composite font.
Simple font only supports character encoding in the range of 0 to, while composite font cmap can support character encoding in the range of 0.
Composite font consists of two components: cidfont and cmap.
Cidfont: character identifier font
Font file describing the glyph drawing parameters
Cmap: Character Map, aka character encoding, AKA code page
Charing between character and glyph
Cmap is a very effective method. It provides a temporary and small code page to establish the relationship between characters actually used in PDF files and font files, for example, winansi and identity_h are both character encoding. However, using indentity_h can effectively reduce the size of embedded fonts.
Font and PDF