text:
/***************************************************************************/
/*                                                                         */
/*  svttglyf.h                                                             */
/*                                                                         */
/*    The FreeType TrueType glyph service.                                 */
/*                                                                         */
/*  Copyright 2007-2017 by                                                 */
/*  David Turner.                                                          */
/*                                                                         */
/*  This file is part of the FreeType project, and may only be used,       */
/*  modified, and distributed under the terms of the FreeType project      */
/*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
/*  this file you indicate that you have read the license and              */
/*  understand and accept it fully.                                        */
/*                                                                         */
/***************************************************************************/

#ifndef SVTTGLYF_H_
#define SVTTGLYF_H_

#include FT_INTERNAL_SERVICE_H
#include FT_TRUETYPE_TABLES_H

FT_BEGIN_HEADER

#define FT_SERVICE_ID_TT_GLYF  "tt-glyf"

  typedef FT_ULong
  (*TT_Glyf_GetLocationFunc)( FT_Face    face,
                              FT_UInt    gindex,
                              FT_ULong  *psize );

  FT_DEFINE_SERVICE( TTGlyf )
  {
    TT_Glyf_GetLocationFunc  get_location;
  };

#ifndef FT_CONFIG_OPTION_PIC

#define FT_DEFINE_SERVICE_TTGLYFREC( class_, get_location_ )  \
  static const FT_Service_TTGlyfRec  class_ =                 \
  {                                                           \
    get_location_                                             \
  };

#else /* FT_CONFIG_OPTION_PIC */

#define FT_DEFINE_SERVICE_TTGLYFREC( class_, get_location_ )  \
  void                                                        \
  FT_Init_Class_ ## class_( FT_Service_TTGlyfRec*  clazz )    \
  {                                                           \
    clazz->get_location = get_location_;                      \
  }

#endif /* FT_CONFIG_OPTION_PIC */

  /* */

FT_END_HEADER

#endif /* SVTTGLYF_H_ */

/* END */


text:
/***************************************************************************/
/*                                                                         */
/*  svsfnt.h                                                               */
/*                                                                         */
/*    The FreeType SFNT table loading service (specification).             */
/*                                                                         */
/*  Copyright 2003-2017 by                                                 */
/*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
/*                                                                         */
/*  This file is part of the FreeType project, and may only be used,       */
/*  modified, and distributed under the terms of the FreeType project      */
/*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
/*  this file you indicate that you have read the license and              */
/*  understand and accept it fully.                                        */
/*                                                                         */
/***************************************************************************/

#ifndef SVSFNT_H_
#define SVSFNT_H_

#include FT_INTERNAL_SERVICE_H
#include FT_TRUETYPE_TABLES_H

FT_BEGIN_HEADER

  /*
   *  SFNT table loading service.
   */

#define FT_SERVICE_ID_SFNT_TABLE  "sfnt-table"

  /*
   * Used to implement FT_Load_Sfnt_Table().
   */
  typedef FT_Error
  (*FT_SFNT_TableLoadFunc)( FT_Face    face,
                            FT_ULong   tag,
                            FT_Long    offset,
                            FT_Byte*   buffer,
                            FT_ULong*  length );

  /*
   * Used to implement FT_Get_Sfnt_Table().
   */
  typedef void*
  (*FT_SFNT_TableGetFunc)( FT_Face      face,
                           FT_Sfnt_Tag  tag );

  /*
   * Used to implement FT_Sfnt_Table_Info().
   */
  typedef FT_Error
  (*FT_SFNT_TableInfoFunc)( FT_Face    face,
                            FT_UInt    idx,
                            FT_ULong  *tag,
                            FT_ULong  *offset,
                            FT_ULong  *length );

  FT_DEFINE_SERVICE( SFNT_Table )
  {
    FT_SFNT_TableLoadFunc  load_table;
    FT_SFNT_TableGetFunc   get_table;
    FT_SFNT_TableInfoFunc  table_info;
  };

#ifndef FT_CONFIG_OPTION_PIC

#define FT_DEFINE_SERVICE_SFNT_TABLEREC( class_, load_, get_, info_ )  \
  static const FT_Service_SFNT_TableRec  class_ =                      \
  {                                                                    \
    load_, get_, info_                                                 \
  };

#else /* FT_CONFIG_OPTION_PIC */

#define FT_DEFINE_SERVICE_SFNT_TABLEREC( class_, load_, get_, info_ ) \
  void                                                                \
  FT_Init_Class_ ## class_( FT_Service_SFNT_TableRec*  clazz )        \
  {                                                                   \
    clazz->load_table = load_;                                        \
    clazz->get_table  = get_;                                         \
    clazz->table_info = info_;                                        \
  }

#endif /* FT_CONFIG_OPTION_PIC */

  /* */

FT_END_HEADER

#endif /* SVSFNT_H_ */

/* END */

repo_name: JoshParnell/libphx

repo_language: C

mime_type: text/x-c++


text:
/***************************************************************************/
/*                                                                         */
/*  svcid.h                                                                */
/*                                                                         */
/*    The FreeType CID font services (specification).                      */
/*                                                                         */
/*  Copyright 2007-2017 by                                                 */
/*  Derek Clegg and Michael Toftdal.                                       */
/*                                                                         */
/*  This file is part of the FreeType project, and may only be used,       */
/*  modified, and distributed under the terms of the FreeType project      */
/*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
/*  this file you indicate that you have read the license and              */
/*  understand and accept it fully.                                        */
/*                                                                         */
/***************************************************************************/

#ifndef SVCID_H_
#define SVCID_H_

#include FT_INTERNAL_SERVICE_H

FT_BEGIN_HEADER

#define FT_SERVICE_ID_CID  "CID"

  typedef FT_Error
  (*FT_CID_GetRegistryOrderingSupplementFunc)( FT_Face       face,
                                               const char*  *registry,
                                               const char*  *ordering,
                                               FT_Int       *supplement );
  typedef FT_Error
  (*FT_CID_GetIsInternallyCIDKeyedFunc)( FT_Face   face,
                                         FT_Bool  *is_cid );
  typedef FT_Error
  (*FT_CID_GetCIDFromGlyphIndexFunc)( FT_Face   face,
                                      FT_UInt   glyph_index,
                                      FT_UInt  *cid );

  FT_DEFINE_SERVICE( CID )
  {
    FT_CID_GetRegistryOrderingSupplementFunc  get_ros;
    FT_CID_GetIsInternallyCIDKeyedFunc        get_is_cid;
    FT_CID_GetCIDFromGlyphIndexFunc           get_cid_from_glyph_index;
  };

#ifndef FT_CONFIG_OPTION_PIC

#define FT_DEFINE_SERVICE_CIDREC( class_,                                   \
                                  get_ros_,                                 \
                                  get_is_cid_,                              \
                                  get_cid_from_glyph_index_ )               \
  static const FT_Service_CIDRec class_ =                                   \
  {                                                                         \
    get_ros_, get_is_cid_, get_cid_from_glyph_index_                        \
  };

#else /* FT_CONFIG_OPTION_PIC */

#define FT_DEFINE_SERVICE_CIDREC( class_,                                   \
                                  get_ros_,                                 \
                                  get_is_cid_,                              \
                                  get_cid_from_glyph_index_ )               \
  void                                                                      \
  FT_Init_Class_ ## class_( FT_Library          library,                    \
                            FT_Service_CIDRec*  clazz )                     \
  {                                                                         \
    FT_UNUSED( library );                                                   \
                                                                            \
    clazz->get_ros                  = get_ros_;                             \
    clazz->get_is_cid               = get_is_cid_;                          \
    clazz->get_cid_from_glyph_index = get_cid_from_glyph_index_;            \
  }

#endif /* FT_CONFIG_OPTION_PIC */

  /* */

FT_END_HEADER

#endif /* SVCID_H_ */

/* END */


text:
/***************************************************************************/
/*                                                                         */
/*  svgldict.h                                                             */
/*                                                                         */
/*    The FreeType glyph dictionary services (specification).              */
/*                                                                         */
/*  Copyright 2003-2017 by                                                 */
/*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
/*                                                                         */
/*  This file is part of the FreeType project, and may only be used,       */
/*  modified, and distributed under the terms of the FreeType project      */
/*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
/*  this file you indicate that you have read the license and              */
/*  understand and accept it fully.                                        */
/*                                                                         */
/***************************************************************************/

#ifndef SVGLDICT_H_
#define SVGLDICT_H_

#include FT_INTERNAL_SERVICE_H

FT_BEGIN_HEADER

  /*
   *  A service used to retrieve glyph names, as well as to find the
   *  index of a given glyph name in a font.
   *
   */

#define FT_SERVICE_ID_GLYPH_DICT  "glyph-dict"

  typedef FT_Error
  (*FT_GlyphDict_GetNameFunc)( FT_Face     face,
                               FT_UInt     glyph_index,
                               FT_Pointer  buffer,
                               FT_UInt     buffer_max );

  typedef FT_UInt
  (*FT_GlyphDict_NameIndexFunc)( FT_Face     face,
                                 FT_String*  glyph_name );

  FT_DEFINE_SERVICE( GlyphDict )
  {
    FT_GlyphDict_GetNameFunc    get_name;
    FT_GlyphDict_NameIndexFunc  name_index;  /* optional */
  };

#ifndef FT_CONFIG_OPTION_PIC

#define FT_DEFINE_SERVICE_GLYPHDICTREC( class_,                        \
                                        get_name_,                     \
                                        name_index_)                   \
  static const FT_Service_GlyphDictRec  class_ =                       \
  {                                                                    \
    get_name_, name_index_                                             \
  };

#else /* FT_CONFIG_OPTION_PIC */

#define FT_DEFINE_SERVICE_GLYPHDICTREC( class_,                        \
                                        get_name_,                     \
                                        name_index_)                   \
  void                                                                 \
  FT_Init_Class_ ## class_( FT_Library                library,         \
                            FT_Service_GlyphDictRec*  clazz )          \
  {                                                                    \
    FT_UNUSED( library );                                              \
                                                                       \
    clazz->get_name   = get_name_;                                     \
    clazz->name_index = name_index_;                                   \
  }

#endif /* FT_CONFIG_OPTION_PIC */

  /* */

FT_END_HEADER

#endif /* SVGLDICT_H_ */

/* END */


text:
/***************************************************************************/
/*                                                                         */
/*  svttcmap.h                                                             */
/*                                                                         */
/*    The FreeType TrueType/sfnt cmap extra information service.           */
/*                                                                         */
/*  Copyright 2003-2017 by                                                 */
/*  Masatake YAMATO, Redhat K.K.,                                          */
/*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
/*                                                                         */
/*  This file is part of the FreeType project, and may only be used,       */
/*  modified, and distributed under the terms of the FreeType project      */
/*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
/*  this file you indicate that you have read the license and              */
/*  understand and accept it fully.                                        */
/*                                                                         */
/***************************************************************************/

/* Development of this service is support of
   Information-technology Promotion Agency, Japan. */

#ifndef SVTTCMAP_H_
#define SVTTCMAP_H_

#include FT_INTERNAL_SERVICE_H
#include FT_TRUETYPE_TABLES_H

FT_BEGIN_HEADER

#define FT_SERVICE_ID_TT_CMAP  "tt-cmaps"

  /*************************************************************************/
  /*                                                                       */
  /* <Struct>                                                              */
  /*    TT_CMapInfo                                                        */
  /*                                                                       */
  /* <Description>                                                         */
  /*    A structure used to store TrueType/sfnt specific cmap information  */
  /*    which is not covered by the generic @FT_CharMap structure.  This   */
  /*    structure can be accessed with the @FT_Get_TT_CMap_Info function.  */
  /*                                                                       */
  /* <Fields>                                                              */
  /*    language ::                                                        */
  /*      The language ID used in Mac fonts.  Definitions of values are in */
  /*      `ttnameid.h'.                                                    */
  /*                                                                       */
  /*    format ::                                                          */
  /*      The cmap format.  OpenType 1.6 defines the formats 0 (byte       */
  /*      encoding table), 2~(high-byte mapping through table), 4~(segment */
  /*      mapping to delta values), 6~(trimmed table mapping), 8~(mixed    */
  /*      16-bit and 32-bit coverage), 10~(trimmed array), 12~(segmented   */
  /*      coverage), 13~(last resort font), and 14 (Unicode Variation      */
  /*      Sequences).                                                      */
  /*                                                                       */
  typedef struct  TT_CMapInfo_
  {
    FT_ULong  language;
    FT_Long   format;

  } TT_CMapInfo;

  typedef FT_Error
  (*TT_CMap_Info_GetFunc)( FT_CharMap    charmap,
                           TT_CMapInfo  *cmap_info );

  FT_DEFINE_SERVICE( TTCMaps )
  {
    TT_CMap_Info_GetFunc  get_cmap_info;
  };

#ifndef FT_CONFIG_OPTION_PIC

#define FT_DEFINE_SERVICE_TTCMAPSREC( class_, get_cmap_info_ )  \
  static const FT_Service_TTCMapsRec  class_ =                  \
  {                                                             \
    get_cmap_info_                                              \
  };

#else /* FT_CONFIG_OPTION_PIC */

#define FT_DEFINE_SERVICE_TTCMAPSREC( class_, get_cmap_info_ )  \
  void                                                          \
  FT_Init_Class_ ## class_( FT_Library              library,    \
                            FT_Service_TTCMapsRec*  clazz )     \
  {                                                             \
    FT_UNUSED( library );                                       \
                                                                \
    clazz->get_cmap_info = get_cmap_info_;                      \
  }

#endif /* FT_CONFIG_OPTION_PIC */

  /* */

FT_END_HEADER

#endif /* SVTTCMAP_H_ */

/* END */


text:
/***************************************************************************/
/*                                                                         */
/*  svmm.h                                                                 */
/*                                                                         */
/*    The FreeType Multiple Masters and GX var services (specification).   */
/*                                                                         */
/*  Copyright 2003-2017 by                                                 */
/*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
/*                                                                         */
/*  This file is part of the FreeType project, and may only be used,       */
/*  modified, and distributed under the terms of the FreeType project      */
/*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
/*  this file you indicate that you have read the license and              */
/*  understand and accept it fully.                                        */
/*                                                                         */
/***************************************************************************/

#ifndef SVMM_H_
#define SVMM_H_

#include FT_INTERNAL_SERVICE_H

FT_BEGIN_HEADER

  /*
   *  A service used to manage multiple-masters data in a given face.
   *
   *  See the related APIs in `ftmm.h' (FT_MULTIPLE_MASTERS_H).
   *
   */

#define FT_SERVICE_ID_MULTI_MASTERS  "multi-masters"

  typedef FT_Error
  (*FT_Get_MM_Func)( FT_Face           face,
                     FT_Multi_Master*  master );

  typedef FT_Error
  (*FT_Get_MM_Var_Func)( FT_Face      face,
                         FT_MM_Var*  *master );

  typedef FT_Error
  (*FT_Set_MM_Design_Func)( FT_Face   face,
                            FT_UInt   num_coords,
                            FT_Long*  coords );

  typedef FT_Error
  (*FT_Set_Var_Design_Func)( FT_Face    face,
                             FT_UInt    num_coords,
                             FT_Fixed*  coords );

  typedef FT_Error
  (*FT_Set_MM_Blend_Func)( FT_Face   face,
                           FT_UInt   num_coords,
                           FT_Long*  coords );

  typedef FT_Error
  (*FT_Get_Var_Design_Func)( FT_Face    face,
                             FT_UInt    num_coords,
                             FT_Fixed*  coords );

  typedef FT_Error
  (*FT_Get_MM_Blend_Func)( FT_Face   face,
                           FT_UInt   num_coords,
                           FT_Long*  coords );

  typedef FT_Error
  (*FT_Get_Var_Blend_Func)( FT_Face      face,
                            FT_UInt     *num_coords,
                            FT_Fixed*   *coords,
                            FT_Fixed*   *normalizedcoords,
                            FT_MM_Var*  *mm_var );

  typedef void
  (*FT_Done_Blend_Func)( FT_Face );

  FT_DEFINE_SERVICE( MultiMasters )
  {
    FT_Get_MM_Func          get_mm;
    FT_Set_MM_Design_Func   set_mm_design;
    FT_Set_MM_Blend_Func    set_mm_blend;
    FT_Get_MM_Blend_Func    get_mm_blend;
    FT_Get_MM_Var_Func      get_mm_var;
    FT_Set_Var_Design_Func  set_var_design;
    FT_Get_Var_Design_Func  get_var_design;

    /* for internal use; only needed for code sharing between modules */
    FT_Get_Var_Blend_Func   get_var_blend;
    FT_Done_Blend_Func      done_blend;
  };

#ifndef FT_CONFIG_OPTION_PIC

#define FT_DEFINE_SERVICE_MULTIMASTERSREC( class_,           \
                                           get_mm_,          \
                                           set_mm_design_,   \
                                           set_mm_blend_,    \
                                           get_mm_blend_,    \
                                           get_mm_var_,      \
                                           set_var_design_,  \
                                           get_var_design_,  \
                                           get_var_blend_,   \
                                           done_blend_     ) \
  static const FT_Service_MultiMastersRec  class_ =          \
  {                                                          \
    get_mm_,                                                 \
    set_mm_design_,                                          \
    set_mm_blend_,                                           \
    get_mm_blend_,                                           \
    get_mm_var_,                                             \
    set_var_design_,                                         \
    get_var_design_,                                         \
    get_var_blend_,                                          \
    done_blend_                                              \
  };

#else /* FT_CONFIG_OPTION_PIC */

#define FT_DEFINE_SERVICE_MULTIMASTERSREC( class_,               \
                                           get_mm_,              \
                                           set_mm_design_,       \
                                           set_mm_blend_,        \
                                           get_mm_blend_,        \
                                           get_mm_var_,          \
                                           set_var_design_,      \
                                           get_var_design_,      \
                                           get_var_blend_,       \
                                           done_blend_ )         \
  void                                                           \
  FT_Init_Class_ ## class_( FT_Service_MultiMastersRec*  clazz ) \
  {                                                              \
    clazz->get_mm         = get_mm_;                             \
    clazz->set_mm_design  = set_mm_design_;                      \
    clazz->set_mm_blend   = set_mm_blend_;                       \
    clazz->get_mm_blend   = get_mm_blend_;                       \
    clazz->get_mm_var     = get_mm_var_;                         \
    clazz->set_var_design = set_var_design_;                     \
    clazz->get_var_design = get_var_design_;                     \
    clazz->get_var_blend  = get_var_blend_;                      \
    clazz->done_blend     = done_blend_;                         \
  }

#endif /* FT_CONFIG_OPTION_PIC */

  /* */

FT_END_HEADER

#endif /* SVMM_H_ */

/* END */


text:
/***************************************************************************/
/*                                                                         */
/*  svwinfnt.h                                                             */
/*                                                                         */
/*    The FreeType Windows FNT/FONT service (specification).               */
/*                                                                         */
/*  Copyright 2003-2017 by                                                 */
/*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
/*                                                                         */
/*  This file is part of the FreeType project, and may only be used,       */
/*  modified, and distributed under the terms of the FreeType project      */
/*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
/*  this file you indicate that you have read the license and              */
/*  understand and accept it fully.                                        */
/*                                                                         */
/***************************************************************************/

#ifndef SVWINFNT_H_
#define SVWINFNT_H_

#include FT_INTERNAL_SERVICE_H
#include FT_WINFONTS_H

FT_BEGIN_HEADER

#define FT_SERVICE_ID_WINFNT  "winfonts"

  typedef FT_Error
  (*FT_WinFnt_GetHeaderFunc)( FT_Face               face,
                              FT_WinFNT_HeaderRec  *aheader );

  FT_DEFINE_SERVICE( WinFnt )
  {
    FT_WinFnt_GetHeaderFunc  get_header;
  };

  /* */

FT_END_HEADER

#endif /* SVWINFNT_H_ */

/* END */


text:
/***************************************************************************/
/*                                                                         */
/*  svpsinfo.h                                                             */
/*                                                                         */
/*    The FreeType PostScript info service (specification).                */
/*                                                                         */
/*  Copyright 2003-2017 by                                                 */
/*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
/*                                                                         */
/*  This file is part of the FreeType project, and may only be used,       */
/*  modified, and distributed under the terms of the FreeType project      */
/*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
/*  this file you indicate that you have read the license and              */
/*  understand and accept it fully.                                        */
/*                                                                         */
/***************************************************************************/

#ifndef SVPSINFO_H_
#define SVPSINFO_H_

#include FT_INTERNAL_SERVICE_H
#include FT_INTERNAL_TYPE1_TYPES_H

FT_BEGIN_HEADER

#define FT_SERVICE_ID_POSTSCRIPT_INFO  "postscript-info"

  typedef FT_Error
  (*PS_GetFontInfoFunc)( FT_Face          face,
                         PS_FontInfoRec*  afont_info );

  typedef FT_Error
  (*PS_GetFontExtraFunc)( FT_Face           face,
                          PS_FontExtraRec*  afont_extra );

  typedef FT_Int
  (*PS_HasGlyphNamesFunc)( FT_Face  face );

  typedef FT_Error
  (*PS_GetFontPrivateFunc)( FT_Face         face,
                            PS_PrivateRec*  afont_private );

  typedef FT_Long
  (*PS_GetFontValueFunc)( FT_Face       face,
                          PS_Dict_Keys  key,
                          FT_UInt       idx,
                          void         *value,
                          FT_Long       value_len );

  FT_DEFINE_SERVICE( PsInfo )
  {
    PS_GetFontInfoFunc     ps_get_font_info;
    PS_GetFontExtraFunc    ps_get_font_extra;
    PS_HasGlyphNamesFunc   ps_has_glyph_names;
    PS_GetFontPrivateFunc  ps_get_font_private;
    PS_GetFontValueFunc    ps_get_font_value;
  };

#ifndef FT_CONFIG_OPTION_PIC

#define FT_DEFINE_SERVICE_PSINFOREC( class_,                     \
                                     get_font_info_,             \
                                     ps_get_font_extra_,         \
                                     has_glyph_names_,           \
                                     get_font_private_,          \
                                     get_font_value_ )           \
  static const FT_Service_PsInfoRec  class_ =                    \
  {                                                              \
    get_font_info_, ps_get_font_extra_, has_glyph_names_,        \
    get_font_private_, get_font_value_                           \
  };

#else /* FT_CONFIG_OPTION_PIC */

#define FT_DEFINE_SERVICE_PSINFOREC( class_,                     \
                                     get_font_info_,             \
                                     ps_get_font_extra_,         \
                                     has_glyph_names_,           \
                                     get_font_private_,          \
                                     get_font_value_ )           \
  void                                                           \
  FT_Init_Class_ ## class_( FT_Library             library,      \
                            FT_Service_PsInfoRec*  clazz )       \
  {                                                              \
    FT_UNUSED( library );                                        \
                                                                 \
    clazz->ps_get_font_info    = get_font_info_;                 \
    clazz->ps_get_font_extra   = ps_get_font_extra_;             \
    clazz->ps_has_glyph_names  = has_glyph_names_;               \
    clazz->ps_get_font_private = get_font_private_;              \
    clazz->ps_get_font_value   = get_font_value_;                \
  }

#endif /* FT_CONFIG_OPTION_PIC */

  /* */

FT_END_HEADER

#endif /* SVPSINFO_H_ */

/* END */


text:
/***************************************************************************/
/*                                                                         */
/*  svfntfmt.h                                                             */
/*                                                                         */
/*    The FreeType font format service (specification only).               */
/*                                                                         */
/*  Copyright 2003-2017 by                                                 */
/*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
/*                                                                         */
/*  This file is part of the FreeType project, and may only be used,       */
/*  modified, and distributed under the terms of the FreeType project      */
/*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
/*  this file you indicate that you have read the license and              */
/*  understand and accept it fully.                                        */
/*                                                                         */
/***************************************************************************/

#ifndef SVFNTFMT_H_
#define SVFNTFMT_H_

#include FT_INTERNAL_SERVICE_H

FT_BEGIN_HEADER

  /*
   *  A trivial service used to return the name of a face's font driver,
   *  according to the XFree86 nomenclature.  Note that the service data
   *  is a simple constant string pointer.
   */

#define FT_SERVICE_ID_FONT_FORMAT  "font-format"

#define FT_FONT_FORMAT_TRUETYPE  "TrueType"
#define FT_FONT_FORMAT_TYPE_1    "Type 1"
#define FT_FONT_FORMAT_BDF       "BDF"
#define FT_FONT_FORMAT_PCF       "PCF"
#define FT_FONT_FORMAT_TYPE_42   "Type 42"
#define FT_FONT_FORMAT_CID       "CID Type 1"
#define FT_FONT_FORMAT_CFF       "CFF"
#define FT_FONT_FORMAT_PFR       "PFR"
#define FT_FONT_FORMAT_WINFNT    "Windows FNT"

  /* */

FT_END_HEADER

#endif /* SVFNTFMT_H_ */

/* END */


text:
/***************************************************************************/
/*                                                                         */
/*  svpfr.h                                                                */
/*                                                                         */
/*    Internal PFR service functions (specification).                      */
/*                                                                         */
/*  Copyright 2003-2017 by                                                 */
/*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
/*                                                                         */
/*  This file is part of the FreeType project, and may only be used,       */
/*  modified, and distributed under the terms of the FreeType project      */
/*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
/*  this file you indicate that you have read the license and              */
/*  understand and accept it fully.                                        */
/*                                                                         */
/***************************************************************************/

#ifndef SVPFR_H_
#define SVPFR_H_

#include FT_PFR_H
#include FT_INTERNAL_SERVICE_H

FT_BEGIN_HEADER

#define FT_SERVICE_ID_PFR_METRICS  "pfr-metrics"

  typedef FT_Error
  (*FT_PFR_GetMetricsFunc)( FT_Face    face,
                            FT_UInt   *aoutline,
                            FT_UInt   *ametrics,
                            FT_Fixed  *ax_scale,
                            FT_Fixed  *ay_scale );

  typedef FT_Error
  (*FT_PFR_GetKerningFunc)( FT_Face     face,
                            FT_UInt     left,
                            FT_UInt     right,
                            FT_Vector  *avector );

  typedef FT_Error
  (*FT_PFR_GetAdvanceFunc)( FT_Face   face,
                            FT_UInt   gindex,
                            FT_Pos   *aadvance );

  FT_DEFINE_SERVICE( PfrMetrics )
  {
    FT_PFR_GetMetricsFunc  get_metrics;
    FT_PFR_GetKerningFunc  get_kerning;
    FT_PFR_GetAdvanceFunc  get_advance;

  };

 /* */

FT_END_HEADER

#endif /* SVPFR_H_ */

/* END */


text:
/***************************************************************************/
/*                                                                         */
/*  svpostnm.h                                                             */
/*                                                                         */
/*    The FreeType PostScript name services (specification).               */
/*                                                                         */
/*  Copyright 2003-2017 by                                                 */
/*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
/*                                                                         */
/*  This file is part of the FreeType project, and may only be used,       */
/*  modified, and distributed under the terms of the FreeType project      */
/*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
/*  this file you indicate that you have read the license and              */
/*  understand and accept it fully.                                        */
/*                                                                         */
/***************************************************************************/

#ifndef SVPOSTNM_H_
#define SVPOSTNM_H_

#include FT_INTERNAL_SERVICE_H

FT_BEGIN_HEADER

  /*
   *  A trivial service used to retrieve the PostScript name of a given
   *  font when available.  The `get_name' field should never be NULL.
   *
   *  The corresponding function can return NULL to indicate that the
   *  PostScript name is not available.
   *
   *  The name is owned by the face and will be destroyed with it.
   */

#define FT_SERVICE_ID_POSTSCRIPT_FONT_NAME  "postscript-font-name"

  typedef const char*
  (*FT_PsName_GetFunc)( FT_Face  face );

  FT_DEFINE_SERVICE( PsFontName )
  {
    FT_PsName_GetFunc  get_ps_font_name;
  };

#ifndef FT_CONFIG_OPTION_PIC

#define FT_DEFINE_SERVICE_PSFONTNAMEREC( class_, get_ps_font_name_ ) \
  static const FT_Service_PsFontNameRec  class_ =                    \
  {                                                                  \
    get_ps_font_name_                                                \
  };

#else /* FT_CONFIG_OPTION_PIC */

#define FT_DEFINE_SERVICE_PSFONTNAMEREC( class_, get_ps_font_name_ ) \
  void                                                               \
  FT_Init_Class_ ## class_( FT_Library                 library,      \
                            FT_Service_PsFontNameRec*  clazz )       \
  {                                                                  \
    FT_UNUSED( library );                                            \
                                                                     \
    clazz->get_ps_font_name = get_ps_font_name_;                     \
  }

#endif /* FT_CONFIG_OPTION_PIC */

  /* */

FT_END_HEADER

#endif /* SVPOSTNM_H_ */

/* END */


text:
/***************************************************************************/
/*                                                                         */
/*  svotval.h                                                              */
/*                                                                         */
/*    The FreeType OpenType validation service (specification).            */
/*                                                                         */
/*  Copyright 2004-2017 by                                                 */
/*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
/*                                                                         */
/*  This file is part of the FreeType project, and may only be used,       */
/*  modified, and distributed under the terms of the FreeType project      */
/*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
/*  this file you indicate that you have read the license and              */
/*  understand and accept it fully.                                        */
/*                                                                         */
/***************************************************************************/

#ifndef SVOTVAL_H_
#define SVOTVAL_H_

#include FT_OPENTYPE_VALIDATE_H
#include FT_INTERNAL_VALIDATE_H

FT_BEGIN_HEADER

#define FT_SERVICE_ID_OPENTYPE_VALIDATE  "opentype-validate"

  typedef FT_Error
  (*otv_validate_func)( FT_Face volatile  face,
                        FT_UInt           ot_flags,
                        FT_Bytes         *base,
                        FT_Bytes         *gdef,
                        FT_Bytes         *gpos,
                        FT_Bytes         *gsub,
                        FT_Bytes         *jstf );

  FT_DEFINE_SERVICE( OTvalidate )
  {
    otv_validate_func  validate;
  };

  /* */

FT_END_HEADER

#endif /* SVOTVAL_H_ */

/* END */