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