[Xorg-commit] xc/extras/freetype2/include/freetype freetype.h,1.1.4.1,1.1.4.2 ftbbox.h,1.1,1.1.4.1 ftbdf.h,1.1.4.1,1.1.4.2 ftcache.h,1.1.4.1,1.1.4.2 ftglyph.h,1.1.4.1,1.1.4.2 ftgzip.h,1.1,1.1.4.1 ftimage.h,1.1.4.1,1.1.4.2 ftincrem.h,1.1,1.1.4.1 ftlist.h,1.1,1.1.4.1 ftmm.h,1.1,1.1.4.1 ftmoderr.h,1.1,1.1.4.1 ftoutln.h,1.1.4.1,1.1.4.2 ftpfr.h,1.1,1.1.4.1 ftsizes.h,1.1.4.1,1.1.4.2 ftsnames.h,1.1,1.1.4.1 ftsynth.h,1.1.4.1,1.1.4.2 fttrigon.h,1.1.4.1,1.1.4.2 ftwinfnt.h,1.1,1.1.4.1 ftxf86.h,1.1,1.1.4.1 t1tables.h,1.1.4.1,1.1.4.2 ttnameid.h,1.1.4.1,1.1.4.2 tttables.h,1.1.4.1,1.1.4.2 tttags.h,1.1,1.1.4.1

Kaleb Keithley xorg-commit at pdx.freedesktop.org
Wed May 9 17:30:30 EEST 2007


Committed by: kaleb

Update of /cvs/xorg/xc/extras/freetype2/include/freetype
In directory pdx:/home/kaleb/xorg/xc.XORG-CURRENT/extras/freetype2/include/freetype

Modified Files:
      Tag: XORG-CURRENT
	freetype.h ftbbox.h ftbdf.h ftcache.h ftglyph.h ftgzip.h 
	ftimage.h ftincrem.h ftlist.h ftmm.h ftmoderr.h ftoutln.h 
	ftpfr.h ftsizes.h ftsnames.h ftsynth.h fttrigon.h ftwinfnt.h 
	ftxf86.h t1tables.h ttnameid.h tttables.h tttags.h 
Log Message:
merge most of XFree86 RC3 (4.3.99.903) from vendor branch.
bug #214


Index: freetype.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/freetype.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/freetype.h	26 Nov 2003 22:48:24 -0000	1.1.4.1
+++ b/freetype.h	23 Feb 2004 21:32:25 -0000	1.1.4.2
@@ -4,7 +4,7 @@
 /*                                                                         */
 /*    FreeType high-level API and common types (specification only).       */
 /*                                                                         */
-/*  Copyright 1996-2001, 2002 by                                           */
+/*  Copyright 1996-2001, 2002, 2003 by                                     */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -16,6 +16,15 @@
 /***************************************************************************/
 
 
+#ifndef FT_FREETYPE_H
+#error "`ft2build.h' hasn't been included yet!"
+#error "Please always use macros to include FreeType header files."
+#error "Example:"
+#error "  #include <ft2build.h>"
+#error "  #include FT_FREETYPE_H"
+#endif
+
+
 #ifndef __FREETYPE_H__
 #define __FREETYPE_H__
 
@@ -35,7 +44,7 @@
   /*                                                                       */
 #define FREETYPE_MAJOR 2
 #define FREETYPE_MINOR 1
-#define FREETYPE_PATCH 4
+#define FREETYPE_PATCH 7
 
 
 #include <ft2build.h>
@@ -113,7 +122,6 @@
   /*    FT_New_Memory_Face                                                 */
   /*    FT_Open_Face                                                       */
   /*    FT_Open_Args                                                       */
-  /*    FT_Open_Flags                                                      */
   /*    FT_Parameter                                                       */
   /*    FT_Attach_File                                                     */
   /*    FT_Attach_Stream                                                   */
@@ -126,6 +134,12 @@
   /*    FT_Get_Name_Index                                                  */
   /*    FT_Load_Char                                                       */
   /*                                                                       */
+  /*    FT_OPEN_MEMORY                                                     */
+  /*    FT_OPEN_STREAM                                                     */
+  /*    FT_OPEN_PATHNAME                                                   */
+  /*    FT_OPEN_DRIVER                                                     */
+  /*    FT_OPEN_PARAMS                                                     */
+  /*                                                                       */
   /*    FT_LOAD_DEFAULT                                                    */
   /*    FT_LOAD_RENDER                                                     */
   /*    FT_LOAD_MONOCHROME                                                 */
@@ -142,6 +156,12 @@
   /*    FT_LOAD_NO_RECURSE                                                 */
   /*    FT_LOAD_PEDANTIC                                                   */
   /*                                                                       */
+  /*    FT_LOAD_TARGET_NORMAL                                              */
+  /*    FT_LOAD_TARGET_LIGHT                                               */
+  /*    FT_LOAD_TARGET_MONO                                                */
+  /*    FT_LOAD_TARGET_LCD                                                 */
+  /*    FT_LOAD_TARGET_LCD_V                                               */
+  /*                                                                       */
   /*    FT_Render_Glyph                                                    */
   /*    FT_Render_Mode                                                     */
   /*    FT_Get_Kerning                                                     */
@@ -162,9 +182,10 @@
   /*    FT_Glyph_Metrics                                                   */
   /*                                                                       */
   /* <Description>                                                         */
-  /*    A structure used to model the metrics of a single glyph.  Note     */
-  /*    that values are expressed in 26.6 fractional pixel format or in    */
-  /*    font units, depending on context.                                  */
+  /*    A structure used to model the metrics of a single glyph.  The      */
+  /*    values are expressed in 26.6 fractional pixel format; if the flag  */
+  /*    FT_LOAD_NO_SCALE is used, values are returned in font units        */
+  /*    instead.                                                           */
   /*                                                                       */
   /* <Fields>                                                              */
   /*    width        :: The glyph's width.                                 */
@@ -205,21 +226,62 @@
   /*    FT_Bitmap_Size                                                     */
   /*                                                                       */
   /* <Description>                                                         */
-  /*    An extremely simple structure used to model the size of a bitmap   */
-  /*    strike (i.e., a bitmap instance of the font for a given            */
-  /*    resolution) in a fixed-size font face.  This is used for the       */
-  /*    `available_sizes' field of the FT_Face_Properties structure.       */
+  /*    This structure models the size of a bitmap strike (i.e., a bitmap  */
+  /*    instance of the font for a given resolution) in a fixed-size font  */
+  /*    face.  It is used for the `available_sizes' field of the           */
+  /*    @FT_FaceRec structure.                                             */
   /*                                                                       */
   /* <Fields>                                                              */
-  /*    height :: The character height in pixels.                          */
+  /*    height :: The (vertical) baseline-to-baseline distance in pixels.  */
+  /*              It makes most sense to define the height of a bitmap     */
+  /*              font in this way.                                        */
   /*                                                                       */
-  /*    width  :: The character width in pixels.                           */
+  /*    width  :: The average width of the font (in pixels).  Since the    */
+  /*              algorithms to compute this value are different for the   */
+  /*              various bitmap formats, it can only give an additional   */
+  /*              hint if the `height' value isn't sufficient to select    */
+  /*              the proper font.  For monospaced fonts the average width */
+  /*              is the same as the maximum width.                        */
+  /*                                                                       */
+  /*    size   :: The point size in 26.6 fractional format this font shall */
+  /*              represent (for a given vertical resolution).             */
+  /*                                                                       */
+  /*    x_ppem :: The horizontal ppem value (in 26.6 fractional format).   */
+  /*                                                                       */
+  /*    y_ppem :: The vertical ppem value (in 26.6 fractional format).     */
+  /*                                                                       */
+  /* <Note>                                                                */
+  /*    The values in this structure are taken from the bitmap font.  If   */
+  /*    the font doesn't provide a parameter it is set to zero to indicate */
+  /*    that the information is not available.                             */
+  /*                                                                       */
+  /*    The following formula converts from dpi to ppem:                   */
+  /*                                                                       */
+  /*      ppem = size * dpi / 72                                           */
+  /*                                                                       */
+  /*    where `size' is in points.                                         */
+  /*                                                                       */
+  /*    Windows FNT:                                                       */
+  /*      The `size', `x_ppem', and `y_ppem' parameters are not reliable:  */
+  /*      There exist fonts (e.g. app850.fon) which have a wrong size for  */
+  /*      some subfonts; since FNT files don't contain ppem but dpi values */
+  /*      the computed x_ppem and y_ppem numbers are thus wrong also.      */
+  /*                                                                       */
+  /*    TrueType embedded bitmaps:                                         */
+  /*      `size', `width', and `height' values are not contained in the    */
+  /*      bitmap strike itself.  They are computed from the global font    */
+  /*      parameters.                                                      */
   /*                                                                       */
   typedef struct  FT_Bitmap_Size_
   {
     FT_Short  height;
     FT_Short  width;
 
+    FT_Pos    size;
+
+    FT_Pos    x_ppem;
+    FT_Pos    y_ppem;
+
   } FT_Bitmap_Size;
 
 
@@ -386,6 +448,10 @@
   /*    @FT_Open_Face), the library looks for a Unicode charmap within     */
   /*    the list and automatically activates it.                           */
   /*                                                                       */
+  /* <Also>                                                                */
+  /*    The @FT_CharMapRec details the publicly accessible fields of a     */
+  /*    given character map.                                               */
+  /*                                                                       */
   typedef struct FT_CharMapRec_*  FT_CharMap;
 
 
@@ -452,30 +518,28 @@
   /*     mathematical symbols in the 32..255 character code range.  For    */
   /*     more information, see `http://www.ceviz.net/symbol.htm'.          */
   /*                                                                       */
-  /*   FT_ENCODING_MS_SJIS ::                                              */
-  /*     Corresponds to Microsoft's Japanese SJIS encoding.  More info     */
+  /*   FT_ENCODING_SJIS ::                                                 */
+  /*     Corresponds to Japanese SJIS encoding.  More info at              */
   /*     at `http://langsupport.japanreference.com/encoding.shtml'.        */
   /*     See note on multi-byte encodings below.                           */
   /*                                                                       */
-  /*   FT_ENCODING_MS_GB2312 ::                                            */
-  /*     Corresponds to the encoding system for Simplified Chinese, as     */
-  /*     used in China.  Only found in some TrueType fonts.                */
+  /*   FT_ENCODING_GB2312 ::                                               */
+  /*     Corresponds to an encoding system for Simplified Chinese as used  */
+  /*     used in mainland China.                                           */
   /*                                                                       */
-  /*   FT_ENCODING_MS_BIG5 ::                                              */
-  /*     Corresponds to the encoding system for Traditional Chinese, as    */
-  /*     used in Taiwan and Hong Kong.  Only found in some TrueType fonts. */
+  /*   FT_ENCODING_BIG5 ::                                                 */
+  /*     Corresponds to an encoding system for Traditional Chinese as used */
+  /*     in Taiwan and Hong Kong.                                          */
   /*                                                                       */
-  /*   FT_ENCODING_MS_WANSUNG ::                                           */
+  /*   FT_ENCODING_WANSUNG ::                                              */
   /*     Corresponds to the Korean encoding system known as Wansung.       */
-  /*     This is a Microsoft encoding that is only found in some TrueType  */
-  /*     fonts.  For more information, see                                 */
+  /*     For more information see                                          */
   /*     `http://www.microsoft.com/typography/unicode/949.txt'.            */
   /*                                                                       */
-  /*   FT_ENCODING_MS_JOHAB ::                                             */
+  /*   FT_ENCODING_JOHAB ::                                                */
   /*     The Korean standard character set (KS C-5601-1992), which         */
-  /*     corresponds to Windows code page 1361.  This character set        */
+  /*     corresponds to MS Windows code page 1361.  This character set     */
   /*     includes all possible Hangeul character combinations.             */
-  /*     Only found on some rare TrueType fonts.                           */
   /*                                                                       */
   /*   FT_ENCODING_ADOBE_LATIN_1 ::                                        */
   /*     Corresponds to a Latin-1 encoding as defined in a Type 1          */
@@ -483,7 +547,7 @@
   /*                                                                       */
   /*   FT_ENCODING_ADOBE_STANDARD ::                                       */
   /*     Corresponds to the Adobe Standard encoding, as found in Type 1,   */
-  /*     CFF, and OpenType/CFF fonts.  It is limited to 256character       */
+  /*     CFF, and OpenType/CFF fonts.  It is limited to 256 character      */
   /*     codes.                                                            */
   /*                                                                       */
   /*   FT_ENCODING_ADOBE_EXPERT ::                                         */
@@ -504,6 +568,21 @@
   /*     This value is deprecated and was never used nor reported by       */
   /*     FreeType.  Don't use or test for it.                              */
   /*                                                                       */
+  /*   FT_ENCODING_MS_SJIS ::                                              */
+  /*     Same as FT_ENCODING_SJIS.  Deprecated.                            */
+  /*                                                                       */
+  /*   FT_ENCODING_MS_GB2312 ::                                            */
+  /*     Same as FT_ENCODING_GB2312.  Deprecated.                          */
+  /*                                                                       */
+  /*   FT_ENCODING_MS_BIG5 ::                                              */
+  /*     Same as FT_ENCODING_BIG5.  Deprecated.                            */
+  /*                                                                       */
+  /*   FT_ENCODING_MS_WANSUNG ::                                           */
+  /*     Same as FT_ENCODING_WANSUNG.  Deprecated.                         */
+  /*                                                                       */
+  /*   FT_ENCODING_MS_JOHAB ::                                             */
+  /*     Same as FT_ENCODING_JOHAB.  Deprecated.                           */
+  /*                                                                       */
   /* <Note>                                                                */
   /*   By default, FreeType automatically synthetizes a Unicode charmap    */
   /*   for Postscript fonts, using their glyph names dictionaries.         */
@@ -518,11 +597,18 @@
     FT_ENC_TAG( FT_ENCODING_MS_SYMBOL,  's', 'y', 'm', 'b' ),
     FT_ENC_TAG( FT_ENCODING_UNICODE,    'u', 'n', 'i', 'c' ),
 
-    FT_ENC_TAG( FT_ENCODING_MS_SJIS,    's', 'j', 'i', 's' ),
-    FT_ENC_TAG( FT_ENCODING_MS_GB2312,  'g', 'b', ' ', ' ' ),
-    FT_ENC_TAG( FT_ENCODING_MS_BIG5,    'b', 'i', 'g', '5' ),
-    FT_ENC_TAG( FT_ENCODING_MS_WANSUNG, 'w', 'a', 'n', 's' ),
-    FT_ENC_TAG( FT_ENCODING_MS_JOHAB,   'j', 'o', 'h', 'a' ),
+    FT_ENC_TAG( FT_ENCODING_SJIS,    's', 'j', 'i', 's' ),
+    FT_ENC_TAG( FT_ENCODING_GB2312,  'g', 'b', ' ', ' ' ),
+    FT_ENC_TAG( FT_ENCODING_BIG5,    'b', 'i', 'g', '5' ),
+    FT_ENC_TAG( FT_ENCODING_WANSUNG, 'w', 'a', 'n', 's' ),
+    FT_ENC_TAG( FT_ENCODING_JOHAB,   'j', 'o', 'h', 'a' ),
+
+    /* for backwards compatibility */
+    FT_ENCODING_MS_SJIS    = FT_ENCODING_SJIS,
+    FT_ENCODING_MS_GB2312  = FT_ENCODING_GB2312,
+    FT_ENCODING_MS_BIG5    = FT_ENCODING_BIG5,
+    FT_ENCODING_MS_WANSUNG = FT_ENCODING_WANSUNG,
+    FT_ENCODING_MS_JOHAB   = FT_ENCODING_JOHAB,
 
     FT_ENC_TAG( FT_ENCODING_ADOBE_STANDARD, 'A', 'D', 'O', 'B' ),
     FT_ENC_TAG( FT_ENCODING_ADOBE_EXPERT,   'A', 'D', 'B', 'E' ),
@@ -550,11 +636,11 @@
   /*   ft_encoding_unicode :: see @FT_ENCODING_UNICODE                     */
   /*   ft_encoding_latin_2 :: see @FT_ENCODING_OLD_LATIN_2                 */
   /*   ft_encoding_symbol  :: see @FT_ENCODING_MS_SYMBOL                   */
-  /*   ft_encoding_sjis    :: see @FT_ENCODING_MS_SJIS                     */
-  /*   ft_encoding_gb2312  :: see @FT_ENCODING_MS_GB2312                   */
-  /*   ft_encoding_big5    :: see @FT_ENCODING_MS_BIG5                     */
-  /*   ft_encoding_wansung :: see @FT_ENCODING_MS_WANSUNG                  */
-  /*   ft_encoding_johab   :: see @FT_ENCODING_MS_JOHAB                    */
+  /*   ft_encoding_sjis    :: see @FT_ENCODING_SJIS                        */
+  /*   ft_encoding_gb2312  :: see @FT_ENCODING_GB2312                      */
+  /*   ft_encoding_big5    :: see @FT_ENCODING_BIG5                        */
+  /*   ft_encoding_wansung :: see @FT_ENCODING_WANSUNG                     */
+  /*   ft_encoding_johab   :: see @FT_ENCODING_JOHAB                       */
   /*                                                                       */
   /*   ft_encoding_adobe_standard :: see @FT_ENCODING_ADOBE_STANDARD       */
   /*   ft_encoding_adobe_expert   :: see @FT_ENCODING_ADOBE_EXPERT         */
@@ -563,21 +649,21 @@
   /*                                                                       */
   /*   ft_encoding_apple_roman    :: see @FT_ENCODING_APPLE_ROMAN          */
   /*                                                                       */
-#define  ft_encoding_none            FT_ENCODING_NONE
-#define  ft_encoding_unicode         FT_ENCODING_UNICODE
-#define  ft_encoding_symbol          FT_ENCODING_MS_SYMBOL
-#define  ft_encoding_latin_1         FT_ENCODING_ADOBE_LATIN_1
-#define  ft_encoding_latin_2         FT_ENCODING_OLD_LATIN_2
-#define  ft_encoding_sjis            FT_ENCODING_MS_SJIS
-#define  ft_encoding_gb2312          FT_ENCODING_MS_GB2312
-#define  ft_encoding_big5            FT_ENCODING_MS_BIG5
-#define  ft_encoding_wansung         FT_ENCODING_MS_WANSUNG
-#define  ft_encoding_johab           FT_ENCODING_MS_JOHAB
+#define ft_encoding_none            FT_ENCODING_NONE
+#define ft_encoding_unicode         FT_ENCODING_UNICODE
+#define ft_encoding_symbol          FT_ENCODING_MS_SYMBOL
+#define ft_encoding_latin_1         FT_ENCODING_ADOBE_LATIN_1
+#define ft_encoding_latin_2         FT_ENCODING_OLD_LATIN_2
+#define ft_encoding_sjis            FT_ENCODING_SJIS
+#define ft_encoding_gb2312          FT_ENCODING_GB2312
+#define ft_encoding_big5            FT_ENCODING_BIG5
+#define ft_encoding_wansung         FT_ENCODING_WANSUNG
+#define ft_encoding_johab           FT_ENCODING_JOHAB
 
-#define  ft_encoding_adobe_standard  FT_ENCODING_ADOBE_STANDARD
-#define  ft_encoding_adobe_expert    FT_ENCODING_ADOBE_EXPERT
-#define  ft_encoding_adobe_custom    FT_ENCODING_ADOBE_CUSTOM
-#define  ft_encoding_apple_roman     FT_ENCODING_APPLE_ROMAN
+#define ft_encoding_adobe_standard  FT_ENCODING_ADOBE_STANDARD
+#define ft_encoding_adobe_expert    FT_ENCODING_ADOBE_EXPERT
+#define ft_encoding_adobe_custom    FT_ENCODING_ADOBE_CUSTOM
+#define ft_encoding_apple_roman     FT_ENCODING_APPLE_ROMAN
 
 
   /*************************************************************************/
@@ -692,8 +778,8 @@
   /*                                                                       */
   /*    num_fixed_sizes     :: The number of fixed sizes available in this */
   /*                           face.  This should be set to 0 for scalable */
-  /*                           fonts, unless its face includes a complete  */
-  /*                           set of glyphs (called a `strike') for the   */
+  /*                           fonts, unless its face includes a set of    */
+  /*                           glyphs (called a `strike') for the          */
   /*                           specified sizes.                            */
   /*                                                                       */
   /*    available_sizes     :: An array of sizes specifying the available  */
@@ -743,10 +829,11 @@
   /*    descender           :: The face's descender is the vertical        */
   /*                           distance from the baseline to the           */
   /*                           bottommost point of any glyph in the face.  */
-  /*                           This field's value is *negative*, expressed */
-  /*                           in font units.  Some font designs use a     */
-  /*                           value different from `bbox.yMin'.  Only     */
-  /*                           relevant for scalable formats.              */
+  /*                           This field's value is *negative* for values */
+  /*                           below the baseline.  It is expressed in     */
+  /*                           font units.  Some font designs use a value  */
+  /*                           different from `bbox.yMin'.  Only relevant  */
+  /*                           for scalable formats.                       */
   /*                                                                       */
   /*    height              :: The face's height is the vertical distance  */
   /*                           from one baseline to the next when writing  */
@@ -862,7 +949,7 @@
   /*    FT_FACE_FLAG_SCALABLE ::                                           */
   /*      Indicates that the face provides vectorial outlines.  This       */
   /*      doesn't prevent embedded bitmaps, i.e., a face can have both     */
-  /*      this bit and @FT_FACE_FLAG_FIXED_SIZES set                       */
+  /*      this bit and @FT_FACE_FLAG_FIXED_SIZES set.                      */
   /*                                                                       */
   /*    FT_FACE_FLAG_FIXED_SIZES ::                                        */
   /*      Indicates that the face contains `fixed sizes', i.e., bitmap     */
@@ -901,9 +988,9 @@
   /*                                                                       */
   /*    FT_FACE_FLAG_GLYPH_NAMES ::                                        */
   /*      Indicates that the font contains glyph names that can be         */
-  /*      retrieved through @FT_Get_Glyph_Names.  Note that some TrueType  */
+  /*      retrieved through @FT_Get_Glyph_Name.  Note that some TrueType   */
   /*      fonts contain broken glyph name tables.  Use the function        */
-  /*      @FT_Has_PS_Glyph_Name when needed.                               */
+  /*      @FT_Has_PS_Glyph_Names when needed.                              */
   /*                                                                       */
   /*    FT_FACE_FLAG_EXTERNAL_STREAM ::                                    */
   /*      Used internally by FreeType to indicate that a face's stream was */
@@ -1016,12 +1103,12 @@
   /*************************************************************************/
   /*                                                                       */
   /* @macro:                                                               */
-  /*    FT_IS_FIXED_SIZES( face )                                          */
+  /*    FT_HAS_FIXED_SIZES( face )                                         */
   /*                                                                       */
   /* @description:                                                         */
   /*    A macro that returns true whenever a face object contains some     */
-  /*    embedded bitmaps.  See the `fixed_sizes' field of the @FT_FaceRec  */
-  /*    structure.                                                         */
+  /*    embedded bitmaps.  See the `available_sizes' field of the          */
+  /*    @FT_FaceRec structure.                                             */
   /*                                                                       */
 #define FT_HAS_FIXED_SIZES( face ) \
           ( face->face_flags & FT_FACE_FLAG_FIXED_SIZES )
@@ -1050,7 +1137,7 @@
   /*                                                                       */
   /* @description:                                                         */
   /*    A macro that returns true whenever a face object contains some     */
-  /*    glyph names that can be accessed through @FT_Get_Glyph_Names.      */
+  /*    glyph names that can be accessed through @FT_Get_Glyph_Name.       */
   /*                                                                       */
 #define FT_HAS_GLYPH_NAMES( face ) \
           ( face->face_flags & FT_FACE_FLAG_GLYPH_NAMES )
@@ -1130,10 +1217,12 @@
   /*                    units to fractional (26.6) pixel coordinates.      */
   /*                                                                       */
   /*    ascender     :: The ascender, expressed in 26.6 fixed point        */
-  /*                    pixels.  Always positive.                          */
+  /*                    pixels.  Positive for ascenders above the          */
+  /*                    baseline.                                          */
   /*                                                                       */
   /*    descender    :: The descender, expressed in 26.6 fixed point       */
-  /*                    pixels.  Always negative.                          */
+  /*                    pixels.  Negative for descenders below the         */
+  /*                    baseline.                                          */
   /*                                                                       */
   /*    height       :: The text height, expressed in 26.6 fixed point     */
   /*                    pixels.  Always positive.                          */
@@ -1142,12 +1231,12 @@
   /*                    fixed point pixels.  Always positive.              */
   /*                                                                       */
   /* <Note>                                                                */
-  /*    The values of `ascender', `descender', and `height' are only the   */
-  /*    scaled versions of `face->ascender', `face->descender', and        */
-  /*    `face->height'.                                                    */
+  /*    For scalable fonts, the values of `ascender', `descender', and     */
+  /*    `height' are scaled versions of `face->ascender',                  */
+  /*    `face->descender', and `face->height', respectively.               */
   /*                                                                       */
   /*    Unfortunately, due to glyph hinting, these values might not be     */
-  /*    exact for certain fonts, they thus must be treated as unreliable   */
+  /*    exact for certain fonts.  They thus must be treated as unreliable  */
   /*    with an error margin of at least one pixel!                        */
   /*                                                                       */
   /*    Indeed, the only way to get the exact pixel ascender and descender */
@@ -1161,7 +1250,7 @@
     FT_UShort  y_ppem;      /* vertical pixels per EM                 */
 
     FT_Fixed   x_scale;     /* two scales used to convert font units  */
-    FT_Fixed   y_scale;     /* to 26.6 frac. pixel coordinates..      */
+    FT_Fixed   y_scale;     /* to 26.6 frac. pixel coordinates        */
 
     FT_Pos     ascender;    /* ascender in 26.6 frac. pixels          */
     FT_Pos     descender;   /* descender in 26.6 frac. pixels         */
@@ -1311,16 +1400,18 @@
   /*                                                                       */
   /*    outline           :: The outline descriptor for the current glyph  */
   /*                         image if its format is                        */
-  /*                         ft_glyph_bitmap_outline.                      */
+  /*                         FT_GLYPH_FORMAT_OUTLINE.                      */
   /*                                                                       */
   /*    num_subglyphs     :: The number of subglyphs in a composite glyph. */
-  /*                         This format is only valid for the composite   */
-  /*                         glyph format, that should normally only be    */
-  /*                         loaded with the FT_LOAD_NO_RECURSE flag.      */
+  /*                         This field is only valid for the composite    */
+  /*                         glyph format that should normally only be     */
+  /*                         loaded with the @FT_LOAD_NO_RECURSE flag.     */
+  /*                         For now this is internal to FreeType.         */
   /*                                                                       */
   /*    subglyphs         :: An array of subglyph descriptors for          */
   /*                         composite glyphs.  There are `num_subglyphs'  */
-  /*                         elements in there.                            */
+  /*                         elements in there.  Currently internal to     */
+  /*                         FreeType.                                     */
   /*                                                                       */
   /*    control_data      :: Certain font drivers can also return the      */
   /*                         control data for a given glyph image (e.g.    */
@@ -1359,7 +1450,7 @@
     FT_Library        library;
     FT_Face           face;
     FT_GlyphSlot      next;
-    FT_UInt           flags;
+    FT_UInt           reserved;       /* retained for binary compatibility */
     FT_Generic        generic;
 
     FT_Glyph_Metrics  metrics;
@@ -1474,13 +1565,13 @@
   /*************************************************************************/
   /*                                                                       */
   /* <Enum>                                                                */
-  /*    FT_Open_Flags                                                      */
+  /*    FT_OPEN_XXX                                                        */
   /*                                                                       */
   /* <Description>                                                         */
-  /*    An enumeration used to list the bit flags used within the          */
-  /*    `flags' field of the @FT_Open_Args structure.                      */
+  /*    A list of bit-field constants used within the `flags' field of the */
+  /*    @FT_Open_Args structure.                                           */
   /*                                                                       */
-  /* <Fields>                                                              */
+  /* <Values>                                                              */
   /*    FT_OPEN_MEMORY      :: This is a memory-based stream.              */
   /*                                                                       */
   /*    FT_OPEN_STREAM      :: Copy the stream from the `stream' field.    */
@@ -1492,35 +1583,31 @@
   /*                                                                       */
   /*    FT_OPEN_PARAMS      :: Use the `num_params' & `params' field.      */
   /*                                                                       */
-  /*    ft_open_memory :: deprecated. use @FT_OPEN_MEMORY instead          */
+  /*    ft_open_memory      :: Deprecated; use @FT_OPEN_MEMORY instead.    */
   /*                                                                       */
-  /*    ft_open_stream :: deprecated. use @FT_OPEN_STREAM instead          */
+  /*    ft_open_stream      :: Deprecated; use @FT_OPEN_STREAM instead.    */
   /*                                                                       */
-  /*    ft_open_pathname :: deprecated. use @FT_OPEN_PATHNAME instead      */
+  /*    ft_open_pathname    :: Deprecated; use @FT_OPEN_PATHNAME instead.  */
   /*                                                                       */
-  /*    ft_open_driver :: deprecated, use @FT_OPEN_DRIVER instead          */
+  /*    ft_open_driver      :: Deprecated; use @FT_OPEN_DRIVER instead.    */
   /*                                                                       */
-  /*    ft_open_params :: deprecated, use @FT_OPEN_PARAMS instead          */
+  /*    ft_open_params      :: Deprecated; use @FT_OPEN_PARAMS instead.    */
   /*                                                                       */
   /* <Note>                                                                */
   /*    The `FT_OPEN_MEMORY', `FT_OPEN_STREAM', and `FT_OPEN_PATHNAME'     */
   /*    flags are mutually exclusive.                                      */
   /*                                                                       */
-  typedef enum
-  {
-    FT_OPEN_MEMORY   = 1,
-    FT_OPEN_STREAM   = 2,
-    FT_OPEN_PATHNAME = 4,
-    FT_OPEN_DRIVER   = 8,
-    FT_OPEN_PARAMS   = 16
-
-  } FT_Open_Flags;
+#define FT_OPEN_MEMORY    0x1
+#define FT_OPEN_STREAM    0x2
+#define FT_OPEN_PATHNAME  0x4
+#define FT_OPEN_DRIVER    0x8
+#define FT_OPEN_PARAMS    0x10
 
-#define  ft_open_memory    FT_OPEN_MEMORY     /* deprecated */
-#define  ft_open_stream    FT_OPEN_STREAM     /* deprecated */
-#define  ft_open_pathname  FT_OPEN_PATHNAME   /* deprecated */
-#define  ft_open_driver    FT_OPEN_DRIVER     /* deprecated */
-#define  ft_open_params    FT_OPEN_PARAMS     /* deprecated */
+#define ft_open_memory    FT_OPEN_MEMORY     /* deprecated */
+#define ft_open_stream    FT_OPEN_STREAM     /* deprecated */
+#define ft_open_pathname  FT_OPEN_PATHNAME   /* deprecated */
+#define ft_open_driver    FT_OPEN_DRIVER     /* deprecated */
+#define ft_open_params    FT_OPEN_PARAMS     /* deprecated */
 
 
   /*************************************************************************/
@@ -1602,14 +1689,14 @@
   /*                                                                       */
   typedef struct  FT_Open_Args_
   {
-    FT_Open_Flags              flags;
-    const FT_Byte*             memory_base;
-    FT_Long                    memory_size;
-    FT_String*                 pathname;
-    FT_Stream                  stream;
-    FT_Module                  driver;
-    FT_Int                     num_params;
-    FT_Parameter*              params;
+    FT_UInt         flags;
+    const FT_Byte*  memory_base;
+    FT_Long         memory_size;
+    FT_String*      pathname;
+    FT_Stream       stream;
+    FT_Module       driver;
+    FT_Int          num_params;
+    FT_Parameter*   params;
 
   } FT_Open_Args;
 
@@ -1853,7 +1940,7 @@
   /*    character dimensions is zero, its value is set equal to the other. */
   /*                                                                       */
   /* <InOut>                                                               */
-  /*    size            :: A handle to a target size object.               */
+  /*    face            :: A handle to a target face object.               */
   /*                                                                       */
   /* <Input>                                                               */
   /*    char_width      :: The character width, in 26.6 fractional points. */
@@ -1870,7 +1957,7 @@
   /*                                                                       */
   /* <Note>                                                                */
   /*    When dealing with fixed-size faces (i.e., non-scalable formats),   */
-  /*    use the function @FT_Set_Pixel_Sizes.                              */
+  /*    @FT_Set_Pixel_Sizes provides a more convenient interface.          */
   /*                                                                       */
   FT_EXPORT( FT_Error )
   FT_Set_Char_Size( FT_Face     face,
@@ -1903,7 +1990,6 @@
   /* <Return>                                                              */
   /*    FreeType error code.  0 means success.                             */
   /*                                                                       */
-  /*                                                                       */
   /* <Note>                                                                */
   /*    The values of `pixel_width' and `pixel_height' correspond to the   */
   /*    pixel values of the _typographic_ character size, which are NOT    */
@@ -1919,6 +2005,11 @@
   /*    guarantee in any way that you will get glyph bitmaps that all fit  */
   /*    within an 8x8 cell (sometimes even far from it).                   */
   /*                                                                       */
+  /*    For bitmap fonts, `pixel_height' usually is a reliable value for   */
+  /*    the height of the bitmap cell.  Drivers for bitmap font formats    */
+  /*    which contain a single bitmap strike only (BDF, PCF, FNT) ignore   */
+  /*    `pixel_width'.                                                     */
+  /*                                                                       */
   FT_EXPORT( FT_Error )
   FT_Set_Pixel_Sizes( FT_Face  face,
                       FT_UInt  pixel_width,
@@ -2010,7 +2101,7 @@
                 FT_Int32  load_flags );
 
 
- /****************************************************************************
+ /***************************************************************************
   *
   * @enum:
   *   FT_LOAD_XXX
@@ -2131,6 +2222,7 @@
   *     being used.  This can be important for certain fonts where unhinted
   *     output is better than auto-hinted one.
   */
+#define FT_LOAD_DEFAULT                      0x0
 #define FT_LOAD_NO_SCALE                     0x1
 #define FT_LOAD_NO_HINTING                   0x2
 #define FT_LOAD_RENDER                       0x4
@@ -2151,16 +2243,43 @@
 
   /* */
 
+
 #define FT_LOAD_TARGET_( x )      ( (FT_Int32)( (x) & 15 ) << 16 )
 #define FT_LOAD_TARGET_MODE( x )  ( (FT_Render_Mode)( ( (x) >> 16 ) & 15 ) )
 
+
+ /***************************************************************************
+  *
+  * @enum:
+  *   FT_LOAD_TARGET_XXX
+  *
+  * @description:
+  *   A list of load targets.  XXX
+  *
+  * @values:
+  *   FT_LOAD_TARGET_NORMAL ::
+  *     XXX
+  *
+  *   FT_LOAD_TARGET_LIGHT ::
+  *     XXX
+  *
+  *   FT_LOAD_TARGET_MONO ::
+  *     XXX
+  *
+  *   FT_LOAD_TARGET_LCD ::
+  *     XXX
+  *
+  *   FT_LOAD_TARGET_LCD_V ::
+  *     XXX
+  */
+
 #define FT_LOAD_TARGET_NORMAL     FT_LOAD_TARGET_( FT_RENDER_MODE_NORMAL )
 #define FT_LOAD_TARGET_LIGHT      FT_LOAD_TARGET_( FT_RENDER_MODE_LIGHT  )
 #define FT_LOAD_TARGET_MONO       FT_LOAD_TARGET_( FT_RENDER_MODE_MONO   )
 #define FT_LOAD_TARGET_LCD        FT_LOAD_TARGET_( FT_RENDER_MODE_LCD    )
 #define FT_LOAD_TARGET_LCD_V      FT_LOAD_TARGET_( FT_RENDER_MODE_LCD_V  )
 
-#define FT_LOAD_DEFAULT           0x0
+  /* */
 
 
   /*************************************************************************/
@@ -2186,7 +2305,7 @@
   /*    The transformation is only applied to scalable image formats after */
   /*    the glyph has been loaded.  It means that hinting is unaltered by  */
   /*    the transformation and is performed on the character size given in */
-  /*    the last call to @FT_Set_Char_Sizes or @FT_Set_Pixel_Sizes.        */
+  /*    the last call to @FT_Set_Char_Size or @FT_Set_Pixel_Sizes.         */
   /*                                                                       */
   FT_EXPORT( void )
   FT_Set_Transform( FT_Face     face,
@@ -2205,6 +2324,10 @@
   /*    conversion performed on the outline, as well as specific           */
   /*    hinting optimizations.                                             */
   /*                                                                       */
+  /*    For bitmap fonts the `bitmap->pixel_mode' field in the             */
+  /*    @FT_GlyphSlotRec structure gives the format of the returned        */
+  /*    bitmap.                                                            */
+  /*                                                                       */
   /* <Values>                                                              */
   /*    FT_RENDER_MODE_NORMAL ::                                           */
   /*      This is the default render mode; it corresponds to 8-bit         */
@@ -2212,11 +2335,10 @@
   /*                                                                       */
   /*    FT_RENDER_MODE_LIGHT ::                                            */
   /*      This is similar to @FT_RENDER_MODE_NORMAL, except that this      */
-  /*      changes the hinting to prevent stem width quantization. This     */
+  /*      changes the hinting to prevent stem width quantization.  This    */
   /*      results in glyph shapes that are more similar to the original,   */
   /*      while being a bit more fuzzy ("better shapes", instead of        */
-  /*      "better contrast" if you want :-) THIS IS STILL EXPERIMENTAL,    */
-  /*      FOR NOW, THIS WILL PRODUCE RESULTS SIMILAR TO NORMAL MODE !!     */
+  /*      "better contrast" if you want :-).                               */
   /*                                                                       */
   /*    FT_RENDER_MODE_MONO ::                                             */
   /*      This mode corresponds to 1-bit bitmaps.                          */
@@ -2225,8 +2347,7 @@
   /*      This mode corresponds to horizontal RGB/BGR sub-pixel displays,  */
   /*      like LCD-screens.  It produces 8-bit bitmaps that are 3 times    */
   /*      the width of the original glyph outline in pixels, and which use */
-  /*      the @FT_PIXEL_MODE_LCD mode. THIS IS STILL EXPERIMENTAL, DO NOT  */
-  /*      USE FOR NOW !!                                                   */
+  /*      the @FT_PIXEL_MODE_LCD mode.                                     */
   /*                                                                       */
   /*    FT_RENDER_MODE_LCD_V ::                                            */
   /*      This mode corresponds to vertical RGB/BGR sub-pixel displays     */
@@ -2237,8 +2358,7 @@
   /* <Note>                                                                */
   /*   The LCD-optimized glyph bitmaps produced by FT_Render_Glyph are     */
   /*   _not filtered_ to reduce color-fringes.  It is up to the caller to  */
-  /*   perform this pass. THIS IS STILL EXPERIMENTAL, DO NOT USE FOR NOW   */
-  /*   !!                                                                  */
+  /*   perform this pass.                                                  */
   /*                                                                       */
   typedef enum  FT_Render_Mode_
   {
@@ -2770,7 +2890,7 @@
   /* <Note>                                                                */
   /*    The optimization for FT_DivFix() is simple: If (a << 16) fits in   */
   /*    32 bits, then the division is computed directly.  Otherwise, we    */
-  /*    use a specialized version of the old @FT_MulDiv64.                 */
+  /*    use a specialized version of @FT_MulDiv.                           */
   /*                                                                       */
   FT_EXPORT( FT_Long )
   FT_DivFix( FT_Long  a,

Index: ftbbox.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftbbox.h,v
retrieving revision 1.1
retrieving revision 1.1.4.1
diff -u -d -r1.1 -r1.1.4.1
--- a/ftbbox.h	14 Nov 2003 16:48:24 -0000	1.1
+++ b/ftbbox.h	23 Feb 2004 21:32:25 -0000	1.1.4.1
@@ -4,7 +4,7 @@
 /*                                                                         */
 /*    FreeType exact bbox computation (specification).                     */
 /*                                                                         */
-/*  Copyright 1996-2001 by                                                 */
+/*  Copyright 1996-2001, 2003 by                                           */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -34,6 +34,12 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
 
 FT_BEGIN_HEADER
 

Index: ftbdf.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftbdf.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/ftbdf.h	26 Nov 2003 22:48:24 -0000	1.1.4.1
+++ b/ftbdf.h	23 Feb 2004 21:32:25 -0000	1.1.4.2
@@ -4,7 +4,7 @@
 /*                                                                         */
 /*    FreeType API for accessing BDF-specific strings (specification).     */
 /*                                                                         */
-/*  Copyright 2002 by                                                      */
+/*  Copyright 2002, 2003 by                                                */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -22,6 +22,12 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
 
 FT_BEGIN_HEADER
 
@@ -49,22 +55,22 @@
   *    FT_PropertyType
   *
   * @description:
-  *    list of BDF property types
+  *    A list of BDF property types.
   *
   * @values:
   *    BDF_PROPERTY_TYPE_NONE ::
-  *      value 0 is used to indicate a missing property
+  *      Value 0 is used to indicate a missing property.
   *
   *    BDF_PROPERTY_TYPE_ATOM ::
-  *      property is a string atom
+  *      Property is a string atom.
   *
   *    BDF_PROPERTY_TYPE_INTEGER ::
-  *      property is a 32-bit signed integer
+  *      Property is a 32-bit signed integer.
   *
   *    BDF_PROPERTY_TYPE_CARDINAL ::
-  *      property is a 32-bit unsigned integer
+  *      Property is a 32-bit unsigned integer.
   */
-  typedef enum
+  typedef enum  BDF_PropertyType_
   {
     BDF_PROPERTY_TYPE_NONE     = 0,
     BDF_PROPERTY_TYPE_ATOM     = 1,
@@ -76,34 +82,44 @@
 
  /**********************************************************************
   *
-  * @type:  BDF_Property
+  * @type:
+  *    BDF_Property
   *
   * @description:
-  *    handle to a @BDF_PropertyRec structure used to model a given
-  *    BDF/PCF property
+  *    A handle to a @BDF_PropertyRec structure to model a given
+  *    BDF/PCF property.
   */
-  typedef struct BDF_PropertyRec_*   BDF_Property;
+  typedef struct BDF_PropertyRec_*  BDF_Property;
+
 
  /**********************************************************************
   *
-  * @struct:  BDF_PropertyRec
+  * @struct:
+  *    BDF_PropertyRec
   *
   * @description:
-  *    models a given BDF/PCF property
+  *    This structure models a given BDF/PCF property.
   *
-  * @note:
-  *    type       :: property type
-  *    u.atom     :: atom string, when type is @BDF_PROPERTY_TYPE_ATOM
-  *    u.integer  :: signed integer, when type is @BDF_PROPERTY_TYPE_INTEGER
-  *    u.cardinal :: unsigned integer, when type is @BDF_PROPERTY_TYPE_CARDINAL
+  * @fields:
+  *    type ::
+  *      The property type.
+  *
+  *    u.atom ::
+  *      The atom string, if type is @BDF_PROPERTY_TYPE_ATOM.
+  *
+  *    u.integer ::
+  *      A signed integer, if type is @BDF_PROPERTY_TYPE_INTEGER.
+  *
+  *    u.cardinal ::
+  *      An unsigned integer, if type is @BDF_PROPERTY_TYPE_CARDINAL.
   */
-  typedef struct BDF_PropertyRec_
+  typedef struct  BDF_PropertyRec_
   {
-    BDF_PropertyType   type;
+    BDF_PropertyType  type;
     union {
-      const char*   atom;
-      FT_Int32      integer;
-      FT_UInt32     cardinal;
+      const char*     atom;
+      FT_Int32        integer;
+      FT_UInt32       cardinal;
 
     } u;
 
@@ -121,7 +137,7 @@
   *
   * @input:
   *    face ::
-  *       handle to input face
+  *       A handle to the input face.
   *
   * @output:
   *    acharset_encoding ::
@@ -131,7 +147,7 @@
   *       Charset registry, as a C string, owned by the face.
   *
   * @return:
-  *   FreeType rror code.  0 means success.
+  *   FreeType error code.  0 means success.
   *
   * @note:
   *   This function only works with BDF faces, returning an error otherwise.
@@ -141,31 +157,33 @@
                          const char*  *acharset_encoding,
                          const char*  *acharset_registry );
 
+
  /**********************************************************************
   *
   * @function:
   *    FT_Get_BDF_Property
   *
   * @description:
-  *    Retrieves a BDF property from a BDF or PCF font file
+  *    Retrieves a BDF property from a BDF or PCF font file.
   *
   * @input:
-  *    face :: handle to input face
-  *    name :: property name
+  *    face :: A handle to the input face.
+  *
+  *    name :: The property name.
   *
   * @output:
-  *    aproperty :: the property
+  *    aproperty :: The property.
   *
   * @return:
   *   FreeType error code.  0 means success.
   *
   * @note:
-  *   This function works with BDF _and_ PCF fonts. It returns an error
-  *   otherwise. it also returns an error when the property is not in the
+  *   This function works with BDF _and_ PCF fonts.  It returns an error
+  *   otherwise.  It also returns an error if the property is not in the
   *   font.
   *
-  *   in case of error, "aproperty->type" is always set to
-  *   @BDF_PROPERTY_TYPE_NONE
+  *   In case of error, "aproperty->type" is always set to
+  *   @BDF_PROPERTY_TYPE_NONE.
   */
   FT_EXPORT( FT_Error )
   FT_Get_BDF_Property( FT_Face           face,

Index: ftcache.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftcache.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/ftcache.h	26 Nov 2003 22:48:24 -0000	1.1.4.1
+++ b/ftcache.h	23 Feb 2004 21:32:25 -0000	1.1.4.2
@@ -4,7 +4,7 @@
 /*                                                                         */
 /*    FreeType Cache subsystem (specification).                            */
 /*                                                                         */
-/*  Copyright 1996-2001 by                                                 */
+/*  Copyright 1996-2001, 2002, 2003 by                                     */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -71,7 +71,6 @@
   /*   FTC_Node_Unref                                                      */
   /*                                                                       */
   /*   FTC_Font                                                            */
-  /*   FTC_ImageDesc                                                       */
   /*   FTC_ImageCache                                                      */
   /*   FTC_ImageCache_New                                                  */
   /*   FTC_ImageCache_Lookup                                               */
@@ -242,9 +241,9 @@
   /*    If you lookup nodes, you have the ability to "acquire" them, i.e., */
   /*    to increment their reference count.  This will prevent the node    */
   /*    from being flushed out of the cache until you explicitly "release" */
-  /*    it (see @FTC_Node_Release).                                        */
+  /*    it (see @FTC_Node_Unref).                                          */
   /*                                                                       */
-  /*    See also @FTC_BitsetCache_Lookup and @FTC_ImageCache_Lookup.       */
+  /*    See also @FTC_SBitCache_Lookup and @FTC_ImageCache_Lookup.         */
   /*                                                                       */
   typedef struct FTC_NodeRec_*  FTC_Node;
 
@@ -368,12 +367,12 @@
   /*                                                                       */
   /* <Description>                                                         */
   /*    Retrieves the @FT_Face and @FT_Size objects that correspond to a   */
-  /*    given @FTC_SizeID.                                                 */
+  /*    given font.                                                        */
   /*                                                                       */
   /* <Input>                                                               */
   /*    manager :: A handle to the cache manager.                          */
   /*                                                                       */
-  /*    size_id :: The ID of the `font size' to use.                       */
+  /*    font    :: The font to use.                                        */
   /*                                                                       */
   /* <Output>                                                              */
   /*    aface   :: A pointer to the handle of the face object.  Set it to  */

Index: ftglyph.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftglyph.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/ftglyph.h	26 Nov 2003 22:48:24 -0000	1.1.4.1
+++ b/ftglyph.h	23 Feb 2004 21:32:25 -0000	1.1.4.2
@@ -4,7 +4,7 @@
 /*                                                                         */
 /*    FreeType convenience functions to handle glyphs (specification).     */
 /*                                                                         */
-/*  Copyright 1996-2001 by                                                 */
+/*  Copyright 1996-2001, 2002, 2003 by                                     */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -36,6 +36,12 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
 
 FT_BEGIN_HEADER
 
@@ -235,7 +241,8 @@
   /*    FT_Glyph_Copy                                                      */
   /*                                                                       */
   /* <Description>                                                         */
-  /*    A function used to copy a glyph image.                             */
+  /*    A function used to copy a glyph image.  Note that the created      */
+  /*    @FT_Glyph object must be released with @FT_Done_Glyph.             */
   /*                                                                       */
   /* <Input>                                                               */
   /*    source :: A handle to the source glyph object.                     */
@@ -282,7 +289,64 @@
                       FT_Matrix*  matrix,
                       FT_Vector*  delta );
 
-  /* */
+
+  /*************************************************************************/
+  /*                                                                       */
+  /* <Enum>                                                                */
+  /*    FT_Glyph_BBox_Mode                                                 */
+  /*                                                                       */
+  /* <Description>                                                         */
+  /*    The mode how the values of @FT_Glyph_Get_CBox are returned.        */
+  /*                                                                       */
+  /* <Values>                                                              */
+  /*    FT_GLYPH_BBOX_UNSCALED ::                                          */
+  /*      Return unscaled font units.                                      */
+  /*                                                                       */
+  /*    FT_GLYPH_BBOX_SUBPIXELS ::                                         */
+  /*      Return unfitted 26.6 coordinates.                                */
+  /*                                                                       */
+  /*    FT_GLYPH_BBOX_GRIDFIT ::                                           */
+  /*      Return grid-fitted 26.6 coordinates.                             */
+  /*                                                                       */
+  /*    FT_GLYPH_BBOX_TRUNCATE ::                                          */
+  /*      Return coordinates in integer pixels.                            */
+  /*                                                                       */
+  /*    FT_GLYPH_BBOX_PIXELS ::                                            */
+  /*      Return grid-fitted pixel coordinates.                            */
+  /*                                                                       */
+  typedef enum  FT_Glyph_BBox_Mode_
+  {
+    FT_GLYPH_BBOX_UNSCALED  = 0,
+    FT_GLYPH_BBOX_SUBPIXELS = 0,
+    FT_GLYPH_BBOX_GRIDFIT   = 1,
+    FT_GLYPH_BBOX_TRUNCATE  = 2,
+    FT_GLYPH_BBOX_PIXELS    = 3
+
+  } FT_Glyph_BBox_Mode;
+
+
+  /*************************************************************************/
+  /*                                                                       */
+  /* <Enum>                                                                */
+  /*    ft_glyph_bbox_xxx                                                  */
+  /*                                                                       */
+  /* <Description>                                                         */
+  /*    These constants are deprecated.  Use the corresponding             */
+  /*    @FT_Glyph_BBox_Mode values instead.                                */
+  /*                                                                       */
+  /* <Values>                                                              */
+  /*   ft_glyph_bbox_unscaled  :: see @FT_GLYPH_BBOX_UNSCALED              */
+  /*   ft_glyph_bbox_subpixels :: see @FT_GLYPH_BBOX_SUBPIXELS             */
+  /*   ft_glyph_bbox_gridfit   :: see @FT_GLYPH_BBOX_GRIDFIT               */
+  /*   ft_glyph_bbox_truncate  :: see @FT_GLYPH_BBOX_TRUNCATE              */
+  /*   ft_glyph_bbox_pixels    :: see @FT_GLYPH_BBOX_PIXELS                */
+  /*                                                                       */
+#define ft_glyph_bbox_unscaled   FT_GLYPH_BBOX_UNSCALED
+#define ft_glyph_bbox_subpixels  FT_GLYPH_BBOX_SUBPIXELS
+#define ft_glyph_bbox_gridfit    FT_GLYPH_BBOX_GRIDFIT
+#define ft_glyph_bbox_truncate   FT_GLYPH_BBOX_TRUNCATE
+#define ft_glyph_bbox_pixels     FT_GLYPH_BBOX_PIXELS
+
 
   /*************************************************************************/
   /*                                                                       */
@@ -316,11 +380,9 @@
   /*    convention.                                                        */
   /*                                                                       */
   /*    If the glyph has been loaded with FT_LOAD_NO_SCALE, `bbox_mode'    */
-  /*    must be set to `ft_glyph_bbox_unscaled' to get unscaled font       */
-  /*    units.                                                             */
-  /*                                                                       */
-  /*    If `bbox_mode' is set to `ft_glyph_bbox_subpixels' the bbox        */
-  /*    coordinates are returned in 26.6 pixels (i.e. 1/64th of pixels).   */
+  /*    must be set to `FT_GLYPH_BBOX_UNSCALED' to get unscaled font       */
+  /*    units in 26.6 pixel format.  The value `FT_GLYPH_BBOX_SUBPIXELS'   */
+  /*    is another name for this constant.                                 */
   /*                                                                       */
   /*    Note that the maximum coordinates are exclusive, which means that  */
   /*    one can compute the width and height of the glyph image (be it in  */
@@ -330,7 +392,7 @@
   /*      height = bbox.yMax - bbox.yMin;                                  */
   /*                                                                       */
   /*    Note also that for 26.6 coordinates, if `bbox_mode' is set to      */
-  /*    `ft_glyph_bbox_gridfit', the coordinates will also be grid-fitted, */
+  /*    `FT_GLYPH_BBOX_GRIDFIT', the coordinates will also be grid-fitted, */
   /*    which corresponds to:                                              */
   /*                                                                       */
   /*      bbox.xMin = FLOOR(bbox.xMin);                                    */
@@ -339,23 +401,11 @@
   /*      bbox.yMax = CEILING(bbox.yMax);                                  */
   /*                                                                       */
   /*    To get the bbox in pixel coordinates, set `bbox_mode' to           */
-  /*    `ft_glyph_bbox_truncate'.                                          */
+  /*    `FT_GLYPH_BBOX_TRUNCATE'.                                          */
   /*                                                                       */
   /*    To get the bbox in grid-fitted pixel coordinates, set `bbox_mode'  */
-  /*    to `ft_glyph_bbox_pixels'.                                         */
-  /*                                                                       */
-  /*    The default value for `bbox_mode' is `ft_glyph_bbox_pixels'.       */
+  /*    to `FT_GLYPH_BBOX_PIXELS'.                                         */
   /*                                                                       */
-  enum
-  {
-    ft_glyph_bbox_unscaled  = 0, /* return unscaled font units           */
-    ft_glyph_bbox_subpixels = 0, /* return unfitted 26.6 coordinates     */
-    ft_glyph_bbox_gridfit   = 1, /* return grid-fitted 26.6 coordinates  */
-    ft_glyph_bbox_truncate  = 2, /* return coordinates in integer pixels */
-    ft_glyph_bbox_pixels    = 3  /* return grid-fitted pixel coordinates */
-  };
-
-
   FT_EXPORT( void )
   FT_Glyph_Get_CBox( FT_Glyph  glyph,
                      FT_UInt   bbox_mode,
@@ -391,8 +441,7 @@
   /*                                                                       */
   /* <Note>                                                                */
   /*    The glyph image is translated with the `origin' vector before      */
-  /*    rendering.  In case of error, it it translated back to its         */
-  /*    original position and the glyph is left untouched.                 */
+  /*    rendering.                                                         */
   /*                                                                       */
   /*    The first parameter is a pointer to a FT_Glyph handle, that will   */
   /*    be replaced by this function.  Typically, you would use (omitting  */
@@ -413,7 +462,7 @@
   /*        // convert to a bitmap (default render mode + destroy old)     */
   /*        if ( glyph->format != FT_GLYPH_FORMAT_BITMAP )                 */
   /*        {                                                              */
-  /*          error = FT_Glyph_To_Bitmap( &glyph, ft_render_mode_default,  */
+  /*          error = FT_Glyph_To_Bitmap( &glyph, FT_RENDER_MODE_DEFAULT,  */
   /*                                      0, 1 );                          */
   /*          if ( error ) // glyph unchanged                              */
   /*            ...                                                        */

Index: ftgzip.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftgzip.h,v
retrieving revision 1.1
retrieving revision 1.1.4.1
diff -u -d -r1.1 -r1.1.4.1
--- a/ftgzip.h	25 Nov 2003 19:27:18 -0000	1.1
+++ b/ftgzip.h	23 Feb 2004 21:32:26 -0000	1.1.4.1
@@ -4,7 +4,7 @@
 /*                                                                         */
 /*    Gzip-compressed stream support.                                      */
 /*                                                                         */
-/*  Copyright 2002 by                                                      */
+/*  Copyright 2002, 2003 by                                                */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -22,6 +22,13 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
+
 FT_BEGIN_HEADER
 
   /*************************************************************************/
@@ -40,47 +47,54 @@
   /*                                                                       */
   /*************************************************************************/
 
+
  /************************************************************************
   *
-  * @type: FT_Stream_OpenGzip
+  * @function:
+  *   FT_Stream_OpenGzip
   *
   * @description:
-  *   open a new stream to parse gzip-compressed font files. This is
+  *   Open a new stream to parse gzip-compressed font files.  This is
   *   mainly used to support the compressed *.pcf.gz fonts that come
-  *   with XFree86
+  *   with XFree86.
   *
   * @input:
-  *   stream :: target embedding stream
-  *   source :: source stream, used to
+  *   stream :: The target embedding stream.
+  *
+  *   source :: The source stream.
   *
   * @return:
-  *   error code. 0 means success
+  *   FreeType error code.  0 means success.
   *
   * @note:
-  *   the source stream must be opened _before_ calling this function.
+  *   The source stream must be opened _before_ calling this function.
   *
-  *   calling @FT_Stream_Close on the new stream will *not* call
-  *   @FT_Stream_Close on the source stream. None of the stream objects
-  *   will be released to the heap.
+  *   Calling the internal function FT_Stream_Close on the new stream will
+  *   *not* call FT_Stream_Close on the source stream.  None of the stream
+  *   objects will be released to the heap.
   *
-  *   the stream implementation is very basic, and resets the decompression
-  *   process each time seeking backwards is needed within the stream
+  *   The stream implementation is very basic and resets the decompression
+  *   process each time seeking backwards is needed within the stream.
   *
-  *   in certain builds of the library, gzip compression recognition is
-  *   automatic when calling @FT_New_Face or @FT_Open_Face. This means that
-  *   if no font driver is capable of handling the raw compressed file,
-  *   the library will try to open a gzip stream from it and re-open
-  *   the face with it.
+  *   In certain builds of the library, gzip compression recognition is
+  *   automatically handled when calling @FT_New_Face or @FT_Open_Face.
+  *   This means that if no font driver is capable of handling the raw
+  *   compressed file, the library will try to open a gzipped stream from
+  *   it and re-open the face with it.
   *
-  *   this function may return "FT_Err_Unimplemented" if your build of
+  *   This function may return "FT_Err_Unimplemented" if your build of
   *   FreeType was not compiled with zlib support.
   */
   FT_EXPORT( FT_Error )
-  FT_Stream_OpenGzip( FT_Stream    stream,
-                      FT_Stream    source );
+  FT_Stream_OpenGzip( FT_Stream  stream,
+                      FT_Stream  source );
 
  /* */
 
+
 FT_END_HEADER
 
 #endif /* __FTGZIP_H__ */
+
+
+/* END */

Index: ftimage.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftimage.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/ftimage.h	26 Nov 2003 22:48:24 -0000	1.1.4.1
+++ b/ftimage.h	23 Feb 2004 21:32:26 -0000	1.1.4.2
@@ -5,7 +5,7 @@
 /*    FreeType glyph image formats and default raster interface            */
 /*    (specification).                                                     */
 /*                                                                         */
-/*  Copyright 1996-2001, 2002 by                                           */
+/*  Copyright 1996-2001, 2002, 2003 by                                     */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -53,8 +53,8 @@
   /* <Description>                                                         */
   /*    The type FT_Pos is a 32-bit integer used to store vectorial        */
   /*    coordinates.  Depending on the context, these can represent        */
-  /*    distances in integer font units, or 26.6 fixed float pixel         */
-  /*    coordinates.                                                       */
+  /*    distances in integer font units, or 16,16, or 26.6 fixed float     */
+  /*    pixel coordinates.                                                 */
   /*                                                                       */
   typedef signed long  FT_Pos;
 
@@ -261,7 +261,8 @@
   /*                    `FT_PIXEL_MODE_GRAY'; it gives the number of gray  */
   /*                    levels used in the bitmap.                         */
   /*                                                                       */
-  /*    pixel_mode   :: The pixel_mode, i.e., how pixel bits are stored.   */
+  /*    pixel_mode   :: The pixel mode, i.e., how pixel bits are stored.   */
+  /*                    See @FT_Pixel_Mode for possible values.            */
   /*                                                                       */
   /*    palette_mode :: This field is only used with paletted pixel modes; */
   /*                    it indicates how the palette is stored.            */
@@ -357,11 +358,11 @@
   /*************************************************************************/
   /*                                                                       */
   /* <Enum>                                                                */
-  /*   FT_Outline_Flags                                                    */
+  /*   FT_OUTLINE_FLAGS                                                    */
   /*                                                                       */
   /* <Description>                                                         */
-  /*    A simple type used to enumerates the flags in an outline's         */
-  /*    `outline_flags' field.                                             */
+  /*    A list of bit-field constants use for the flags in an outline's    */
+  /*    `flags' field.                                                     */
   /*                                                                       */
   /* <Values>                                                              */
   /*    FT_OUTLINE_NONE           :: Value 0 is reserved.                  */
@@ -414,27 +415,24 @@
   /*                                 completely ignored by a given         */
   /*                                 scan-converter.                       */
   /*                                                                       */
-  typedef enum  FT_Outline_Flags_
-  {
-    FT_OUTLINE_NONE            = 0,
-    FT_OUTLINE_OWNER           = 1,
-    FT_OUTLINE_EVEN_ODD_FILL   = 2,
-    FT_OUTLINE_REVERSE_FILL    = 4,
-    FT_OUTLINE_IGNORE_DROPOUTS = 8,
-    FT_OUTLINE_HIGH_PRECISION  = 256,
-    FT_OUTLINE_SINGLE_PASS     = 512
+#define FT_OUTLINE_NONE             0x0
+#define FT_OUTLINE_OWNER            0x1
+#define FT_OUTLINE_EVEN_ODD_FILL    0x2
+#define FT_OUTLINE_REVERSE_FILL     0x4
+#define FT_OUTLINE_IGNORE_DROPOUTS  0x8
 
-  } FT_Outline_Flags;
+#define FT_OUTLINE_HIGH_PRECISION   0x100
+#define FT_OUTLINE_SINGLE_PASS      0x200
 
 
  /*************************************************************************
   *
   * @enum:
-  *   ft_outline_xxx
+  *   ft_outline_flags
   *
   * @description:
   *   These constants are deprecated.  Please use the corresponding
-  *   @FT_OUTLINE_XXX values.
+  *   @FT_OUTLINE_FLAGS values.
   *
   * @values:
   *   ft_outline_none            :: See @FT_OUTLINE_NONE.
@@ -689,8 +687,8 @@
   /*                                                                       */
   /*    FT_GLYPH_FORMAT_COMPOSITE ::                                       */
   /*      The glyph image is a composite of several other images.  This    */
-  /*      format is _only_ used with @FT_LOAD_FLAG_NO_RECURSE, and is      */
-  /*      used to report compound glyphs (like accented characters).       */
+  /*      format is _only_ used with @FT_LOAD_NO_RECURSE, and is used to   */
+  /*      report compound glyphs (like accented characters).               */
   /*                                                                       */
   /*    FT_GLYPH_FORMAT_BITMAP ::                                          */
   /*      The glyph image is a bitmap, and can be described as an          */
@@ -937,11 +935,11 @@
   /*************************************************************************/
   /*                                                                       */
   /* <Enum>                                                                */
-  /*    FT_Raster_Flag                                                     */
+  /*    FT_RASTER_FLAG_XXX                                                 */
   /*                                                                       */
   /* <Description>                                                         */
-  /*    An enumeration to list the bit flags as used in the `flags' field  */
-  /*    of a FT_Raster_Params structure.                                   */
+  /*    A list of bit flag constants as used in the `flags' field of a     */
+  /*    @FT_Raster_Params structure.                                       */
   /*                                                                       */
   /* <Values>                                                              */
   /*    FT_RASTER_FLAG_DEFAULT :: This value is 0.                         */
@@ -949,7 +947,7 @@
   /*    FT_RASTER_FLAG_AA      :: This flag is set to indicate that an     */
   /*                              anti-aliased glyph image should be       */
   /*                              generated.  Otherwise, it will be        */
-  /*                              monochrome (1-bit)                       */
+  /*                              monochrome (1-bit).                      */
   /*                                                                       */
   /*    FT_RASTER_FLAG_DIRECT  :: This flag is set to indicate direct      */
   /*                              rendering.  In this mode, client         */
@@ -974,15 +972,12 @@
   /*                              in direct rendering mode where all spans */
   /*                              are generated if no clipping box is set. */
   /*                                                                       */
-  typedef  enum
-  {
-    FT_RASTER_FLAG_DEFAULT = 0,
-    FT_RASTER_FLAG_AA      = 1,
-    FT_RASTER_FLAG_DIRECT  = 2,
-    FT_RASTER_FLAG_CLIP    = 4
-
-  } FT_Raster_Flag;
+#define FT_RASTER_FLAG_DEFAULT  0x0
+#define FT_RASTER_FLAG_AA       0x1
+#define FT_RASTER_FLAG_DIRECT   0x2
+#define FT_RASTER_FLAG_CLIP     0x4
 
+  /* deprecated */
 #define ft_raster_flag_default  FT_RASTER_FLAG_DEFAULT
 #define ft_raster_flag_aa       FT_RASTER_FLAG_AA
 #define ft_raster_flag_direct   FT_RASTER_FLAG_DIRECT

Index: ftincrem.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftincrem.h,v
retrieving revision 1.1
retrieving revision 1.1.4.1
diff -u -d -r1.1 -r1.1.4.1
--- a/ftincrem.h	25 Nov 2003 19:27:18 -0000	1.1
+++ b/ftincrem.h	23 Feb 2004 21:32:26 -0000	1.1.4.1
@@ -4,7 +4,7 @@
 /*                                                                         */
 /*    FreeType incremental loading (specification).                        */
 /*                                                                         */
-/*  Copyright 2002 by                                                      */
+/*  Copyright 2002, 2003 by                                                */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -22,6 +22,12 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
 
 FT_BEGIN_HEADER
 
@@ -186,10 +192,10 @@
   */
   typedef FT_Error
   (*FT_Incremental_GetGlyphMetricsFunc)
-                      ( FT_Incremental                   incremental,
-                        FT_UInt                          glyph_index,
-                        FT_Bool                          vertical,
-                        FT_Incremental_MetricsRec        *ametrics );
+                      ( FT_Incremental              incremental,
+                        FT_UInt                     glyph_index,
+                        FT_Bool                     vertical,
+                        FT_Incremental_MetricsRec  *ametrics );
 
 
   /**************************************************************************
@@ -199,7 +205,7 @@
    * 
    * @description:
    *   A table of functions for accessing fonts that load data
-   *   incrementally.  Used in @FT_Incremental_Interface.
+   *   incrementally.  Used in @FT_Incremental_InterfaceRec.
    * 
    * @fields:
    *   get_glyph_data ::
@@ -246,8 +252,7 @@
   *       parameter.data = &inc_int;
   *
   *       // set up FT_Open_Args structure
-  *       open_args.flags      = (FT_Open_Flags)( FT_OPEN_PATHNAME |
-  *                                               FT_OPEN_PARAMS   );
+  *       open_args.flags      = FT_OPEN_PATHNAME | FT_OPEN_PARAMS;
   *       open_args.pathname   = my_font_pathname;
   *       open_args.num_params = 1;
   *       open_args.params     = &parameter; // we use one optional argument

Index: ftlist.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftlist.h,v
retrieving revision 1.1
retrieving revision 1.1.4.1
diff -u -d -r1.1 -r1.1.4.1
--- a/ftlist.h	14 Nov 2003 16:48:24 -0000	1.1
+++ b/ftlist.h	23 Feb 2004 21:32:26 -0000	1.1.4.1
@@ -4,7 +4,7 @@
 /*                                                                         */
 /*    Generic list support for FreeType (specification).                   */
 /*                                                                         */
-/*  Copyright 1996-2001 by                                                 */
+/*  Copyright 1996-2001, 2003 by                                           */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -31,6 +31,12 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
 
 FT_BEGIN_HEADER
 

Index: ftmm.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftmm.h,v
retrieving revision 1.1
retrieving revision 1.1.4.1
diff -u -d -r1.1 -r1.1.4.1
--- a/ftmm.h	14 Nov 2003 16:48:24 -0000	1.1
+++ b/ftmm.h	23 Feb 2004 21:32:26 -0000	1.1.4.1
@@ -100,21 +100,6 @@
 
   /* */
 
-  typedef FT_Error
-  (*FT_Get_MM_Func)( FT_Face           face,
-                     FT_Multi_Master*  master );
-
-  typedef FT_Error
-  (*FT_Set_MM_Design_Func)( FT_Face   face,
-                            FT_UInt   num_coords,
-                            FT_Long*  coords );
-
-  typedef FT_Error
-  (*FT_Set_MM_Blend_Func)( FT_Face   face,
-                           FT_UInt   num_coords,
-                           FT_Long*  coords );
-
-
   /*************************************************************************/
   /*                                                                       */
   /* <Function>                                                            */

Index: ftmoderr.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftmoderr.h,v
retrieving revision 1.1
retrieving revision 1.1.4.1
diff -u -d -r1.1 -r1.1.4.1
--- a/ftmoderr.h	14 Nov 2003 16:48:24 -0000	1.1
+++ b/ftmoderr.h	23 Feb 2004 21:32:26 -0000	1.1.4.1
@@ -4,7 +4,7 @@
 /*                                                                         */
 /*    FreeType module error offsets (specification).                       */
 /*                                                                         */
-/*  Copyright 2001, 2002 by                                                */
+/*  Copyright 2001, 2002, 2003 by                                          */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -23,8 +23,8 @@
   /* The lower byte gives the error code, the higher byte gives the        */
   /* module.  The base module has error offset 0.  For example, the error  */
   /* `FT_Err_Invalid_File_Format' has value 0x003, the error               */
-  /* `TT_Err_Invalid_File_Format' has value 0xB03, the error               */
-  /* `T1_Err_Invalid_File_Format' has value 0xC03, etc.                    */
+  /* `TT_Err_Invalid_File_Format' has value 0xF03, the error               */
+  /* `T1_Err_Invalid_File_Format' has value 0x1003, etc.                   */
   /*                                                                       */
   /* Undefine the macro FT_CONFIG_OPTION_USE_MODULE_ERRORS in ftoption.h   */
   /* to make the higher byte always zero (disabling the module error       */
@@ -102,21 +102,25 @@
 #endif
 
 
-  FT_MODERRDEF( Base,     0x000, "base module" )
-  FT_MODERRDEF( Autohint, 0x100, "autohinter module" )
-  FT_MODERRDEF( Cache,    0x200, "cache module" )
-  FT_MODERRDEF( CFF,      0x300, "CFF module" )
-  FT_MODERRDEF( CID,      0x400, "CID module" )
-  FT_MODERRDEF( PCF,      0x500, "PCF module" )
-  FT_MODERRDEF( PSaux,    0x600, "PS auxiliary module" )
-  FT_MODERRDEF( PSnames,  0x700, "PS names module" )
-  FT_MODERRDEF( Raster,   0x800, "raster module" )
-  FT_MODERRDEF( SFNT,     0x900, "SFNT module" )
-  FT_MODERRDEF( Smooth,   0xA00, "smooth raster module" )
-  FT_MODERRDEF( TrueType, 0xB00, "TrueType module" )
-  FT_MODERRDEF( Type1,    0xC00, "Type 1 module" )
-  FT_MODERRDEF( Winfonts, 0xD00, "Windows FON/FNT module" )
-  FT_MODERRDEF( PFR,      0xE00, "PFR module" )
+  FT_MODERRDEF( Base,      0x000, "base module" )
+  FT_MODERRDEF( Autohint,  0x100, "autohinter module" )
+  FT_MODERRDEF( BDF,       0x200, "BDF module" )
+  FT_MODERRDEF( Cache,     0x300, "cache module" )
+  FT_MODERRDEF( CFF,       0x400, "CFF module" )
+  FT_MODERRDEF( CID,       0x500, "CID module" )
+  FT_MODERRDEF( Gzip,      0x600, "Gzip module" )
+  FT_MODERRDEF( PCF,       0x700, "PCF module" )
+  FT_MODERRDEF( PFR,       0x800, "PFR module" )
+  FT_MODERRDEF( PSaux,     0x900, "PS auxiliary module" )
+  FT_MODERRDEF( PShinter,  0xA00, "PS hinter module" )
+  FT_MODERRDEF( PSnames,   0xB00, "PS names module" )
+  FT_MODERRDEF( Raster,    0xC00, "raster module" )
+  FT_MODERRDEF( SFNT,      0xD00, "SFNT module" )
+  FT_MODERRDEF( Smooth,    0xE00, "smooth raster module" )
+  FT_MODERRDEF( TrueType,  0xF00, "TrueType module" )
+  FT_MODERRDEF( Type1,    0x1000, "Type 1 module" )
+  FT_MODERRDEF( Type42,   0x1100, "Type 42 module" )
+  FT_MODERRDEF( Winfonts, 0x1200, "Windows FON/FNT module" )
 
 
 #ifdef FT_MODERR_END_LIST

Index: ftoutln.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftoutln.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/ftoutln.h	26 Nov 2003 22:48:24 -0000	1.1.4.1
+++ b/ftoutln.h	23 Feb 2004 21:32:26 -0000	1.1.4.2
@@ -5,7 +5,7 @@
 /*    Support for the FT_Outline type used to store glyph shapes of        */
 /*    most scalable font formats (specification).                          */
 /*                                                                         */
-/*  Copyright 1996-2001, 2002 by                                           */
+/*  Copyright 1996-2001, 2002, 2003 by                                     */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -24,6 +24,12 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
 
 FT_BEGIN_HEADER
 
@@ -46,7 +52,7 @@
   /*                                                                       */
   /* <Order>                                                               */
   /*    FT_Outline                                                         */
-  /*    FT_Outline_Flags                                                   */
+  /*    FT_OUTLINE_FLAGS                                                   */
   /*    FT_Outline_New                                                     */
   /*    FT_Outline_Done                                                    */
   /*    FT_Outline_Copy                                                    */
@@ -389,6 +395,72 @@
                      FT_Raster_Params*  params );
 
 
+ /**************************************************************************
+  *
+  * @enum:
+  *   FT_Orientation
+  *  
+  * @description:
+  *   A list of values used to describe an outline's contour orientation.
+  *
+  *   The TrueType and Postscript specifications use different conventions
+  *   to determine whether outline contours should be filled or unfilled.
+  *   
+  * @values:
+  *   FT_ORIENTATION_TRUETYPE ::
+  *     According to the TrueType specification, clockwise contours must
+  *     be filled, and counter-clockwise ones must be unfilled.
+  *
+  *   FT_ORIENTATION_POSTSCRIPT ::
+  *     According to the Postscript specification, counter-clockwise contours
+  *     must be filled, and clockwise ones must be unfilled.
+  *
+  *   FT_ORIENTATION_FILL_RIGHT ::
+  *     This is identical to @FT_ORIENTATION_TRUETYPE, but is used to
+  *     remember that in TrueType, everything that is to the right of
+  *     the drawing direction of a contour must be filled.
+  *
+  *   FT_ORIENTATION_FILL_LEFT ::
+  *     This is identical to @FT_ORIENTATION_POSTSCRIPT, but is used to
+  *     remember that in Postscript, everything that is to the left of
+  *     the drawing direction of a contour must be filled.
+  */
+  typedef enum
+  {
+    FT_ORIENTATION_TRUETYPE   = 0,
+    FT_ORIENTATION_POSTSCRIPT = 1,
+    FT_ORIENTATION_FILL_RIGHT = FT_ORIENTATION_TRUETYPE,
+    FT_ORIENTATION_FILL_LEFT  = FT_ORIENTATION_POSTSCRIPT
+  
+  } FT_Orientation;
+
+
+ /**************************************************************************
+  *
+  * @function:
+  *   FT_Outline_Get_Orientation
+  *  
+  * @description:
+  *   This function analyzes a glyph outline and tries to compute its
+  *   fill orientation (see @FT_Orientation).  This is done by computing
+  *   the direction of each global horizontal and/or vertical extrema
+  *   within the outline.
+  *
+  *   Note that this will return @FT_ORIENTATION_TRUETYPE for empty
+  *   outlines.
+  *
+  * @input:
+  *   outline ::
+  *     A handle to the source outline.
+  *
+  * @return:
+  *   The orientation.
+  *
+  */
+  FT_EXPORT( FT_Orientation )
+  FT_Outline_Get_Orientation( FT_Outline*  outline );
+
+
   /* */
 
 

Index: ftpfr.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftpfr.h,v
retrieving revision 1.1
retrieving revision 1.1.4.1
diff -u -d -r1.1 -r1.1.4.1
--- a/ftpfr.h	25 Nov 2003 19:27:18 -0000	1.1
+++ b/ftpfr.h	23 Feb 2004 21:32:26 -0000	1.1.4.1
@@ -2,9 +2,9 @@
 /*                                                                         */
 /*  ftpfr.h                                                                */
 /*                                                                         */
-/*    FreeType API for accessing PFR-specific data                         */
+/*    FreeType API for accessing PFR-specific data (specification only).   */
 /*                                                                         */
-/*  Copyright 2002 by                                                      */
+/*  Copyright 2002, 2003 by                                                */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -22,6 +22,12 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
 
 FT_BEGIN_HEADER
 
@@ -49,42 +55,44 @@
   *    FT_Get_PFR_Metrics
   *
   * @description:
-  *    returns the outline and metrics resolutions of a given PFR
-  *    face.
+  *    Return the outline and metrics resolutions of a given PFR face.
   *
   * @input:
-  *    face :: handle to input face. It can be a non-PFR face.
+  *    face :: Handle to the input face.  It can be a non-PFR face.
   *
   * @output:
   *    aoutline_resolution ::
-  *      outline resolution. This is equivalent to "face->units_per_EM".
-  *      optional (parameter can be NULL)
+  *      Outline resolution.  This is equivalent to `face->units_per_EM'.
+  *      Optional (parameter can be NULL).
   *
   *    ametrics_resolution ::
-  *      metrics_resolution. This is equivalent to "outline_resolution"
-  *      for non-PFR fonts. can be NULL
-  *      optional (parameter can be NULL)
+  *      Metrics resolution.  This is equivalent to `outline_resolution'
+  *      for non-PFR fonts.  Optional (parameter can be NULL).
   *
   *    ametrics_x_scale ::
-  *      a 16.16 fixed-point number used to scale distance expressed
-  *      in metrics units to device sub-pixels. This is equivalent to
-  *      'face->size->x_scale', but for metrics only.
-  *      optional (parameter can be NULL)
+  *      A 16.16 fixed-point number used to scale distance expressed
+  *      in metrics units to device sub-pixels.  This is equivalent to
+  *      `face->size->x_scale', but for metrics only.  Optional (parameter
+  *      can be NULL)
   *
   *    ametrics_y_scale ::
-  *      same as 'ametrics_x_scale', but for the vertical direction.
+  *      Same as `ametrics_x_scale' but for the vertical direction.
   *      optional (parameter can be NULL)
   *
+  * @return:
+  *    FreeType error code.  0 means success.
+  *
   * @note:
-  *   if the input face is not a PFR, this function will return an error.
+  *   If the input face is not a PFR, this function will return an error.
   *   However, in all cases, it will return valid values.
   */
   FT_EXPORT( FT_Error )
-  FT_Get_PFR_Metrics( FT_Face     face,
-                      FT_UInt    *aoutline_resolution,
-                      FT_UInt    *ametrics_resolution,
-                      FT_Fixed   *ametrics_x_scale,
-                      FT_Fixed   *ametrics_y_scale );
+  FT_Get_PFR_Metrics( FT_Face    face,
+                      FT_UInt   *aoutline_resolution,
+                      FT_UInt   *ametrics_resolution,
+                      FT_Fixed  *ametrics_x_scale,
+                      FT_Fixed  *ametrics_y_scale );
+
 
  /**********************************************************************
   *
@@ -92,25 +100,30 @@
   *    FT_Get_PFR_Kerning
   *
   * @description:
-  *    returns the kerning pair corresponding to two glyphs in
-  *    a PFR face. The distance is expressed in metrics units, unlike
-  *    the result of @FT_Get_Kerning.
+  *    Return the kerning pair corresponding to two glyphs in a PFR face.
+  *    The distance is expressed in metrics units, unlike the result of
+  *    @FT_Get_Kerning.
   *
   * @input:
-  *    face :: handle to input face.
-  *    left  :: left glyph index
-  *    right :: right glyph index
+  *    face  :: A handle to the input face.
+  *
+  *    left  :: Index of the left glyph.
+  *
+  *    right :: Index of the right glyph.
   *
   * @output:
-  *    avector :: kerning vector
+  *    avector :: A kerning vector.
+  *
+  * @return:
+  *    FreeType error code.  0 means success.
   *
   * @note:
-  *    this function always return distances in original PFR metrics
-  *    units. This is unlike @FT_Get_Kerning with the @FT_KERNING_UNSCALED
-  *    mode, which always return distances converted to outline units.
+  *    This function always return distances in original PFR metrics
+  *    units.  This is unlike @FT_Get_Kerning with the @FT_KERNING_UNSCALED
+  *    mode, which always returns distances converted to outline units.
   *
-  *    you can use the value of the 'x_scale' and 'y_scale' parameters
-  *    returned by @FT_Get_PFR_Metrics to scale these to device sub-pixels
+  *    You can use the value of the `x_scale' and `y_scale' parameters
+  *    returned by @FT_Get_PFR_Metrics to scale these to device sub-pixels.
   */
   FT_EXPORT( FT_Error )
   FT_Get_PFR_Kerning( FT_Face     face,
@@ -118,36 +131,39 @@
                       FT_UInt     right,
                       FT_Vector  *avector );
 
+
  /**********************************************************************
   *
   * @function:
   *    FT_Get_PFR_Advance
   *
   * @description:
-  *    returns a given glyph advance, expressed in original metrics units,
+  *    Return a given glyph advance, expressed in original metrics units,
   *    from a PFR font.
   *
   * @input:
-  *    face   :: handle to input face.
-  *    gindex :: glyph index
+  *    face   :: A handle to the input face.
+  *
+  *    gindex :: The glyph index.
   *
   * @output:
-  *    aadvance :: glyph advance in metrics units
+  *    aadvance :: The glyph advance in metrics units.
   *
   * @return:
-  *    error code. 0 means success
+  *    FreeType error code.  0 means success.
   *
   * @note:
-  *    you can use the 'x_scale' or 'y_scale' results of @FT_Get_PFR_Metrics
-  *    to convert the advance to device sub-pixels (i.e. 1/64th of pixels)
+  *    You can use the `x_scale' or `y_scale' results of @FT_Get_PFR_Metrics
+  *    to convert the advance to device sub-pixels (i.e. 1/64th of pixels).
   */
   FT_EXPORT( FT_Error )
-  FT_Get_PFR_Advance( FT_Face    face,
-                      FT_UInt    gindex,
-                      FT_Pos    *aadvance );
+  FT_Get_PFR_Advance( FT_Face   face,
+                      FT_UInt   gindex,
+                      FT_Pos   *aadvance );
 
  /* */
 
+
 FT_END_HEADER
 
 #endif /* __FTBDF_H__ */

Index: ftsizes.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftsizes.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/ftsizes.h	26 Nov 2003 22:48:24 -0000	1.1.4.1
+++ b/ftsizes.h	23 Feb 2004 21:32:26 -0000	1.1.4.2
@@ -4,7 +4,7 @@
 /*                                                                         */
 /*    FreeType size objects management (specification).                    */
 /*                                                                         */
-/*  Copyright 1996-2001 by                                                 */
+/*  Copyright 1996-2001, 2003 by                                           */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -32,6 +32,12 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
 
 FT_BEGIN_HEADER
 
@@ -101,7 +107,9 @@
   /*    FT_Done_Size                                                       */
   /*                                                                       */
   /* <Description>                                                         */
-  /*    Discards a given size object.                                      */
+  /*    Discards a given size object.  Note that @FT_Done_Face             */
+  /*    automatically discards all size objects allocated with             */
+  /*    @FT_New_Size.                                                      */
   /*                                                                       */
   /* <Input>                                                               */
   /*    size :: A handle to a target size object.                          */

Index: ftsnames.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftsnames.h,v
retrieving revision 1.1
retrieving revision 1.1.4.1
diff -u -d -r1.1 -r1.1.4.1
--- a/ftsnames.h	14 Nov 2003 16:48:24 -0000	1.1
+++ b/ftsnames.h	23 Feb 2004 21:32:26 -0000	1.1.4.1
@@ -7,7 +7,7 @@
 /*                                                                         */
 /*    This is _not_ used to retrieve glyph names!                          */
 /*                                                                         */
-/*  Copyright 1996-2001, 2002 by                                           */
+/*  Copyright 1996-2001, 2002, 2003 by                                     */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -26,6 +26,12 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
 
 FT_BEGIN_HEADER
 

Index: ftsynth.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftsynth.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/ftsynth.h	26 Nov 2003 22:48:24 -0000	1.1.4.1
+++ b/ftsynth.h	23 Feb 2004 21:32:26 -0000	1.1.4.2
@@ -5,7 +5,7 @@
 /*    FreeType synthesizing code for emboldening and slanting              */
 /*    (specification).                                                     */
 /*                                                                         */
-/*  Copyright 2000-2001 by                                                 */
+/*  Copyright 2000-2001, 2003 by                                           */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -41,6 +41,12 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
 
 FT_BEGIN_HEADER
 

Index: fttrigon.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/fttrigon.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/fttrigon.h	26 Nov 2003 22:48:24 -0000	1.1.4.1
+++ b/fttrigon.h	23 Feb 2004 21:32:26 -0000	1.1.4.2
@@ -4,7 +4,7 @@
 /*                                                                         */
 /*    FreeType trigonometric functions (specification).                    */
 /*                                                                         */
-/*  Copyright 2001 by                                                      */
+/*  Copyright 2001, 2003 by                                                */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -21,6 +21,12 @@
 
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
 
 FT_BEGIN_HEADER
 
@@ -260,22 +266,6 @@
   /*************************************************************************/
   /*                                                                       */
   /* @function:                                                            */
-  /*    FT_Vector_Normalize                                                */
-  /*                                                                       */
-  /* @description:                                                         */
-  /*    Normalize a given vector (i.e. compute the equivalent unit         */
-  /*    vector).                                                           */
-  /*                                                                       */
-  /* @inout:                                                               */
-  /*    vec :: The address of target vector.                               */
-  /*                                                                       */
-  FT_EXPORT( void )
-  FT_Vector_Normalize( FT_Vector*  vec );
-
-
-  /*************************************************************************/
-  /*                                                                       */
-  /* @function:                                                            */
   /*    FT_Vector_Polarize                                                 */
   /*                                                                       */
   /* @description:                                                         */

Index: ftwinfnt.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftwinfnt.h,v
retrieving revision 1.1
retrieving revision 1.1.4.1
diff -u -d -r1.1 -r1.1.4.1
--- a/ftwinfnt.h	25 Nov 2003 19:27:18 -0000	1.1
+++ b/ftwinfnt.h	23 Feb 2004 21:32:26 -0000	1.1.4.1
@@ -4,7 +4,7 @@
 /*                                                                         */
 /*    FreeType API for accessing Windows fnt-specific data.                */
 /*                                                                         */
-/*  Copyright 2002 by                                                      */
+/*  Copyright 2003 by                                                      */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -22,6 +22,12 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
 
 FT_BEGIN_HEADER
 
@@ -93,31 +99,31 @@
   } FT_WinFNT_HeaderRec, *FT_WinFNT_Header;
 
 
-
  /**********************************************************************
   *
   * @function:
   *    FT_Get_WinFNT_Header
   *
   * @description:
-  *    Retrieves a Windows FNT font info header.
+  *    Retrieve a Windows FNT font info header.
   *
   * @input:
-  *    face   :: handle to input face
+  *    face    :: A handle to the input face.
   *
   * @output:
-  *    header :: WinFNT header.
+  *    aheader :: The WinFNT header.
   *
   * @return:
   *   FreeType error code.  0 means success.
   *
   * @note:
-  *   This function only works with Windows FNT faces, returning an erro
+  *   This function only works with Windows FNT faces, returning an error
   *   otherwise.
   */
   FT_EXPORT( FT_Error )
-  FT_Get_WinFNT_Header( FT_Face              face,
-                        FT_WinFNT_HeaderRec *header );
+  FT_Get_WinFNT_Header( FT_Face               face,
+                        FT_WinFNT_HeaderRec  *aheader );
+
 
  /* */
 

Index: ftxf86.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ftxf86.h,v
retrieving revision 1.1
retrieving revision 1.1.4.1
diff -u -d -r1.1 -r1.1.4.1
--- a/ftxf86.h	14 Nov 2003 16:48:24 -0000	1.1
+++ b/ftxf86.h	23 Feb 2004 21:32:26 -0000	1.1.4.1
@@ -4,7 +4,7 @@
 /*                                                                         */
 /*    Support functions for X11.                                           */
 /*                                                                         */
-/*  Copyright 2002 by                                                      */
+/*  Copyright 2002, 2003 by                                                */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -22,6 +22,13 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
+
 FT_BEGIN_HEADER
 
   /* this comment is intentionally disabled for now, to prevent this       */

Index: t1tables.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/t1tables.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/t1tables.h	26 Nov 2003 22:48:24 -0000	1.1.4.1
+++ b/t1tables.h	23 Feb 2004 21:32:26 -0000	1.1.4.2
@@ -5,7 +5,7 @@
 /*    Basic Type 1/Type 2 tables definitions and interface (specification  */
 /*    only).                                                               */
 /*                                                                         */
-/*  Copyright 1996-2001, 2002 by                                           */
+/*  Copyright 1996-2001, 2002, 2003 by                                     */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -24,6 +24,12 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
 
 FT_BEGIN_HEADER
 
@@ -314,7 +320,7 @@
   /*    CID_Info                                                           */
   /*                                                                       */
   /* <Description>                                                         */
-  /*   This type is equivalent to @CID_FaceInfoRec. It is deprecated but   */
+  /*   This type is equivalent to CID_FaceInfoRec.  It is deprecated but   */
   /*   kept to maintain source compatibility between various versions of   */
   /*   FreeType.                                                           */
   /*                                                                       */
@@ -373,7 +379,7 @@
   *    the face and don't need to be freed by the caller.
   *
   *    If the font's format is not Postscript-based, this function will
-  *    return the @FT_Err_Invalid_Argument error code.
+  *    return the FT_Err_Invalid_Argument error code.
   */
   FT_EXPORT( FT_Error )
   FT_Get_PS_Font_Info( FT_Face          face,

Index: ttnameid.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/ttnameid.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/ttnameid.h	26 Nov 2003 22:48:24 -0000	1.1.4.1
+++ b/ttnameid.h	23 Feb 2004 21:32:26 -0000	1.1.4.2
@@ -4,7 +4,7 @@
 /*                                                                         */
 /*    TrueType name ID definitions (specification only).                   */
 /*                                                                         */
-/*  Copyright 1996-2002 by                                                 */
+/*  Copyright 1996-2002, 2003 by                                           */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -41,7 +41,7 @@
    *
    * @description:
    *   A list of valid values for the `platform_id' identifier code in
-   *   @FT_CharmapRec and @FT_SfntName structures.
+   *   @FT_CharMapRec and @FT_SfntName structures.
    *
    * @values:
    *   TT_PLATFORM_APPLE_UNICODE ::
@@ -231,34 +231,33 @@
    *
    * @values:
    *   TT_MS_ID_SYMBOL_CS ::
-   *     Corresponds to symbol encodings. see @FT_ENCODING_MS_SYMBOL.
+   *     Corresponds to Microsoft symbol encoding. See
+   *     @FT_ENCODING_MS_SYMBOL.
    *
    *   TT_MS_ID_UNICODE_CS ::
    *     Corresponds to a Microsoft WGL4 charmap, matching Unicode.  See
    *     @FT_ENCODING_UNICODE.
    *
    *   TT_MS_ID_SJIS ::
-   *     Corresponds to Microsoft SJIS Japanese encoding.
-   *     See @FT_ENCODING_MS_SJIS.
+   *     Corresponds to SJIS Japanese encoding.  See @FT_ENCODING_SJIS.
    *
    *   TT_MS_ID_GB2312 ::
-   *     Corresponds to Microsoft Simplified Chinese as used in Mainland
-   *     China.  See @FT_ENCODING_MS_GB2312.
+   *     Corresponds to Simplified Chinese as used in Mainland China.  See
+   *     @FT_ENCODING_GB2312.
    *
    *   TT_MS_ID_BIG_5 ::
-   *     Corresponds to Microsoft Traditional Chinese as used in Taiwan and
-   *     Hong Kong.  See @FT_ENCODING_MS_BIG5.
+   *     Corresponds to Traditional Chinese as used in Taiwan and Hong Kong.
+   *     See @FT_ENCODING_BIG5.
    *
    *   TT_MS_ID_WANSUNG ::
-   *     Corresponds to Microsoft Korean Wansung encoding.  See
-   *     @FT_ENCODING_MS_WANSUNG.
+   *     Corresponds to Korean Wansung encoding.  See @FT_ENCODING_WANSUNG.
    *
    *   TT_MS_ID_JOHAB ::
-   *     Corresponds to Microsoft Johab encoding.  See @FT_ENCODING_MS_JOHAB.
+   *     Corresponds to Johab encoding.  See @FT_ENCODING_JOHAB.
    *
    *   TT_MS_ID_UCS_4 ::
-   *     Corresponds to UCS-4 or UTF-32 charmaps.  This has been added into
-   *     OpenType specification as of version 1.4 (mid-2001.)
+   *     Corresponds to UCS-4 or UTF-32 charmaps.  This has been added to
+   *     the OpenType specification version 1.4 (mid-2001.)
    */
 
 #define TT_MS_ID_SYMBOL_CS    0
@@ -705,8 +704,8 @@
 #define TT_MS_LANGID_SPANISH_UNITED_STATES             0x540a
   /* The following two IDs blatantly violate MS specs by using a */
   /* sublanguage > 0x1F.                                         */
-#define TT_MS_LANGID_SPANISH_LATIN_AMERICA             0xE40a
-#define TT_MS_LANGID_FRENCH_NORTH_AFRICA               0xE40c
+#define TT_MS_LANGID_SPANISH_LATIN_AMERICA             0xE40aU
+#define TT_MS_LANGID_FRENCH_NORTH_AFRICA               0xE40cU
 
 #define TT_MS_LANGID_FRENCH_MOROCCO                    0x380c
 #define TT_MS_LANGID_FRENCH_HAITI                      0x3c0c

Index: tttables.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/tttables.h,v
retrieving revision 1.1.4.1
retrieving revision 1.1.4.2
diff -u -d -r1.1.4.1 -r1.1.4.2
--- a/tttables.h	26 Nov 2003 22:48:24 -0000	1.1.4.1
+++ b/tttables.h	23 Feb 2004 21:32:26 -0000	1.1.4.2
@@ -5,7 +5,7 @@
 /*    Basic SFNT/TrueType tables definitions and interface                 */
 /*    (specification only).                                                */
 /*                                                                         */
-/*  Copyright 1996-2001 by                                                 */
+/*  Copyright 1996-2001, 2002, 2003 by                                     */
 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
 /*                                                                         */
 /*  This file is part of the FreeType project, and may only be used,       */
@@ -24,6 +24,12 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
 
 FT_BEGIN_HEADER
 
@@ -541,8 +547,15 @@
   } TT_MaxProfile;
 
 
-  /* */
-
+  /*************************************************************************/
+  /*                                                                       */
+  /* <Enum>                                                                */
+  /*    FT_Sfnt_Tag                                                        */
+  /*                                                                       */
+  /* <Description>                                                         */
+  /*    An enumeration used to specify the index of an SFNT table.         */
+  /*    Used in the @FT_Get_Sfnt_Table API function.                       */
+  /*                                                                       */
   typedef enum
   {
     ft_sfnt_head = 0,
@@ -553,15 +566,11 @@
     ft_sfnt_post = 5,
     ft_sfnt_pclt = 6,
 
-    sfnt_max   /* don't remove */
+    sfnt_max   /* internal end mark */
 
   } FT_Sfnt_Tag;
 
-
-  /* internal use only */
-  typedef void*
-  (*FT_Get_Sfnt_Table_Func)( FT_Face      face,
-                             FT_Sfnt_Tag  tag );
+  /* */
 
 
   /*************************************************************************/
@@ -586,13 +595,14 @@
   /*    The table is owned by the face object and disappears with it.      */
   /*                                                                       */
   /*    This function is only useful to access SFNT tables that are loaded */
-  /*    by the sfnt/truetype/opentype drivers.  See FT_Sfnt_Tag for a      */
+  /*    by the sfnt/truetype/opentype drivers.  See @FT_Sfnt_Tag for a     */
   /*    list.                                                              */
   /*                                                                       */
   FT_EXPORT( void* )
   FT_Get_Sfnt_Table( FT_Face      face,
                      FT_Sfnt_Tag  tag );
 
+
  /**************************************************************************
   *
   * <Function>
@@ -602,54 +612,56 @@
   *   Loads any font table into client memory.
   *
   * <Input>
-  *   face   :: handle to source face.
-  *   tag    :: the 4-byte tag of the table to load. Use the value 0 if
-  *             you want to access the whole font file. Else, you can use
-  *             one of the definitions found in the @FT_TRUETYPE_TAGS_H
-  *             file, or forge a new one with @FT_MAKE_TAG
+  *   face   :: A handle to the source face.
+  *
+  *   tag    :: The 4-byte tag of the table to load.  Use the value 0 if
+  *             you want to access the whole font file.  Otherwise, you can
+  *             use one of the definitions found in the @FT_TRUETYPE_TAGS_H
+  *             file, or forge a new one with @FT_MAKE_TAG.
   *              
-  *   offset :: the starting offset in the table (or file if tag == 0)
+  *   offset :: The starting offset in the table (or file if tag == 0).
   *
   * <Output>
-  *   buffer :: target buffer address. client must ensure that there are
-  *             enough bytes in it.
+  *   buffer :: The target buffer address.  The client must ensure that
+  *             the memory array is big enough to hold the data.
   *
   * <InOut>
-  *   length :: if the 'length' parameter is NULL, then try to load the whole
-  *             table, and return an error code if it fails.
+  *   length :: If the `length' parameter is NULL, then try to load the whole
+  *             table.  Return an error code if it fails.
   *
-  *             else, if '*length' is 0, then exit immediately while returning
+  *             Else, if `*length' is 0, exit immediately while returning
   *             the table's (or file) full size in it.
   *
-  *             else, the number of bytes to read from the table or file,
+  *             Else the number of bytes to read from the table or file,
   *             from the starting offset.
   *
   * <Return>
-  *   error code. 0 means success
+  *   FreeType error code.  0 means success.
   *
   * <Note>
-  *   if you need to determine the table's length you should first call this
-  *   function with "*length" set to 0, as in the following example:
+  *   If you need to determine the table's length you should first call this
+  *   function with `*length' set to 0, as in the following example:
   *
   *   {
   *     FT_ULong  length = 0;
   *
+  *
   *     error = FT_Load_Sfnt_Table( face, tag, 0, NULL, &length );
   *     if ( error ) { ... table does not exist ... }
   *
   *     buffer = malloc( length );
-  *     if ( buffer == NULL )  { ... not enough memory ... }
+  *     if ( buffer == NULL ) { ... not enough memory ... }
   *
   *     error = FT_Load_Sfnt_Table( face,tag, 0, buffer, &length );
   *     if ( error ) { ... could not load table ... }
   *   }
   */
   FT_EXPORT( FT_Error )
-  FT_Load_Sfnt_Table( FT_Face      face,
-                      FT_ULong     tag,
-                      FT_Long      offset,
-                      FT_Byte*     buffer,
-                      FT_ULong*    length );
+  FT_Load_Sfnt_Table( FT_Face    face,
+                      FT_ULong   tag,
+                      FT_Long    offset,
+                      FT_Byte*   buffer,
+                      FT_ULong*  length );
 
   /* */
 

Index: tttags.h
===================================================================
RCS file: /cvs/xorg/xc/extras/freetype2/include/freetype/tttags.h,v
retrieving revision 1.1
retrieving revision 1.1.4.1
diff -u -d -r1.1 -r1.1.4.1
--- a/tttags.h	14 Nov 2003 16:48:24 -0000	1.1
+++ b/tttags.h	23 Feb 2004 21:32:26 -0000	1.1.4.1
@@ -23,6 +23,12 @@
 #include <ft2build.h>
 #include FT_FREETYPE_H
 
+#ifdef FREETYPE_H
+#error "freetype.h of FreeType 1 has been loaded!"
+#error "Please fix the directory search order for header files"
+#error "so that freetype.h of FreeType 2 is found first."
+#endif
+
 
 FT_BEGIN_HEADER
 





More information about the xorg-commit mailing list