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