Hash :
d42c68e8
        
        Author :
  
        
        Date :
2000-01-27T13:56:02
        
      
many new small, but important, changes there:
  - modified the interface of the "sfnt" module. There is now a function
    called "load_format_tag", and another called "load_directory".
    The first one is in charge of returning the 4-byte tag located at
    the beginning of a given font file. It understand TrueType collections
    and parses them automatically
    The second loads the table directory that is located just after
    the format tag.
    This is useful, because the "SFNT" storage scheme can be used by
    several distinct formats, each with its own format tag.
    The TrueType driver now checks the format tag in "src/truetype/ttobjs.c"
  - made some changes to "src/shared/t1types.h" to clearly separate the
    Type 1 font content from the rest of the T1_Face structure. This
    will be useful when adding the CFF/Type2 driver that will be able
    to reuse the "T1_Font" structure within a "TT_Font" one (which
    really describes a SFNT-based font file).
    Some changes in "src/type1" were thus performed to reflect this.
    Note that the current type1 driver will be discontinued in a
    distant future. More on this later..
      
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73
#include <sfdriver.h>
#include <ttload.h>
#include <ttsbit.h>
#include <ttpost.h>
#include <ttcmap.h>
#include <sfconfig.h>
#include <sfnt.h>
  static const SFNT_Interface  sfnt_interface =
  {
    TT_Goto_Table,
    
    TT_Load_Any,
    TT_Load_Format_Tag,
    TT_Load_Directory,
    TT_Load_Header,
    TT_Load_Metrics_Header,
    TT_Load_CMap,
    TT_Load_MaxProfile,
    TT_Load_OS2,
    TT_Load_PostScript,
    TT_Load_Names,
    TT_Free_Names,
    TT_Load_Hdmx,
    TT_Free_Hdmx,
    TT_Load_Kern,
    TT_Load_Gasp,
#ifdef TT_CONFIG_OPTION_EMBEDDED_BITMAPS
    /* see `ttsbit.h' */
    TT_Load_SBit_Strikes,
    TT_Load_SBit_Image,
    TT_Free_SBit_Strikes,
#else
    0,
    0,
    0,
#endif  
    
    /* see `ttpost.h' */
#ifdef TT_CONFIG_OPTION_POSTSCRIPT_NAMES 
    TT_Get_PS_Name,
    TT_Free_Post_Names,    
#else
    0,
    0,
#endif 
    /* see `ttcmap.h' */
    TT_CharMap_Load,
    TT_CharMap_Free,
  };
  
  EXPORT_FUNC
  const FT_DriverInterface  sfnt_driver_interface =
  {
    sizeof(FT_DriverRec),
    0,
    0,
    0,
    "sfnt",     /* driver name                         */
    1,          /* driver version                      */
    2,          /* driver requires FreeType 2 or above */
    (void*)&sfnt_interface
  };