home *** CD-ROM | disk | FTP | other *** search
/ The Developer Connection…ice Driver Kit for OS/2 3 / DEV3-D1.ISO / devtools / os2tk21j / cplus / os2h / pmfont.h__ / pmfont.h
Encoding:
C/C++ Source or Header  |  1993-04-29  |  6.8 KB  |  230 lines

  1. /****************************** Module Header ******************************\
  2. *
  3. * Module Name: PMFONT.H
  4. *
  5. * OS/2 Presentation Manager type declarations for Fonts.
  6. *
  7. * Copyright (c) International Business Machines Corporation 1981, 1988-1992
  8. *
  9. * ===========================================================================
  10. *
  11. * Comments at the end of each typedef line give the name tags used in
  12. * the assembler include version of this file.
  13. *
  14. *
  15. \***************************************************************************/
  16.  
  17. /* XLATOFF */
  18.    #pragma info( none )
  19.    #ifndef __CHKHDR__
  20.       #pragma info( none )
  21.    #endif
  22.    #pragma info( restore )
  23. #ifdef __cplusplus
  24.       extern "C" {
  25. #endif
  26. /* XLATON */
  27.  
  28. /* XLATOFF */
  29. #ifndef PMFONT_INCLUDED
  30.    /* XLATON */
  31.    #define PMFONT_INCLUDED
  32.  
  33.    typedef struct _FOCAMETRICS    /* foca */
  34.    {
  35.       ULONG   ulIdentity;
  36.       ULONG   ulSize;
  37.       CHAR    szFamilyname[32];
  38.       CHAR    szFacename[32];
  39.       SHORT   usRegistryId;
  40.       SHORT   usCodePage;
  41.       SHORT   yEmHeight;
  42.       SHORT   yXHeight;
  43.       SHORT   yMaxAscender;
  44.       SHORT   yMaxDescender;
  45.       SHORT   yLowerCaseAscent;
  46.       SHORT   yLowerCaseDescent;
  47.       SHORT   yInternalLeading;
  48.       SHORT   yExternalLeading;
  49.       SHORT   xAveCharWidth;
  50.       SHORT   xMaxCharInc;
  51.       SHORT   xEmInc;
  52.       SHORT   yMaxBaselineExt;
  53.       SHORT   sCharSlope;
  54.       SHORT   sInlineDir;
  55.       SHORT   sCharRot;
  56.       USHORT  usWeightClass;
  57.       USHORT  usWidthClass;
  58.       SHORT   xDeviceRes;
  59.       SHORT   yDeviceRes;
  60.       SHORT   usFirstChar;
  61.       SHORT   usLastChar;
  62.       SHORT   usDefaultChar;
  63.       SHORT   usBreakChar;
  64.       SHORT   usNominalPointSize;
  65.       SHORT   usMinimumPointSize;
  66.       SHORT   usMaximumPointSize;
  67.       SHORT   fsTypeFlags;
  68.       SHORT   fsDefn;
  69.       SHORT   fsSelectionFlags;
  70.       SHORT   fsCapabilities;
  71.       SHORT   ySubscriptXSize;
  72.       SHORT   ySubscriptYSize;
  73.       SHORT   ySubscriptXOffset;
  74.       SHORT   ySubscriptYOffset;
  75.       SHORT   ySuperscriptXSize;
  76.       SHORT   ySuperscriptYSize;
  77.       SHORT   ySuperscriptXOffset;
  78.       SHORT   ySuperscriptYOffset;
  79.       SHORT   yUnderscoreSize;
  80.       SHORT   yUnderscorePosition;
  81.       SHORT   yStrikeoutSize;
  82.       SHORT   yStrikeoutPosition;
  83.       SHORT   usKerningPairs;
  84.       SHORT   sFamilyClass;
  85.       PSZ      pszDeviceNameOffset;
  86.    } FOCAMETRICS;
  87.    typedef FOCAMETRICS *PFOCAMETRICS;
  88.  
  89.    typedef struct _FONTFILEMETRICS    /* ffm */
  90.    {
  91.       ULONG   ulIdentity;
  92.       ULONG   ulSize;
  93.       CHAR    szFamilyname[32];
  94.       CHAR    szFacename[32];
  95.       SHORT   usRegistryId;
  96.       SHORT   usCodePage;
  97.       SHORT   yEmHeight;
  98.       SHORT   yXHeight;
  99.       SHORT   yMaxAscender;
  100.       SHORT   yMaxDescender;
  101.       SHORT   yLowerCaseAscent;
  102.       SHORT   yLowerCaseDescent;
  103.       SHORT   yInternalLeading;
  104.       SHORT   yExternalLeading;
  105.       SHORT   xAveCharWidth;
  106.       SHORT   xMaxCharInc;
  107.       SHORT   xEmInc;
  108.       SHORT   yMaxBaselineExt;
  109.       SHORT   sCharSlope;
  110.       SHORT   sInlineDir;
  111.       SHORT   sCharRot;
  112.       USHORT  usWeightClass;
  113.       USHORT  usWidthClass;
  114.       SHORT   xDeviceRes;
  115.       SHORT   yDeviceRes;
  116.       SHORT   usFirstChar;
  117.       SHORT   usLastChar;
  118.       SHORT   usDefaultChar;
  119.       SHORT   usBreakChar;
  120.       SHORT   usNominalPointSize;
  121.       SHORT   usMinimumPointSize;
  122.       SHORT   usMaximumPointSize;
  123.       SHORT   fsTypeFlags;
  124.       SHORT   fsDefn;
  125.       SHORT   fsSelectionFlags;
  126.       SHORT   fsCapabilities;
  127.       SHORT   ySubscriptXSize;
  128.       SHORT   ySubscriptYSize;
  129.       SHORT   ySubscriptXOffset;
  130.       SHORT   ySubscriptYOffset;
  131.       SHORT   ySuperscriptXSize;
  132.       SHORT   ySuperscriptYSize;
  133.       SHORT   ySuperscriptXOffset;
  134.       SHORT   ySuperscriptYOffset;
  135.       SHORT   yUnderscoreSize;
  136.       SHORT   yUnderscorePosition;
  137.       SHORT   yStrikeoutSize;
  138.       SHORT   yStrikeoutPosition;
  139.       SHORT   usKerningPairs;
  140.       SHORT   sFamilyClass;
  141.       ULONG   ulReserved;
  142.       PANOSE  panose;
  143.    } FONTFILEMETRICS;
  144.    typedef FONTFILEMETRICS *PFONTFILEMETRICS;
  145.  
  146.    typedef struct _FONTDEFINITIONHEADER    /* fdh */
  147.    {
  148.       ULONG   ulIdentity;
  149.       ULONG   ulSize;
  150.       SHORT   fsFontdef;
  151.       SHORT   fsChardef;
  152.       SHORT   usCellSize;
  153.       SHORT   xCellWidth;
  154.       SHORT   yCellHeight;
  155.       SHORT   xCellIncrement;
  156.       SHORT   xCellA;
  157.       SHORT   xCellB;
  158.       SHORT   xCellC;
  159.       SHORT   pCellBaseOffset;
  160.    } FONTDEFINITIONHEADER;
  161.    typedef FONTDEFINITIONHEADER *PFONTDEFINITIONHEADER;
  162.  
  163.    #define FONTDEFFONT1     0x0047  /* set width, height, inc. & base offset */
  164.    #define FONTDEFFONT2     0x0042  /* set height & base offset            */
  165.    #define FONTDEFFONT3     0x0042  /* set height & base offset            */
  166.    #define FONTDEFCHAR1     0x0081  /* set char offset and width           */
  167.    #define FONTDEFCHAR2     0x0081  /* set char offset and width           */
  168.    #define FONTDEFCHAR3     0x00b8  /* set char offset, A, B, and C space  */
  169.    #define SPACE_UNDEF      0x8000  /* space undefined = take default      */
  170.  
  171.    typedef struct _FONTSIGNATURE    /* fs */
  172.    {
  173.       ULONG   ulIdentity;
  174.       ULONG   ulSize;
  175.       CHAR    achSignature[12];
  176.    } FONTSIGNATURE;
  177.    typedef FONTSIGNATURE *PFONTSIGNATURE;
  178.  
  179.    typedef struct _ADDITIONALMETRICS    /* am */
  180.    {
  181.       ULONG   ulIdentity;
  182.       ULONG   ulSize;
  183.       PANOSE  panose;
  184.    } ADDITIONALMETRICS;
  185.    typedef ADDITIONALMETRICS *PADDITIONALMETRICS;
  186.  
  187.    typedef struct _FOCAFONT    /* ff */
  188.    {
  189.       FONTSIGNATURE     fsSignature;
  190.       FOCAMETRICS       fmMetrics;
  191.       FONTDEFINITIONHEADER fdDefinitions;
  192.    } FOCAFONT;
  193.    typedef FOCAFONT *PFOCAFONT;
  194.  
  195.    #define FONT_SIGNATURE          0xfffffffe /* Identity header start    */
  196.    #define FONT_METRICS            0x00000001 /* Identity metrics         */
  197.    #define FONT_DEFINITION         0x00000002 /* Identity definition      */
  198.    #define FONT_KERNPAIRS          0x00000003 /* Identity Kern Pairs      */
  199.    #define FONT_ADDITIONALMETRICS  0x00000004 /* Identity Additional Metrics */
  200.    #define FONT_ENDRECORD          0xffffffff /* Identity record end      */
  201.  
  202.    /* Options for QueryFonts */
  203.  
  204.    #define QUERY_PUBLIC_FONTS      0x0001
  205.    #define QUERY_PRIVATE_FONTS     0x0002
  206.  
  207.    #define CDEF_GENERIC            0x0001
  208.    #define CDEF_BOLD               0x0002
  209.    #define CDEF_ITALIC             0x0004
  210.    #define CDEF_UNDERSCORE         0x0008
  211.    #define CDEF_STRIKEOUT          0x0010
  212.    #define CDEF_OUTLINE            0x0020
  213.  
  214.    /* XLATOFF */
  215. #endif /* PMFONT_INCLUDED */
  216. /* XLATON */
  217.  
  218. /* XLATOFF */
  219. #ifdef __cplusplus
  220.         }
  221. #endif
  222.    #pragma info( none )
  223.    #ifndef __CHKHDR__
  224.       #pragma info( restore )
  225.    #endif
  226.    #pragma info( restore )
  227. /* XLATON */
  228.  
  229. /**************************** end of file **********************************/
  230.