misc/libfreetype/src/pfr/pfrtypes.h
author Xeli
Fri, 17 Feb 2012 21:34:33 +0100
changeset 6701 58a43c2064ad
parent 5172 88f2e05288ba
permissions -rw-r--r--
the onScreenwidgets are multitouch now, frequently (alternating) tapping left and right still causes it to bug though, but you have to try hard to duplicate it, works ok for now
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
5172
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     1
/***************************************************************************/
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     2
/*                                                                         */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     3
/*  pfrtypes.h                                                             */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     4
/*                                                                         */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     5
/*    FreeType PFR data structures (specification only).                   */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     6
/*                                                                         */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     7
/*  Copyright 2002, 2003, 2005, 2007 by                                    */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     8
/*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
     9
/*                                                                         */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    10
/*  This file is part of the FreeType project, and may only be used,       */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    11
/*  modified, and distributed under the terms of the FreeType project      */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    12
/*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    13
/*  this file you indicate that you have read the license and              */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    14
/*  understand and accept it fully.                                        */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    15
/*                                                                         */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    16
/***************************************************************************/
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    17
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    18
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    19
#ifndef __PFRTYPES_H__
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    20
#define __PFRTYPES_H__
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    21
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    22
#include <ft2build.h>
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    23
#include FT_INTERNAL_OBJECTS_H
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    24
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    25
FT_BEGIN_HEADER
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    26
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    27
  /************************************************************************/
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    28
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    29
  /* the PFR Header structure */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    30
  typedef struct  PFR_HeaderRec_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    31
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    32
    FT_UInt32  signature;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    33
    FT_UInt    version;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    34
    FT_UInt    signature2;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    35
    FT_UInt    header_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    36
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    37
    FT_UInt    log_dir_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    38
    FT_UInt    log_dir_offset;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    39
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    40
    FT_UInt    log_font_max_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    41
    FT_UInt32  log_font_section_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    42
    FT_UInt32  log_font_section_offset;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    43
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    44
    FT_UInt32  phy_font_max_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    45
    FT_UInt32  phy_font_section_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    46
    FT_UInt32  phy_font_section_offset;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    47
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    48
    FT_UInt    gps_max_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    49
    FT_UInt32  gps_section_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    50
    FT_UInt32  gps_section_offset;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    51
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    52
    FT_UInt    max_blue_values;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    53
    FT_UInt    max_x_orus;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    54
    FT_UInt    max_y_orus;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    55
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    56
    FT_UInt    phy_font_max_size_high;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    57
    FT_UInt    color_flags;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    58
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    59
    FT_UInt32  bct_max_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    60
    FT_UInt32  bct_set_max_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    61
    FT_UInt32  phy_bct_set_max_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    62
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    63
    FT_UInt    num_phy_fonts;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    64
    FT_UInt    max_vert_stem_snap;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    65
    FT_UInt    max_horz_stem_snap;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    66
    FT_UInt    max_chars;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    67
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    68
  } PFR_HeaderRec, *PFR_Header;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    69
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    70
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    71
  /* used in `color_flags' field of the PFR_Header */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    72
  typedef enum  PFR_HeaderFlags_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    73
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    74
    PFR_FLAG_BLACK_PIXEL   = 1,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    75
    PFR_FLAG_INVERT_BITMAP = 2
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    76
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    77
  } PFR_HeaderFlags;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    78
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    79
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    80
  /************************************************************************/
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    81
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    82
  typedef struct  PFR_LogFontRec_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    83
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    84
    FT_UInt32  size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    85
    FT_UInt32  offset;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    86
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    87
    FT_Int32   matrix[4];
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    88
    FT_UInt    stroke_flags;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    89
    FT_Int     stroke_thickness;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    90
    FT_Int     bold_thickness;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    91
    FT_Int32   miter_limit;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    92
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    93
    FT_UInt32  phys_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    94
    FT_UInt32  phys_offset;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    95
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    96
  } PFR_LogFontRec, *PFR_LogFont;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    97
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    98
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
    99
  typedef enum  PFR_LogFlags_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   100
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   101
    PFR_LOG_EXTRA_ITEMS  = 0x40,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   102
    PFR_LOG_2BYTE_BOLD   = 0x20,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   103
    PFR_LOG_BOLD         = 0x10,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   104
    PFR_LOG_2BYTE_STROKE = 8,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   105
    PFR_LOG_STROKE       = 4,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   106
    PFR_LINE_JOIN_MASK   = 3
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   107
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   108
  } PFR_LogFlags;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   109
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   110
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   111
  typedef enum  PFR_LineJoinFlags_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   112
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   113
    PFR_LINE_JOIN_MITER = 0,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   114
    PFR_LINE_JOIN_ROUND = 1,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   115
    PFR_LINE_JOIN_BEVEL = 2
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   116
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   117
  } PFR_LineJoinFlags;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   118
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   119
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   120
  /************************************************************************/
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   121
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   122
  typedef enum  PFR_BitmapFlags_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   123
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   124
    PFR_BITMAP_3BYTE_OFFSET   = 4,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   125
    PFR_BITMAP_2BYTE_SIZE     = 2,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   126
    PFR_BITMAP_2BYTE_CHARCODE = 1
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   127
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   128
  } PFR_BitmapFlags;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   129
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   130
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   131
  typedef struct  PFR_BitmapCharRec_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   132
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   133
    FT_UInt    char_code;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   134
    FT_UInt    gps_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   135
    FT_UInt32  gps_offset;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   136
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   137
  } PFR_BitmapCharRec, *PFR_BitmapChar;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   138
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   139
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   140
  typedef enum  PFR_StrikeFlags_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   141
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   142
    PFR_STRIKE_2BYTE_COUNT  = 0x10,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   143
    PFR_STRIKE_3BYTE_OFFSET = 0x08,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   144
    PFR_STRIKE_3BYTE_SIZE   = 0x04,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   145
    PFR_STRIKE_2BYTE_YPPM   = 0x02,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   146
    PFR_STRIKE_2BYTE_XPPM   = 0x01
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   147
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   148
  } PFR_StrikeFlags;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   149
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   150
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   151
  typedef struct  PFR_StrikeRec_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   152
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   153
    FT_UInt         x_ppm;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   154
    FT_UInt         y_ppm;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   155
    FT_UInt         flags;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   156
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   157
    FT_UInt32       gps_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   158
    FT_UInt32       gps_offset;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   159
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   160
    FT_UInt32       bct_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   161
    FT_UInt32       bct_offset;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   162
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   163
    /* optional */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   164
    FT_UInt         num_bitmaps;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   165
    PFR_BitmapChar  bitmaps;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   166
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   167
  } PFR_StrikeRec, *PFR_Strike;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   168
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   169
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   170
  /************************************************************************/
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   171
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   172
  typedef struct  PFR_CharRec_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   173
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   174
    FT_UInt    char_code;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   175
    FT_Int     advance;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   176
    FT_UInt    gps_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   177
    FT_UInt32  gps_offset;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   178
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   179
  } PFR_CharRec, *PFR_Char;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   180
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   181
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   182
  /************************************************************************/
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   183
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   184
  typedef struct  PFR_DimensionRec_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   185
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   186
    FT_UInt  standard;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   187
    FT_UInt  num_stem_snaps;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   188
    FT_Int*  stem_snaps;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   189
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   190
  } PFR_DimensionRec, *PFR_Dimension;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   191
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   192
  /************************************************************************/
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   193
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   194
  typedef struct PFR_KernItemRec_*  PFR_KernItem;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   195
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   196
  typedef struct  PFR_KernItemRec_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   197
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   198
    PFR_KernItem  next;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   199
    FT_Byte       pair_count;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   200
    FT_Byte       flags;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   201
    FT_Short      base_adj;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   202
    FT_UInt       pair_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   203
    FT_Offset     offset;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   204
    FT_UInt32     pair1;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   205
    FT_UInt32     pair2;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   206
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   207
  } PFR_KernItemRec;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   208
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   209
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   210
#define PFR_KERN_INDEX( g1, g2 )                          \
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   211
          ( ( (FT_UInt32)(g1) << 16 ) | (FT_UInt16)(g2) )
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   212
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   213
#define PFR_KERN_PAIR_INDEX( pair )                        \
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   214
          PFR_KERN_INDEX( (pair)->glyph1, (pair)->glyph2 )
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   215
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   216
#define PFR_NEXT_KPAIR( p )  ( p += 2,                              \
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   217
                               ( (FT_UInt32)p[-2] << 16 ) | p[-1] )
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   218
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   219
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   220
  /************************************************************************/
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   221
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   222
  typedef struct  PFR_PhyFontRec_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   223
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   224
    FT_Memory          memory;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   225
    FT_UInt32          offset;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   226
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   227
    FT_UInt            font_ref_number;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   228
    FT_UInt            outline_resolution;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   229
    FT_UInt            metrics_resolution;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   230
    FT_BBox            bbox;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   231
    FT_UInt            flags;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   232
    FT_UInt            standard_advance;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   233
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   234
    FT_Int             ascent;   /* optional, bbox.yMax if not present */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   235
    FT_Int             descent;  /* optional, bbox.yMin if not present */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   236
    FT_Int             leading;  /* optional, 0 if not present         */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   237
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   238
    PFR_DimensionRec   horizontal;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   239
    PFR_DimensionRec   vertical;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   240
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   241
    FT_String*         font_id;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   242
    FT_String*         family_name;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   243
    FT_String*         style_name;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   244
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   245
    FT_UInt            num_strikes;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   246
    FT_UInt            max_strikes;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   247
    PFR_StrikeRec*     strikes;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   248
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   249
    FT_UInt            num_blue_values;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   250
    FT_Int            *blue_values;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   251
    FT_UInt            blue_fuzz;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   252
    FT_UInt            blue_scale;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   253
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   254
    FT_UInt            num_chars;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   255
    FT_Offset          chars_offset;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   256
    PFR_Char           chars;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   257
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   258
    FT_UInt            num_kern_pairs;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   259
    PFR_KernItem       kern_items;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   260
    PFR_KernItem*      kern_items_tail;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   261
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   262
    /* not part of the spec, but used during load */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   263
    FT_Long            bct_offset;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   264
    FT_Byte*           cursor;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   265
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   266
  } PFR_PhyFontRec, *PFR_PhyFont;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   267
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   268
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   269
  typedef enum  PFR_PhyFlags_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   270
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   271
    PFR_PHY_EXTRA_ITEMS      = 0x80,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   272
    PFR_PHY_3BYTE_GPS_OFFSET = 0x20,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   273
    PFR_PHY_2BYTE_GPS_SIZE   = 0x10,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   274
    PFR_PHY_ASCII_CODE       = 0x08,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   275
    PFR_PHY_PROPORTIONAL     = 0x04,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   276
    PFR_PHY_2BYTE_CHARCODE   = 0x02,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   277
    PFR_PHY_VERTICAL         = 0x01
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   278
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   279
  } PFR_PhyFlags;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   280
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   281
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   282
  typedef enum PFR_KernFlags_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   283
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   284
    PFR_KERN_2BYTE_CHAR  = 0x01,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   285
    PFR_KERN_2BYTE_ADJ   = 0x02
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   286
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   287
  } PFR_KernFlags;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   288
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   289
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   290
  /************************************************************************/
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   291
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   292
  typedef enum  PFR_GlyphFlags_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   293
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   294
    PFR_GLYPH_IS_COMPOUND   = 0x80,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   295
    PFR_GLYPH_EXTRA_ITEMS   = 0x08,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   296
    PFR_GLYPH_1BYTE_XYCOUNT = 0x04,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   297
    PFR_GLYPH_XCOUNT        = 0x02,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   298
    PFR_GLYPH_YCOUNT        = 0x01
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   299
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   300
  } PFR_GlyphFlags;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   301
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   302
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   303
  /* controlled coordinate */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   304
  typedef struct  PFR_CoordRec_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   305
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   306
    FT_UInt  org;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   307
    FT_UInt  cur;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   308
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   309
  } PFR_CoordRec, *PFR_Coord;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   310
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   311
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   312
  typedef struct  PFR_SubGlyphRec_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   313
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   314
    FT_Fixed   x_scale;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   315
    FT_Fixed   y_scale;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   316
    FT_Int     x_delta;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   317
    FT_Int     y_delta;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   318
    FT_UInt32  gps_offset;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   319
    FT_UInt    gps_size;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   320
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   321
  } PFR_SubGlyphRec, *PFR_SubGlyph;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   322
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   323
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   324
  typedef enum  PFR_SubgGlyphFlags_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   325
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   326
    PFR_SUBGLYPH_3BYTE_OFFSET = 0x80,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   327
    PFR_SUBGLYPH_2BYTE_SIZE   = 0x40,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   328
    PFR_SUBGLYPH_YSCALE       = 0x20,
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   329
    PFR_SUBGLYPH_XSCALE       = 0x10
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   330
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   331
  } PFR_SubGlyphFlags;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   332
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   333
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   334
  typedef struct  PFR_GlyphRec_
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   335
  {
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   336
    FT_Byte           format;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   337
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   338
#if 0
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   339
    FT_UInt           num_x_control;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   340
    FT_UInt           num_y_control;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   341
#endif
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   342
    FT_UInt           max_xy_control;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   343
    FT_Pos*           x_control;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   344
    FT_Pos*           y_control;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   345
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   346
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   347
    FT_UInt           num_subs;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   348
    FT_UInt           max_subs;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   349
    PFR_SubGlyphRec*  subs;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   350
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   351
    FT_GlyphLoader    loader;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   352
    FT_Bool           path_begun;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   353
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   354
  } PFR_GlyphRec, *PFR_Glyph;
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   355
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   356
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   357
FT_END_HEADER
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   358
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   359
#endif /* __PFRTYPES_H__ */
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   360
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   361
88f2e05288ba aaand let's add freetype as well while we are at it
koda
parents:
diff changeset
   362
/* END */