src/java.desktop/share/native/libfreetype/include/freetype/ttnameid.h
changeset 54876 da3834261f0c
parent 49234 3375a8039fde
equal deleted inserted replaced
54875:bcfedddcf4ce 54876:da3834261f0c
     1 /***************************************************************************/
     1 /****************************************************************************
     2 /*                                                                         */
     2  *
     3 /*  ttnameid.h                                                             */
     3  * ttnameid.h
     4 /*                                                                         */
     4  *
     5 /*    TrueType name ID definitions (specification only).                   */
     5  *   TrueType name ID definitions (specification only).
     6 /*                                                                         */
     6  *
     7 /*  Copyright 1996-2018 by                                                 */
     7  * Copyright (C) 1996-2019 by
     8 /*  David Turner, Robert Wilhelm, and Werner Lemberg.                      */
     8  * David Turner, Robert Wilhelm, and Werner Lemberg.
     9 /*                                                                         */
     9  *
    10 /*  This file is part of the FreeType project, and may only be used,       */
    10  * This file is part of the FreeType project, and may only be used,
    11 /*  modified, and distributed under the terms of the FreeType project      */
    11  * modified, and distributed under the terms of the FreeType project
    12 /*  license, LICENSE.TXT.  By continuing to use, modify, or distribute     */
    12  * license, LICENSE.TXT.  By continuing to use, modify, or distribute
    13 /*  this file you indicate that you have read the license and              */
    13  * this file you indicate that you have read the license and
    14 /*  understand and accept it fully.                                        */
    14  * understand and accept it fully.
    15 /*                                                                         */
    15  *
    16 /***************************************************************************/
    16  */
    17 
    17 
    18 
    18 
    19 #ifndef TTNAMEID_H_
    19 #ifndef TTNAMEID_H_
    20 #define TTNAMEID_H_
    20 #define TTNAMEID_H_
    21 
    21 
    24 
    24 
    25 
    25 
    26 FT_BEGIN_HEADER
    26 FT_BEGIN_HEADER
    27 
    27 
    28 
    28 
    29   /*************************************************************************/
    29   /**************************************************************************
    30   /*                                                                       */
    30    *
    31   /* <Section>                                                             */
    31    * @section:
    32   /*    truetype_tables                                                    */
    32    *   truetype_tables
    33   /*                                                                       */
    33    */
    34 
    34 
    35 
    35 
    36   /*************************************************************************/
    36   /**************************************************************************
    37   /*                                                                       */
    37    *
    38   /* Possible values for the `platform' identifier code in the name        */
    38    * Possible values for the 'platform' identifier code in the name records
    39   /* records of an SFNT `name' table.                                      */
    39    * of an SFNT 'name' table.
    40   /*                                                                       */
    40    *
    41   /*************************************************************************/
    41    */
    42 
    42 
    43 
    43 
    44   /***********************************************************************
    44   /**************************************************************************
    45    *
    45    *
    46    * @enum:
    46    * @enum:
    47    *   TT_PLATFORM_XXX
    47    *   TT_PLATFORM_XXX
    48    *
    48    *
    49    * @description:
    49    * @description:
    50    *   A list of valid values for the `platform_id' identifier code in
    50    *   A list of valid values for the `platform_id` identifier code in
    51    *   @FT_CharMapRec and @FT_SfntName structures.
    51    *   @FT_CharMapRec and @FT_SfntName structures.
    52    *
    52    *
    53    * @values:
    53    * @values:
    54    *   TT_PLATFORM_APPLE_UNICODE ::
    54    *   TT_PLATFORM_APPLE_UNICODE ::
    55    *     Used by Apple to indicate a Unicode character map and/or name entry.
    55    *     Used by Apple to indicate a Unicode character map and/or name entry.
    56    *     See @TT_APPLE_ID_XXX for corresponding `encoding_id' values.  Note
    56    *     See @TT_APPLE_ID_XXX for corresponding `encoding_id` values.  Note
    57    *     that name entries in this format are coded as big-endian UCS-2
    57    *     that name entries in this format are coded as big-endian UCS-2
    58    *     character codes _only_.
    58    *     character codes _only_.
    59    *
    59    *
    60    *   TT_PLATFORM_MACINTOSH ::
    60    *   TT_PLATFORM_MACINTOSH ::
    61    *     Used by Apple to indicate a MacOS-specific charmap and/or name entry.
    61    *     Used by Apple to indicate a MacOS-specific charmap and/or name
    62    *     See @TT_MAC_ID_XXX for corresponding `encoding_id' values.  Note that
    62    *     entry.  See @TT_MAC_ID_XXX for corresponding `encoding_id` values.
    63    *     most TrueType fonts contain an Apple roman charmap to be usable on
    63    *     Note that most TrueType fonts contain an Apple roman charmap to be
    64    *     MacOS systems (even if they contain a Microsoft charmap as well).
    64    *     usable on MacOS systems (even if they contain a Microsoft charmap as
       
    65    *     well).
    65    *
    66    *
    66    *   TT_PLATFORM_ISO ::
    67    *   TT_PLATFORM_ISO ::
    67    *     This value was used to specify ISO/IEC 10646 charmaps.  It is however
    68    *     This value was used to specify ISO/IEC 10646 charmaps.  It is
    68    *     now deprecated.  See @TT_ISO_ID_XXX for a list of corresponding
    69    *     however now deprecated.  See @TT_ISO_ID_XXX for a list of
    69    *     `encoding_id' values.
    70    *     corresponding `encoding_id` values.
    70    *
    71    *
    71    *   TT_PLATFORM_MICROSOFT ::
    72    *   TT_PLATFORM_MICROSOFT ::
    72    *     Used by Microsoft to indicate Windows-specific charmaps.  See
    73    *     Used by Microsoft to indicate Windows-specific charmaps.  See
    73    *     @TT_MS_ID_XXX for a list of corresponding `encoding_id' values.
    74    *     @TT_MS_ID_XXX for a list of corresponding `encoding_id` values.
    74    *     Note that most fonts contain a Unicode charmap using
    75    *     Note that most fonts contain a Unicode charmap using
    75    *     (TT_PLATFORM_MICROSOFT, @TT_MS_ID_UNICODE_CS).
    76    *     (`TT_PLATFORM_MICROSOFT`, @TT_MS_ID_UNICODE_CS).
    76    *
    77    *
    77    *   TT_PLATFORM_CUSTOM ::
    78    *   TT_PLATFORM_CUSTOM ::
    78    *     Used to indicate application-specific charmaps.
    79    *     Used to indicate application-specific charmaps.
    79    *
    80    *
    80    *   TT_PLATFORM_ADOBE ::
    81    *   TT_PLATFORM_ADOBE ::
    89 #define TT_PLATFORM_MICROSOFT      3
    90 #define TT_PLATFORM_MICROSOFT      3
    90 #define TT_PLATFORM_CUSTOM         4
    91 #define TT_PLATFORM_CUSTOM         4
    91 #define TT_PLATFORM_ADOBE          7 /* artificial */
    92 #define TT_PLATFORM_ADOBE          7 /* artificial */
    92 
    93 
    93 
    94 
    94   /***********************************************************************
    95   /**************************************************************************
    95    *
    96    *
    96    * @enum:
    97    * @enum:
    97    *   TT_APPLE_ID_XXX
    98    *   TT_APPLE_ID_XXX
    98    *
    99    *
    99    * @description:
   100    * @description:
   100    *   A list of valid values for the `encoding_id' for
   101    *   A list of valid values for the `encoding_id` for
   101    *   @TT_PLATFORM_APPLE_UNICODE charmaps and name entries.
   102    *   @TT_PLATFORM_APPLE_UNICODE charmaps and name entries.
   102    *
   103    *
   103    * @values:
   104    * @values:
   104    *   TT_APPLE_ID_DEFAULT ::
   105    *   TT_APPLE_ID_DEFAULT ::
   105    *     Unicode version 1.0.
   106    *     Unicode version 1.0.
   115    *
   116    *
   116    *   TT_APPLE_ID_UNICODE_32 ::
   117    *   TT_APPLE_ID_UNICODE_32 ::
   117    *     Unicode 3.1 and beyond, using UTF-32.
   118    *     Unicode 3.1 and beyond, using UTF-32.
   118    *
   119    *
   119    *   TT_APPLE_ID_VARIANT_SELECTOR ::
   120    *   TT_APPLE_ID_VARIANT_SELECTOR ::
   120    *     From Adobe, not Apple.  Not a normal cmap.  Specifies variations
   121    *     From Adobe, not Apple.  Not a normal cmap.  Specifies variations on
   121    *     on a real cmap.
   122    *     a real cmap.
   122    *
   123    *
   123    *   TT_APPLE_ID_FULL_UNICODE ::
   124    *   TT_APPLE_ID_FULL_UNICODE ::
   124    *     Used for fallback fonts that provide complete Unicode coverage with
   125    *     Used for fallback fonts that provide complete Unicode coverage with
   125    *     a type~13 cmap.
   126    *     a type~13 cmap.
   126    */
   127    */
   132 #define TT_APPLE_ID_UNICODE_32        4 /* 2.0 or later, full repertoire */
   133 #define TT_APPLE_ID_UNICODE_32        4 /* 2.0 or later, full repertoire */
   133 #define TT_APPLE_ID_VARIANT_SELECTOR  5 /* variation selector data       */
   134 #define TT_APPLE_ID_VARIANT_SELECTOR  5 /* variation selector data       */
   134 #define TT_APPLE_ID_FULL_UNICODE      6 /* used with type 13 cmaps       */
   135 #define TT_APPLE_ID_FULL_UNICODE      6 /* used with type 13 cmaps       */
   135 
   136 
   136 
   137 
   137   /***********************************************************************
   138   /**************************************************************************
   138    *
   139    *
   139    * @enum:
   140    * @enum:
   140    *   TT_MAC_ID_XXX
   141    *   TT_MAC_ID_XXX
   141    *
   142    *
   142    * @description:
   143    * @description:
   143    *   A list of valid values for the `encoding_id' for
   144    *   A list of valid values for the `encoding_id` for
   144    *   @TT_PLATFORM_MACINTOSH charmaps and name entries.
   145    *   @TT_PLATFORM_MACINTOSH charmaps and name entries.
   145    */
   146    */
   146 
   147 
   147 #define TT_MAC_ID_ROMAN                 0
   148 #define TT_MAC_ID_ROMAN                 0
   148 #define TT_MAC_ID_JAPANESE              1
   149 #define TT_MAC_ID_JAPANESE              1
   178 #define TT_MAC_ID_VIETNAMESE           30
   179 #define TT_MAC_ID_VIETNAMESE           30
   179 #define TT_MAC_ID_SINDHI               31
   180 #define TT_MAC_ID_SINDHI               31
   180 #define TT_MAC_ID_UNINTERP             32
   181 #define TT_MAC_ID_UNINTERP             32
   181 
   182 
   182 
   183 
   183   /***********************************************************************
   184   /**************************************************************************
   184    *
   185    *
   185    * @enum:
   186    * @enum:
   186    *   TT_ISO_ID_XXX
   187    *   TT_ISO_ID_XXX
   187    *
   188    *
   188    * @description:
   189    * @description:
   189    *   A list of valid values for the `encoding_id' for
   190    *   A list of valid values for the `encoding_id` for @TT_PLATFORM_ISO
   190    *   @TT_PLATFORM_ISO charmaps and name entries.
   191    *   charmaps and name entries.
   191    *
   192    *
   192    *   Their use is now deprecated.
   193    *   Their use is now deprecated.
   193    *
   194    *
   194    * @values:
   195    * @values:
   195    *   TT_ISO_ID_7BIT_ASCII ::
   196    *   TT_ISO_ID_7BIT_ASCII ::
   203 #define TT_ISO_ID_7BIT_ASCII  0
   204 #define TT_ISO_ID_7BIT_ASCII  0
   204 #define TT_ISO_ID_10646       1
   205 #define TT_ISO_ID_10646       1
   205 #define TT_ISO_ID_8859_1      2
   206 #define TT_ISO_ID_8859_1      2
   206 
   207 
   207 
   208 
   208   /***********************************************************************
   209   /**************************************************************************
   209    *
   210    *
   210    * @enum:
   211    * @enum:
   211    *   TT_MS_ID_XXX
   212    *   TT_MS_ID_XXX
   212    *
   213    *
   213    * @description:
   214    * @description:
   214    *   A list of valid values for the `encoding_id' for
   215    *   A list of valid values for the `encoding_id` for
   215    *   @TT_PLATFORM_MICROSOFT charmaps and name entries.
   216    *   @TT_PLATFORM_MICROSOFT charmaps and name entries.
   216    *
   217    *
   217    * @values:
   218    * @values:
   218    *   TT_MS_ID_SYMBOL_CS ::
   219    *   TT_MS_ID_SYMBOL_CS ::
   219    *     Microsoft symbol encoding.  See @FT_ENCODING_MS_SYMBOL.
   220    *     Microsoft symbol encoding.  See @FT_ENCODING_MS_SYMBOL.
   220    *
   221    *
   221    *   TT_MS_ID_UNICODE_CS ::
   222    *   TT_MS_ID_UNICODE_CS ::
   222    *     Microsoft WGL4 charmap, matching Unicode.  See
   223    *     Microsoft WGL4 charmap, matching Unicode.  See @FT_ENCODING_UNICODE.
   223    *     @FT_ENCODING_UNICODE.
       
   224    *
   224    *
   225    *   TT_MS_ID_SJIS ::
   225    *   TT_MS_ID_SJIS ::
   226    *     Shift JIS Japanese encoding.  See @FT_ENCODING_SJIS.
   226    *     Shift JIS Japanese encoding.  See @FT_ENCODING_SJIS.
   227    *
   227    *
   228    *   TT_MS_ID_PRC ::
   228    *   TT_MS_ID_PRC ::
   229    *     Chinese encodings as used in the People's Republic of China (PRC).
   229    *     Chinese encodings as used in the People's Republic of China (PRC).
   230    *     This means the encodings GB~2312 and its supersets GBK and
   230    *     This means the encodings GB~2312 and its supersets GBK and GB~18030.
   231    *     GB~18030.  See @FT_ENCODING_PRC.
   231    *     See @FT_ENCODING_PRC.
   232    *
   232    *
   233    *   TT_MS_ID_BIG_5 ::
   233    *   TT_MS_ID_BIG_5 ::
   234    *     Traditional Chinese as used in Taiwan and Hong Kong.  See
   234    *     Traditional Chinese as used in Taiwan and Hong Kong.  See
   235    *     @FT_ENCODING_BIG5.
   235    *     @FT_ENCODING_BIG5.
   236    *
   236    *
   256 
   256 
   257   /* this value is deprecated */
   257   /* this value is deprecated */
   258 #define TT_MS_ID_GB2312  TT_MS_ID_PRC
   258 #define TT_MS_ID_GB2312  TT_MS_ID_PRC
   259 
   259 
   260 
   260 
   261   /***********************************************************************
   261   /**************************************************************************
   262    *
   262    *
   263    * @enum:
   263    * @enum:
   264    *   TT_ADOBE_ID_XXX
   264    *   TT_ADOBE_ID_XXX
   265    *
   265    *
   266    * @description:
   266    * @description:
   267    *   A list of valid values for the `encoding_id' for
   267    *   A list of valid values for the `encoding_id` for @TT_PLATFORM_ADOBE
   268    *   @TT_PLATFORM_ADOBE charmaps.  This is a FreeType-specific extension!
   268    *   charmaps.  This is a FreeType-specific extension!
   269    *
   269    *
   270    * @values:
   270    * @values:
   271    *   TT_ADOBE_ID_STANDARD ::
   271    *   TT_ADOBE_ID_STANDARD ::
   272    *     Adobe standard encoding.
   272    *     Adobe standard encoding.
   273    *   TT_ADOBE_ID_EXPERT ::
   273    *   TT_ADOBE_ID_EXPERT ::
   282 #define TT_ADOBE_ID_EXPERT    1
   282 #define TT_ADOBE_ID_EXPERT    1
   283 #define TT_ADOBE_ID_CUSTOM    2
   283 #define TT_ADOBE_ID_CUSTOM    2
   284 #define TT_ADOBE_ID_LATIN_1   3
   284 #define TT_ADOBE_ID_LATIN_1   3
   285 
   285 
   286 
   286 
   287   /***********************************************************************
   287   /**************************************************************************
   288    *
   288    *
   289    * @enum:
   289    * @enum:
   290    *   TT_MAC_LANGID_XXX
   290    *   TT_MAC_LANGID_XXX
   291    *
   291    *
   292    * @description:
   292    * @description:
   293    *   Possible values of the language identifier field in the name records
   293    *   Possible values of the language identifier field in the name records
   294    *   of the SFNT `name' table if the `platform' identifier code is
   294    *   of the SFNT 'name' table if the 'platform' identifier code is
   295    *   @TT_PLATFORM_MACINTOSH.  These values are also used as return values
   295    *   @TT_PLATFORM_MACINTOSH.  These values are also used as return values
   296    *   for function @FT_Get_CMap_Language_ID.
   296    *   for function @FT_Get_CMap_Language_ID.
   297    *
   297    *
   298    *   The canonical source for Apple's IDs is
   298    *   The canonical source for Apple's IDs is
   299    *
   299    *
   422 #define TT_MAC_LANGID_GREEK_POLYTONIC             148
   422 #define TT_MAC_LANGID_GREEK_POLYTONIC             148
   423 #define TT_MAC_LANGID_GREELANDIC                  149
   423 #define TT_MAC_LANGID_GREELANDIC                  149
   424 #define TT_MAC_LANGID_AZERBAIJANI_ROMAN_SCRIPT    150
   424 #define TT_MAC_LANGID_AZERBAIJANI_ROMAN_SCRIPT    150
   425 
   425 
   426 
   426 
   427   /***********************************************************************
   427   /**************************************************************************
   428    *
   428    *
   429    * @enum:
   429    * @enum:
   430    *   TT_MS_LANGID_XXX
   430    *   TT_MS_LANGID_XXX
   431    *
   431    *
   432    * @description:
   432    * @description:
   433    *   Possible values of the language identifier field in the name records
   433    *   Possible values of the language identifier field in the name records
   434    *   of the SFNT `name' table if the `platform' identifier code is
   434    *   of the SFNT 'name' table if the 'platform' identifier code is
   435    *   @TT_PLATFORM_MICROSOFT.  These values are also used as return values
   435    *   @TT_PLATFORM_MICROSOFT.  These values are also used as return values
   436    *   for function @FT_Get_CMap_Language_ID.
   436    *   for function @FT_Get_CMap_Language_ID.
   437    *
   437    *
   438    *   The canonical source for Microsoft's IDs is
   438    *   The canonical source for Microsoft's IDs is
   439    *
   439    *
   440    *     https://www.microsoft.com/globaldev/reference/lcid-all.mspx ,
   440    *     https://docs.microsoft.com/en-us/windows/desktop/Intl/language-identifier-constants-and-strings ,
   441    *
   441    *
   442    *   however, we only provide macros for language identifiers present in
   442    *   however, we only provide macros for language identifiers present in
   443    *   the OpenType specification: Microsoft has abandoned the concept of
   443    *   the OpenType specification: Microsoft has abandoned the concept of
   444    *   LCIDs (language code identifiers), and format~1 of the `name' table
   444    *   LCIDs (language code identifiers), and format~1 of the 'name' table
   445    *   provides a better mechanism for languages not covered here.
   445    *   provides a better mechanism for languages not covered here.
   446    *
   446    *
   447    *   More legacy values not listed in the reference can be found in the
   447    *   More legacy values not listed in the reference can be found in the
   448    *   @FT_TRUETYPE_IDS_H header file.
   448    *   @FT_TRUETYPE_IDS_H header file.
   449    */
   449    */
   778 #define TT_MS_LANGID_PAPIAMENTU_NETHERLANDS_ANTILLES   0x0479
   778 #define TT_MS_LANGID_PAPIAMENTU_NETHERLANDS_ANTILLES   0x0479
   779 #define TT_MS_LANGID_UIGHUR_CHINA \
   779 #define TT_MS_LANGID_UIGHUR_CHINA \
   780           TT_MS_LANGID_UIGHUR_PRC
   780           TT_MS_LANGID_UIGHUR_PRC
   781 
   781 
   782 
   782 
   783   /***********************************************************************
   783   /**************************************************************************
   784    *
   784    *
   785    * @enum:
   785    * @enum:
   786    *   TT_NAME_ID_XXX
   786    *   TT_NAME_ID_XXX
   787    *
   787    *
   788    * @description:
   788    * @description:
   789    *   Possible values of the `name' identifier field in the name records of
   789    *   Possible values of the 'name' identifier field in the name records of
   790    *   an SFNT `name' table.  These values are platform independent.
   790    *   an SFNT 'name' table.  These values are platform independent.
   791    */
   791    */
   792 
   792 
   793 #define TT_NAME_ID_COPYRIGHT              0
   793 #define TT_NAME_ID_COPYRIGHT              0
   794 #define TT_NAME_ID_FONT_FAMILY            1
   794 #define TT_NAME_ID_FONT_FAMILY            1
   795 #define TT_NAME_ID_FONT_SUBFAMILY         2
   795 #define TT_NAME_ID_FONT_SUBFAMILY         2
   832   /* these two values are deprecated */
   832   /* these two values are deprecated */
   833 #define TT_NAME_ID_PREFERRED_FAMILY     TT_NAME_ID_TYPOGRAPHIC_FAMILY
   833 #define TT_NAME_ID_PREFERRED_FAMILY     TT_NAME_ID_TYPOGRAPHIC_FAMILY
   834 #define TT_NAME_ID_PREFERRED_SUBFAMILY  TT_NAME_ID_TYPOGRAPHIC_SUBFAMILY
   834 #define TT_NAME_ID_PREFERRED_SUBFAMILY  TT_NAME_ID_TYPOGRAPHIC_SUBFAMILY
   835 
   835 
   836 
   836 
   837   /***********************************************************************
   837   /**************************************************************************
   838    *
   838    *
   839    * @enum:
   839    * @enum:
   840    *   TT_UCR_XXX
   840    *   TT_UCR_XXX
   841    *
   841    *
   842    * @description:
   842    * @description:
   843    *   Possible bit mask values for the `ulUnicodeRangeX' fields in an SFNT
   843    *   Possible bit mask values for the `ulUnicodeRangeX` fields in an SFNT
   844    *   `OS/2' table.
   844    *   'OS/2' table.
   845    */
   845    */
   846 
   846 
   847   /* ulUnicodeRange1 */
   847   /* ulUnicodeRange1 */
   848   /* --------------- */
   848   /* --------------- */
   849 
   849