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