home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: SysTools / SysTools.zip / ft-beta.zip / freetype / docs / freetype.txt < prev    next >
Text File  |  1997-10-06  |  27KB  |  646 lines

  1.                    The FREE TrueType Font Engine
  2.  
  3. *** DISCLAIMER : The information contained in this file is ************
  4. ********         severely outdated.                           ************
  5.  
  6. This document is a technical introduction to the FreeType project, an
  7. efficient, fast, portable TrueType font rendering engine, with *freely
  8. available* source code!. The reader's good knowledge of the TrueType Font
  9. specification is not required, though being an indeniable "plus" for the
  10. good understanding of the following.
  11.  
  12. ---------------------------------------------------------------------
  13.  
  14. TABLE OF CONTENTS:
  15.  
  16.    Introduction:
  17.  
  18. I. Engine Design Goals:
  19.  
  20.   1. Easy Maintenance.
  21.   2. System Independance.
  22.   3. Reliability.
  23.   4. High Quality.
  24.   5. Speed!
  25.  
  26. II. Engine Architecture:
  27.  
  28.   1. High-level Interface.
  29.   2. Component Hierarchy.
  30.   3. Runtime Execution.
  31.  
  32. II. Internals:
  33.  
  34.   1. Engine Memory Management.
  35.   2. Rasterizer mechanics.
  36.   3. Interpreting TrueType opcodes.
  37.  
  38. III. Engine Characteristics:
  39.  
  40.   1. Differences found between TrueType specs and real-world
  41.      font files.
  42.   2. Engine's behaviour with incorrect font files or glyphs.
  43.  
  44. IV. Still to do:
  45.  
  46.   1. Debug the whole interpreter...
  47.   2. Add more character-oriented functions.
  48.   3. Porting considerations (IMPORTANT).
  49.  
  50. --------------------------------------------------------------------
  51.  
  52. Introduction:
  53. -------------
  54.  
  55.   [ 'A Brief history of digital font technology' is under ]
  56.   [ complete rewrite...                                   ]
  57.  
  58. I. Engine Design Goals:
  59. -----------------------
  60.  
  61. This section describes the several goals the engine has been developped for:
  62.  
  63.  
  64.   - Easy maintenance :
  65.  
  66.       "Language is not all!!"
  67.  
  68.       In an age where all "serious" development is made in C or C++, the
  69.       author of FreeType decided originally to code the engine in PASCAL!
  70.       This choice may seem rather weird, but this language comes on the PC
  71.       with high-quality programming environments (namely Borland's for DOS,
  72.       and Virtual Pascal's on OS/2) that allow light-speed compilation, real
  73.       module separation and easy debugging. Moreover, the language's simple
  74.       design and strong typing allows safe development and short
  75.       compile/run/debug cycles.
  76.  
  77.       Of course, this had also several drawbacks (i.e. a poorly if ever
  78.       optimised generated code, and lack of "true" language portability) but
  79.       these could be easily tolerated during development as long as one
  80.       developer does not tie its code to very specific items of the
  81.       language.
  82.  
  83.       Being doomed by a poor performance from the compiled code ;),
  84.       development focused on algorithm fine-tuning rather than clever
  85.       macro-tricks or the tendency to optimise 'on the run' so common under
  86.       C programmers (a practice that very easily leads to strange and hardly
  87.       maintainable code).
  88.  
  89.       This approach, though quite constraining at first, paid back faster
  90.       than expected. Ultra-fast compile times allowed a lot of algorithmic
  91.       trials which finally led to a now very well crafted piece of software,
  92.       which runs fast even under Borland Pascal. A C version of the engine
  93.       has been written lately from the original Pascal source and seems to
  94.       be as stable as the Pascal version.
  95.  
  96.       The current version has been compiled and tested on Borland's 16-bit
  97.       Pascal Compilers (Turbo-Pascal, Borland-Pascal Real Mode, and
  98.       Borland-Pascal DPMI) as well as the 32-bit OS/2 Virtual Pascal
  99.       compiler (a *must-have*). The 32-bit version is about 2.5 to 3 times
  100.       faster than its 16-bit counterpart; this is mainly due to the fact
  101.       that most of the data processed by the engine is 32-bit, a painful
  102.       task for 16-bit programs...
  103.  
  104.       Compilation of the C version with GCC (all optimizations on) showed a
  105.       significant performance increase, at the cost of code size (namely
  106.       from 22kByte to 60kByte!!).
  107.  
  108.       As a whole, the engine proved several times to be highly readable and
  109.       maintainable. It takes about 9000 lines of commented and airy Pascal
  110.       code, which is quite small for such a piece of software. The C version
  111.       has about 4000 code lines (with very few comments, though---the main
  112.       reason for the smaller code size is the still lacking instruction
  113.       interpreter).
  114.  
  115.  
  116.   - System Independence *and* Portability:
  117.  
  118.       The Engine has been developed with portability in mind. This means
  119.       that we don't rely on any specific feature of the Pascal runtime
  120.       libraries. It thus manages resources in a specific way.
  121.  
  122.  
  123.           a. Memory management:
  124.  
  125.              A client application should first allocate a block of memory
  126.              and pass it to the engine at elaboration. The engine has no
  127.              interface to any external memory manager to allocate or release
  128.              chunks of memory. Rather, it will use the passed memory block,
  129.              called the Font Storage Pool, for all its needs. Deallocation
  130.              of the pool is left to the client application.
  131.  
  132.              This approach guarantees that the engine's memory requirements
  133.              during execution are limited to those defined by the client
  134.              application. Should the pool be too small, the engine will fail
  135.              to initialize or to load a font file in a gentle and
  136.              predictable way (typically with an error message).
  137.  
  138.           b. File operations:
  139.  
  140.              A simple unit called 'File' provides a basic I/O layer using
  141.              the simple Pascal FILE type (unbuffered file access). New
  142.              instances of 'File' can be written to take care of buffered or
  143.              memory-mapped files access when possible, or other system I/O
  144.              routines.
  145.  
  146.           c. Endianess:
  147.  
  148.              TrueType is built on big-endianess, used typically on Motorola
  149.              processors, where the high order byte is always in the first
  150.              memory position, while the lowest is in the last.
  151.  
  152.              Endianess plays a role when reading data from the font file,
  153.              and when extracting constant values from the instruction
  154.              stream. In the modules where it is important ('Tables' and
  155.              'Ins'), the short/long int access has been well defined, and
  156.              ports to platforms with a different endianess has shown that
  157.              this causes only minor problems which will be removed
  158.              completely in future versions.
  159.  
  160.           d. Processor Arithmetic:
  161.  
  162.              The TrueType specs clearly defines fixed point formats that are
  163.              fitted for 32-bits 2's complement arithmetic.
  164.  
  165.              The DOS (Borland Pascal) version of the engine works in 16-bit
  166.              mode to process 32-bit values which is rather painful (but
  167.              consider the fact that the Windows 3.11 engine works only on
  168.              16-bit values and thus has well-known problems when rendering
  169.              to large scales while printing).
  170.  
  171.              Unfortunately, any decent implementation would require a great
  172.              amount of fixed point conversions spread in many parts of the
  173.              engine. This has not been done yet, so consider FreeType a 2's
  174.              complement-only project until now...
  175.              
  176.  
  177.   - Reliability and Predictable Behaviour:
  178.  
  179.       This means that in the case of processing a corrupt font file, the
  180.       engine will react gently by delivering an error message, rather than
  181.       puking garbage at the screen or at the application's memory space.
  182.       This is important if one wants to make the engine part of a windowing
  183.       system (its authors are considering seriously to write a TrueType
  184.       subsystem for OS/2, and maybe an X11 TrueType font server) and keep
  185.       it stable.
  186.  
  187.  
  188.   - High Quality:
  189.  
  190.       The quality of the rendered glyphs should equal those found on the
  191.       Windows and Macintosh platforms. This implies an accurate rasterizer
  192.       (did you ask for *smooth* splines? ;), as well as a real TrueType
  193.       bytecode interpreter (did you ask for good hinting? ;).
  194.  
  195.       Most shareware/commercial TrueType libraries do not include both
  196.       components. Their overall rendering quality is consequently poor to
  197.       disastrous, especially with small characters.
  198.  
  199.       The FreeType Engine is currently the only freely available library
  200.       with support for TT instructions which comes with source code. It will
  201.       be placed under the GPL when finished.
  202.  
  203.       NOTE:  Win95-style'a anti-aliasing "technology" is not considered
  204.              seriously right now.. This being a matter of time, not of
  205.              competence :-)
  206.  
  207.  
  208.   - Speed:
  209.  
  210.       This may surprise the many programmers who think that portable code is
  211.       forced to be inefficient. The idea is to fine-tune every piece of
  212.       algorithm found in this engine, as long as it stays on touch with its
  213.       goals (accuracy, portability, maintainability).
  214.  
  215.       For example, appropriate research led the rasterizer to become faster,
  216.       more accurate, and less memory-consuming as time passed. This is
  217.       Pascal code, with zero, nilch, nada, optimization; however, it
  218.       flies... just test it!
  219.  
  220.  
  221.  
  222. II. Engine Architecture:
  223.  
  224.  
  225.   1. High-level Interface:
  226.   ------------------------
  227.  
  228.   The unit 'FreeType.Pas' (or "freetype.h") is the engine's high level
  229.   #interface. It is the only source that should be used (or include'd in C)
  230.   by a client application in the final release. It defines a few necessary
  231.   types.
  232.  
  233.   2. Component hierarchy:
  234.   -----------------------
  235.  
  236.   The engine is made up of a lot of tiny components, each with a
  237.   well-defined role. A component is simply a Pascal unit (or C source file)
  238.   which name begins with the prefix 'TT' (or 'tt' for C components). Hence,
  239.   the 'Types' component is in file 'TTTypes.Pas' (or "tttypes.h" and
  240.   "tttypes.c").
  241.  
  242.   We will now describe the components:
  243.  
  244.     a. Base Components:
  245.  
  246.       - 'Types':
  247.             Specification of the engine's most used internal types. It holds
  248.             no code nor data.
  249.  
  250.       - 'Error':
  251.             Definition of common error codes and of the global 'Error'
  252.             variable.
  253.  
  254.       - 'Calc':
  255.             This component holds all the computation  routines needed by the
  256.             engine. It comes in three flavours: a portable and slow version,
  257.             as well as two inline assembly optimized versions for the most
  258.             often used computations (for 16 and 32 bits modes, Intel i386
  259.             assembly). The C version is only portable (but gcc does
  260.             wonders!!---if we have time we will implement GNU assembler code
  261.             too).
  262.  
  263.       - 'Memory':
  264.             A very simple component implementing a growing heap with only
  265.             Alloc/Mark/Release operations. This is by far the simplest and
  266.             fastest memory management you can find, though it requires a
  267.             programmer taking care of the orders of allocations. We *do*
  268.             take care :)
  269.  
  270.       - 'File':
  271.             A simple file abstraction component. It could be modified later
  272.             to support buffered file access or memory-mapped files.
  273.  
  274.       - 'Disp':
  275.             This component is not portable but very useful for debugging, as
  276.             it manages the display to a simple graphics screen (640x480x2
  277.             and 320x200x256)
  278.  
  279.       - 'Tables':
  280.             A simple specification of the TrueType tables types and various
  281.             functions to load/search/use them.
  282.  
  283.     b. Advanced Components:
  284.  
  285.       - 'Raster':
  286.             This component is the scan-line renderer. It will convert any
  287.             glyph description into a bitmap. Fast and accurate. Now supports
  288.             graylevel rendering. This module is not dependent on the rest of
  289.             the library; it could be e.g. used for a PS rasterizer too.
  290.  
  291.       - 'Ins':
  292.  
  293.             The TrueType byte-code interpreter. Still about 5% lacking
  294.             functionality, and a lot of things to debug...
  295.  
  296.     c. Test programs:
  297.  
  298.       - 'Timer':
  299.             A program used to test the rendering performance of 'Raster'.
  300.             Define 'VIRTUAL' if you want to enable bitmap display (you will
  301.             then time both Raster's performance and buffer->VRAM copy).
  302.  
  303.       - 'Zoom':
  304.             A simple program used to view any glyph from a TrueType font
  305.             file. Can scale and rotate them.
  306.  
  307.       - 'Debug':
  308.             Still under construction. A full-screen debugger for the
  309.             byte-code interpreter. We'll dearly need it during development.
  310.  
  311.             Using Borland's Turbo Vision Windowing Lib it may not make it to
  312.             a C version, but hey, that's only debugging !!
  313.  
  314.  
  315.   2. Runtime execution:
  316.   ---------------------
  317.  
  318.     a. The Storage Pool:
  319.  
  320.        Though written in Pascal, the engine has been developed to be as
  321.        platform, language, and system independent as possible. This simply
  322.        means two things:
  323.  
  324.        The features, like File I/O, dependent on a specific runtime library
  325.        or system have been moved to well chosen modules, which are the only
  326.        ones that shall be touched to port the engine.
  327.  
  328.        Moreover, the engine provides its own memory management routines. A
  329.        client application should allocate a memory block with its own
  330.        implementation of 'malloc', 'GetMem', or wathever similar function,
  331.        and pass a pointer and its size at engine elaboration.
  332.  
  333.        This block is called the Storage Pool, as all engine routines
  334.        will allocate memory from it.
  335.  
  336.  
  337.     b. The Interpreter:
  338.  
  339.       - code ranges:
  340.  
  341.            To be written.
  342.  
  343.  
  344.     c. The Rasterizer:
  345.  
  346.       - pixel coordinates:
  347.  
  348.           According to the TrueType specifications, all pixel coordinates
  349.           managed by the rasterizer are in 6 bits fixed float format coded
  350.           on 32 bits (the famous F26dot6 type).
  351.  
  352.       - contours:
  353.  
  354.           A contour is a closed, oriented curve giving the borders of the
  355.           regions to be filled when rasterizing a glyph. One glyph is
  356.           commonly described using several contours.
  357.  
  358.           According to the TrueType specs, contours must be oriented so that
  359.           the filled region is to the right of the contour orientation.
  360.           Unfortunately, many freely available fonts do not respect this
  361.           simple rule! FreeType can handle even such non-standard fonts.
  362.  
  363.           Contours are given to the rasterizer as sets of segments and
  364.           simple arcs (second-degree Bezier polynomials).
  365.  
  366.           They are first converted to sets of "Profiles".
  367.  
  368.  
  369.       - profiles:
  370.  
  371.           Put it simply, a "profile" is a contour's portion that can only be
  372.           either ascending or descending, i.e. it is monotonous in the
  373.           vertical direction. There is no such thing as a horizontal
  374.           profile, as we shall see.
  375.  
  376.           Here are a few examples:
  377.  
  378.  
  379.           this square
  380.                                             1         2
  381.            ---->----     is made of two
  382.           |         |                       |         |
  383.           |         |       profiles        |         |
  384.           ^         v                       ^    +    v
  385.           |         |                       |         |
  386.           |         |                       |         |
  387.            ----<----
  388.  
  389.                                           up         down
  390.  
  391.          this triangle
  392.  
  393.               P2                             1          2
  394.  
  395.               |\        is made of two       |         \
  396.            ^  | \  \                         |          \
  397.            | |   \  \      profiles         |            \      |
  398.           |  |    \  v                  ^   |             \     |
  399.             |      \                    |  |         +     \    v
  400.             |       \                   |  |                \
  401.          P1 ---___   \                     ---___            \
  402.                   ---_\                          ---_         \
  403.               <--__     P3                   up           down
  404.  
  405.  
  406.  
  407.           A more general contour can be made of more than
  408.                            two profiles :
  409.  
  410.              __     ^
  411.             /  |   /  ___          /    |
  412.            /   |     /   |        /     |       /     |
  413.           |    |    /   /    =>  |      v      /     /
  414.           |    |   |   |         |      |     ^     |
  415.        ^  |    |___|   |  |      ^   +  |  +  |  +  v
  416.        |  |           |   v      |                 |
  417.           |           |          |           up    |
  418.           |___________|          |    down         |
  419.  
  420.                <--               up              down
  421.  
  422.  
  423.           Successive profiles are always joined by horizontal segments that
  424.           may or may not be visible according to their coordinates.
  425.  
  426.           Each profile is an array that associates one horizontal *pixel
  427.           coordinate* to each bitmap *scanline* crossed by the contour's
  428.           section represented by the profile.
  429.  
  430.           They are stored in a part of the Storage Pool called the Render
  431.           Pool.
  432.  
  433.  
  434.       - table overflow and sub-banding:
  435.  
  436.            Some glyphs are really made from a good number of profiles, each
  437.            taking some memory (especially at high resolutions like when
  438.            rendering to a print bitmap buffer!). As the Storage Pool is
  439.            limited, the engine can automatically detect a "table overflow"
  440.            and then reconsider the way it will render the glyph.
  441.  
  442.            Indeed, in case of overflow, the glyph will be sliced into
  443.            several horizontal strips, each taking less scanlines than
  444.            before, with each strip rendered separately. Inspite of this
  445.            "sub-banding" mechanism the generated bitmap will be exactly the
  446.            same. It will only take a little while longer for computation.
  447.  
  448.            Tests have shown that the time taken by the sub-banding process
  449.            is not exhaustive (typically, a 4kByte Pool will render less than
  450.            twice slower than a 32kByte Pool!!).
  451.  
  452.  
  453.        - spans:
  454.  
  455.            When all profile tables are computed, the glyph is rendered in
  456.            the destination bitmap. The algorithm used is quite
  457.            straightforward:
  458.  
  459.            the vertical axis is swept for the presence of profiles, and
  460.            spans are drawn joining 'up' and 'down' profiles, sorted in the
  461.            horizontal direction (see any good book on polygon filling for
  462.            more details).
  463.  
  464.            The dropout-control rules, defined in the TrueType specs, are
  465.            also used in the case of 'small' (i.e. pixel-sized) spans, and
  466.            an additional sweep of the horizontal axis is added to manage
  467.            horizontal dropouts when required.
  468.  
  469.  
  470.        - beziers :
  471.  
  472. --------------------- Sorry, this document is not finished yet ..
  473. 1. Engine goals:
  474.  
  475.   The  engine have been  designed and  developed with  the following
  476.   ideas in mind:
  477.  
  478.   - To be a quality, efficient and free TrueType _glyph_ renderer:
  479.  
  480.         Though the TrueType specification is published and available
  481.         from Apple and Microsoft, this document reveals surprisingly
  482.         fuzzy  definitions and  features descriptions  that  make it
  483.         _very_ hard to implement a 'correct' TrueType engine.
  484.         
  485.         In  particular, the hinting  mechanism, performed  through a
  486.         specific bytecode interpreter, is described in ambiguous and
  487.         misleading terms, even though being TrueType's key component
  488.         for _any_  decent rendering of  glyphs on the screen  (or at
  489.         small  point  sizes).   Readers  can refer  to  the  engines
  490.         provided by OS/2 and BeOS for examples of 'klunky' engines.
  491.  
  492.         Though being a cleanroom implementation, the FreeType engine
  493.         now  matches  extremely  well  the quality  of  the  bitmaps
  494.         produced  by   Windows  and  the   Macintosh,  even  without
  495.         anti-aliasing!  Moreover, it  is free, available with source
  496.         code under both a LGPL and BSD-style license.
  497.  
  498.         Great care has been taken to keep it small, and to date, the
  499.         core engine alone  represents less than 55 kByte  of code on
  500.         Intel platforms.
  501.  
  502.  
  503.   - to be a solid, and _portable_ base for all kinds of font servers
  504.     and libraries:
  505.  
  506.         The  core engine doesn't  depend on  any system  or compiler
  507.         specific items  (note that the test programs  that come with
  508.         it  can!),  and  can  be  compiled on  a  great  variety  of
  509.         platforms.  It is written in ANSI C.
  510.  
  511.         The distribution  release uses the ANSI C  library to manage
  512.         memory,  i/o and  synchronisation,  but the  source code  is
  513.         modular enough to  replace the related components, tailoring
  514.         the library to your own specific systemif necessary.
  515.  
  516.         It is  also independent  of any windowing  system's metrics,
  517.         and  only deals  with the  ones introduced  in  the TrueType
  518.         specification.  It can then be used as a solid base for very
  519.         distinct font servers  or applications.  Earlier versions of
  520.         the engine has been already used in :
  521.  
  522.            - a prototype font server for OS/2
  523.            - a prototype font server for X11
  524.            - a conversion tool called 'ttf2bdf'
  525.  
  526.         The engine itself has been compiled and run on MS DOS, OS/2,
  527.         Linux, Amiga, and other Unix variants with no problems.
  528.  
  529.         We  hope  to  make  thus  TrueType  available  on  the  most
  530.         platforms.
  531.  
  532.   - to be easily extensible to new specifications:
  533.  
  534.         The  FreeType  core engine  only  deals  with the  mandatory
  535.         TrueType  tables, which is  enough to  load and  display the
  536.         glyphs  of any font.   However, it  includes a  mechanism to
  537.         allow you  to extend it  easily, without modifying  parts of
  538.         the core library, to support additional tables.
  539.  
  540.         Extending the engine can be used to:
  541.  
  542.         - access  optional   tables  that  may   interest  your  own
  543.           application   (like   PCL5,   vertical   metrics,   linear
  544.           threshold, etc.)
  545.  
  546.         - support new specifications  of the TrueType format.  These
  547.           include support for TrueType GX and/or OpenType, which are
  548.           both extensions of the original TrueType font file format,
  549.           presenting new tables.
  550.  
  551.  
  552.   What is doesn't do:
  553.   
  554.   There are  a number of  features that the engine  doesn't perform,
  555.   and never will.  Usually, these are features that are already part
  556.   of   many  windowing  systems,   and  that   we  didn't   want  to
  557.   re-implement. The main 'no-ways' are:
  558.  
  559.  
  560.     - It doesn't cache glyph bitmaps:
  561.  
  562.         A  typical font  server  always need  to  cache the  bitmaps
  563.         generated   most   lately  in   order   to  get   acceptable
  564.         performance.  Because  this relates  too closely to  the way
  565.         memory is managed by  the windowing system, and because some
  566.         graphics environments already provide this feature (and only
  567.         invoke  their font  servers to  _generate_ the  bitmaps), we
  568.         didn't include this in the engine.
  569.  
  570.         You may have to implement caching yourself if you want it in
  571.         your  application  that doesn't  rely  on  such a  windowing
  572.         system.
  573.  
  574.  
  575.     - It doesn't produce 'string text':
  576.  
  577.         The  FreeType engine  is  only able  to generate  individual
  578.         glyph  bitmaps and  let you  access glyph  and  font metrics
  579.         (like character  height, kerning, etc.).   However, its role
  580.         is not to produce string text; our reasons are simple:
  581.  
  582.           - blitting  is  now  performed  very efficiently  by  most
  583.             windowing  systems, and there's  no reason  to implement
  584.             our own slower routines to do it in the engine.
  585.  
  586.           - building  string  bitmaps   can  be  performed  in  many
  587.             different  ways  (with  or  without  kerning,  computing
  588.             advance  widths  in  pixels  or EM  units,  etc.),  each
  589.             application having its own needs for it.
  590.  
  591.           - some graphics environments  already provide this feature
  592.             from the  individual glyph bitmaps produced  by the font
  593.             engine (and usually, they  also cache these bitmaps), in
  594.             a very satisfying way.
  595.  
  596.  
  597.     - It doesn't perform rotation and stretching:
  598.  
  599.         The   engine   will  not,   on   its   own,  perform   these
  600.         transformations on  the glyphs  extracted from a  font file.
  601.         You must, as a client application, or a font server, do them
  602.         by yourself.  You can,  however, use some functions provided
  603.         by   the   FreeType   high-level   API   to   apply   simple
  604.         transformations to a glyph outline.  Nevertheless, this work
  605.         must  be queried explicitly  by the  client application/font
  606.         server.  The reasons for this are:
  607.  
  608.           - there  is   no  valid  reason   to  inject  trigonometry
  609.             functions (like cosine/sine  tables) _within_ the engine
  610.             (btw, it doesn't use floating point arithmetic)!
  611.  
  612.           - simple  transformations, like 2x2  matrix multiplication
  613.             and  translation  can be  performed  with  an API  call.
  614.             However,  you'll  have to  setup  the matrix/vectors  by
  615.             yourself to  your correct values  (there is no  API like
  616.             'rotate by 10 degrees counter-clockwise').
  617.  
  618.           - the  engine  doesn't  perform   these operations, but it
  619.             _supports_ them.   This  means  that  you  have  ways to
  620.             notify the hinting component (the bytecode  interpreter)
  621.             that  the glyphs will be rotated and/or stretched.  This
  622.             information is taken by the glyph programs to alter  the
  623.             rendering process in order to get best displayed results.
  624.             
  625.  
  626.     - It doesn't interpret kerning information:
  627.  
  628.         Though it comes with a 'standard' extension that reveals the
  629.         kerning  information found  in a  TrueType file,  it doesn't
  630.         'cook'  the  kerning  tables   in  any  way,  and  lets  the
  631.         application  interpret this  data on  its own.   The reasons
  632.         are:
  633.  
  634.             - kerning  isn't needed  by  all platforms/library  (and
  635.               there  are  various   kinds  of  kerning:  horizontal,
  636.               vertical, etc.).
  637.  
  638.             - there  are several  kerning sub-tables  formats, which
  639.               can  be  interpreted  differently on  some  platforms.
  640.               Most  of these  are unused  anyway, thus  there  is no
  641.               incentive  to  provide  routines  to  perform  complex
  642.               analysis and processing of these tables.
  643.  
  644.  
  645.  
  646.