home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / bpos13.zip / pmddi.pas < prev    next >
Pascal/Delphi Source File  |  1993-11-24  |  18KB  |  749 lines

  1. {| Unit: pmddi
  2.  | Version: 1.00
  3.  | translated from file pmddi.H
  4.  | Original translation: Peter Sawatzki (ps)
  5.  | Contributing:
  6.  |   (fill in)
  7.  |
  8.  | change history:
  9.  | Date:    Ver: Author:
  10.  | 11/13/93 1.00 ps     original translation by ps
  11. }
  12. Unit pmddi;
  13. Interface
  14. Uses
  15.   Os2Def,
  16.   PmGpi,
  17.   BseDos;
  18. {**************************************************************************\
  19. *
  20. * Module Name: PMDDI.H
  21. *
  22. * OS/2 Presentation Manager Graphics Engine entry point, macro and type
  23. * declarations.
  24. *
  25. * Copyright
  26. *
  27. * =========================================================================
  28. *
  29. * Further defines must be made to specify which of the GRE function macros
  30. * should be defined.  INCL_GREALL causes all of them to be defined.
  31. *
  32. *     INCL_GRE_ARCS        - Arcs functions
  33. *     INCL_GRE_LINES       - Line functions
  34. *     INCL_GRE_MARKERS     - etc.
  35. *     INCL_GRE_SCANS
  36. *     INCL_GRE_BITMAPS
  37. *     INCL_GRE_STRINGS
  38. *     INCL_GRE_PATHS
  39. *     INCL_GRE_PICK
  40. *     INCL_GRE_CLIP
  41. *     INCL_GRE_REGIONS
  42. *     INCL_GRE_XFORMS
  43. *     INCL_GRE_DEVMISC
  44. *     INCL_GRE_COLORTABLE
  45. *     INCL_GRE_DEVICE
  46. *     INCL_GRE_DCS
  47. *     INCL_GRE_SETID
  48. *     INCL_GRE_FONTS
  49. *     INCL_GRE_JOURNALING
  50. *     INCL_GRE_LCID
  51. *     INCL_GRE_DEVSUPPORT
  52. \**************************************************************************}
  53.  
  54. { exported Engine DDI functions }
  55.  
  56.   Function SetDriverInfo (Par1: ULONG; Par2: LHANDLE; Par3: ULONG; hDC: HDC): ULONG;
  57.   Function GetDriverInfo (Par1: LHANDLE; Par2: ULONG; hDC: HDC): ULONG;
  58.   Function PostDeviceModes (Par1: PDRIVDATA; Par2, Par3, Par4: PSZ; Par5: ULONG): ULONG;
  59.   Function GreInitialize: BOOL;
  60.  
  61. { define common types in the Engine and DDI }
  62.  
  63.  
  64. Type
  65.   RECTS = Record                        { rcs }
  66.     pts1,
  67.     pts2: POINTS
  68.   End;
  69.   pRECTS = ^RECTS;
  70.  
  71.   POINTFX = Record                      { ptfx }
  72.     x,
  73.     y: FIXED
  74.   End;
  75.   pPOINTFX = ^POINTFX;
  76.  
  77.   RECTFX = Record                       { rcfx }
  78.     ptfx1,
  79.     ptfx2: POINTFX
  80.   End;
  81.  
  82.   pRECTFX = ^PRECTFX;
  83.  
  84.   XFORM = Record                        { xform }
  85.     fxM11,
  86.     fxM12,
  87.     fxM21,
  88.     fxM22: FIXED;
  89.     lM41,
  90.     lM42: LongInt
  91.   End;
  92.   pXFORM = ^PXFORM;
  93.  
  94.   LCID = LONG;      { locally-coded id }
  95.   pLCID = ^LCID;
  96.   PHID = LONG;      { path id          }
  97.  
  98. { get GRE function macros }
  99. { have INCL_GREALL defined to get all of these }
  100.  
  101. { Command Flags for high word of FunN }
  102.  
  103. Const
  104.   COM_DRAW                =  $0001;
  105.   COM_BOUND                        =  $0002;
  106.   COM_CORRELATE                    =  $0004;
  107.   COM_ALT_BOUND                    =  $0008;
  108.   COM_AREA                         =  $0010;
  109.   COM_PATH                         =  $0020;
  110.   COM_TRANSFORM                    =  $0040;
  111.   COM_RECORDING                    =  $0080;
  112.   COM_DEVICE                       =  $0100;
  113.  
  114. { BoxBoundary }
  115. { BoxInterior }
  116. { BoxBoth }
  117.  
  118. Type
  119.   BOXPARAMS = Record                    { boxp }
  120.     ptl: POINTL;
  121.     sizl: SIZEL
  122.   End;
  123.   pBOXPARAMS = ^BOXPARAMS;
  124.  
  125. { CopyClipRegion }
  126.  
  127. Const
  128.   COPYCRGN_ALLINTERSECT   = 0 ;
  129.   COPYCRGN_VISRGN                  = 1 ;
  130.   COPYCRGN_CLIPRGN                 = 2 ;
  131.  
  132. { SetupDC }
  133.  
  134.   SETUPDC_VISRGN                   =  $00000001 ;
  135.   SETUPDC_ORIGIN                   =  $00000002 ;
  136.   SETUPDC_ACCUMBOUNDSON            =  $00000004 ;
  137.   SETUPDC_ACCUMBOUNDSOFF           =  $00000008 ;
  138.   SETUPDC_RECALCCLIP               =  $00000010 ;
  139.   SETUPDC_SETOWNER                 =  $00000020 ;
  140.   SETUPDC_CLEANDC                  =  $00000040 ;
  141.  
  142. { QueryViewportSize }
  143. Type
  144.   VIEWPORTSIZE = Record                 { vs }
  145.     cx,
  146.     cy: ULONG
  147.   End;
  148.   pVIEWPORTSIZE = ^VIEWPORTSIZE;
  149.  
  150. { Constants for GreInitializeAttributes }
  151.  
  152. Const
  153.   INAT_DEFAULTATTRIBUTES  = 1 ;
  154.   INAT_CURRENTATTRIBUTES           = 2 ;
  155.  
  156. { InvalidateVisRegion }
  157.  
  158.  
  159. Type
  160.   DC_BLOCK = Record                     { ivr }
  161.     hdc,
  162.     hddc: ULONG
  163.   End;
  164.   pDC_BLOCK = ^DC_BLOCK;
  165.  
  166. { Display information resource structure }
  167.  
  168.   DISPLAYINFO = Record                  { dspinfo }
  169.     cb: USHORT;
  170.     cxIcon,
  171.     cyIcon,
  172.     cxPointer,
  173.     cyPointer,
  174.     cxBorder,
  175.     cyBorder,
  176.     cxHSlider,
  177.     cyVSlider,
  178.     cxSizeBorder,
  179.     cySizeBorder,
  180.     cxDeviceAlign,
  181.     cyDeviceAlign: SHORT
  182.   End;
  183.   pDISPLAYINFO = ^DISPLAYINFO;
  184.  
  185. { Parameters for the DC Enable function }
  186.  
  187.   DENPARAMS = Record                    { den }
  188.     ulStateInfo,
  189.     ulType,
  190.     ulHDC: ULONG
  191.   End;
  192.   pDENPARAMS = ^DENPARAMS;
  193.  
  194.  
  195.   STYLERATIO = Record                   { sr }
  196.     dx,
  197.     dy: BYTE
  198.   End;
  199.   pSTYLERATIO = ^STYLERATIO;
  200.  
  201. { Options flags for SetGlobalAttribute }
  202.  
  203.  
  204. Const
  205.   GATTR_DEFAULT           = 1 ;
  206.  
  207. { Attribute Types for SetGlobalAttribute }
  208.  
  209.   ATYPE_COLOR                      = 1 ;
  210.   ATYPE_BACK_COLOR                 = 2 ;
  211.   ATYPE_MIX_MODE                   = 3 ;
  212.   ATYPE_BACK_MIX_MODE              = 4 ;
  213.  
  214. { Options for CharStringPos }
  215.  
  216.   CHS_START_XY                     =  $00000020 ;
  217.   CHS_ATTR_INFO                    =  $00000040 ;
  218.  
  219.  
  220. Type
  221.   CSP_INFO = Record                     { csp }
  222.     cSize,
  223.     lColor,
  224.     lBackColor: LongInt
  225.   End;
  226.   pCSP_INFO = ^CSP_INFO;
  227.  
  228. { Set/GetProcessControl }
  229.  
  230.  
  231. Const
  232.   PCTL_DRAW               =  $00000001 ;
  233.   PCTL_BOUND                       =  $00000002 ;
  234.   PCTL_CORRELATE                   =  $00000004 ;
  235.   PCTL_USERBOUNDS                  =  $00000008 ;
  236.   PCTL_AREA                        =  $00000010 ;
  237.  
  238. { ResetBounds }
  239.  
  240.   RB_GPI                           =  $00000001 ;
  241.   RB_USER                          =  $00000002 ;
  242.  
  243. { GetBoundsData }
  244.  
  245.   GBD_GPI                          = 0 ;
  246.   GBD_USER                         = 1 ;
  247.  
  248. { EndArea Cancel Option }
  249.  
  250.   EA_DRAW                          =  $00000000 ;
  251.   EA_CANCEL                        =  $00000001 ;
  252.  
  253. { Bitblt Style }
  254.  
  255.   BLTMODE_SRC_BITMAP               =  $00010000 ;
  256.   BLTMODE_ATTRS_PRES               =  $00020000 ;
  257.   BBO_TARGWORLD                    =  $00000100 ;
  258.  
  259.  
  260. Type
  261.   BITBLTPARAMETERS = Record             { bbp }
  262.     rclTarg,
  263.     rclSrc: RECTL
  264.   End;
  265.   pBITBLTPARAMETERS = ^BITBLTPARAMETERS;
  266.  
  267.   BITBLTATTRS = Record                  { bba }
  268.     cSize,
  269.     lColor,
  270.     lBackColor: LongInt
  271.   End;
  272.   pBITBLTATTRS = ^BITBLTATTRS;
  273.  
  274. { LCIDs }
  275.  
  276.  
  277. Const
  278.   LCID_AVIO_1             = (-2 );
  279.   LCID_AVIO_2                      = (-3 );
  280.   LCID_AVIO_3                      = (-4 );
  281.  
  282.   LCID_RANGE_GPI                   = 1 ;
  283.   LCID_RANGE_AVIO                  = 2 ;
  284.   LCID_RANGE_BOTH                  = 3 ;
  285.   LCID_GRAPHICS_MIN                = 1;
  286.   LCID_GRAPHICS_MAX                = 254;
  287.  
  288. { ResetDC }
  289.  
  290.   RDC_RGBMODE                      =  $1 ;
  291.   RDC_SETOWNERTOSHELL              =  $2 ;
  292.  
  293. { SetRandomXform }
  294.  
  295.   SX_UNITY                         = 0 ;
  296.   SX_CAT_AFTER                     = 1 ;
  297.   SX_CAT_BEFORE                    = 2 ;
  298.   SX_OVERWRITE                     = 3 ;
  299.  
  300. { Transform accelerators                                                   }
  301. { These bits are only valid if the MATRIX_SIMPLE bit is set.               }
  302. { The X and Y negate flags are only meaningful if MATRIX_UNITS is set.     }
  303.  
  304.   MATRIX_SIMPLE                    =  $0001 ;               { two entries are zero      }
  305.   MATRIX_UNITS                     =  $0002 ;               { all entries are +1 or -1  }
  306.   MATRIX_XY_EXCHANGE               =  $0004 ;               { zeros are on the diagonal }
  307.   MATRIX_X_NEGATE                  =  $0008 ;               { X is hit by negative      }
  308.   MATRIX_Y_NEGATE                  =  $0010 ;               { Y is hit by negative      }
  309.   MATRIX_TRANSLATION               =  $0020 ;               { non-zero translation      }
  310.  
  311. { NotifyClipChange }
  312.  
  313.   NCC_CLEANDC                      =  $0002 ;               { clear DC dirty bit        }
  314.  
  315. { NotifyTransformChange }
  316.  
  317.  
  318. Type
  319.   NOTIFYTRANSFORMDATA = Record          { ntd }
  320.     usType: USHORT;
  321.     xform: XFORM
  322.   End;
  323.   pNOTIFYTRANSFORMDATA = ^NOTIFYTRANSFORMDATA;
  324.  
  325.  
  326. { ColorTable }
  327. Const
  328.   LCOL_SYSCOLORS          =  $0010 ;
  329.  
  330. { query device caps }
  331. Type
  332.   QCDARRAY = Record                     { qcd }
  333.     iFormat,
  334.     iSmallest,
  335.     iLargest,
  336.     cAvailable,
  337.     cSpecifiable,
  338.     iMax: LongInt
  339.   End;
  340.   pQCDARRAY = ^QCDARRAY;
  341.  
  342.  
  343. Const
  344.   CAPS_MIX_OR             =  $00000001 ;
  345.   CAPS_MIX_COPY                    =  $00000002 ;
  346.   CAPS_MIX_UNDERPAINT              =  $00000004 ;
  347.   CAPS_MIX_XOR                     =  $00000008 ;
  348.   CAPS_MIX_INVISIBLE               =  $00000010 ;
  349.   CAPS_MIX_AND                     =  $00000020 ;
  350.   CAPS_MIX_OTHER                   =  $00000040 ;
  351.  
  352. { for CAPS_DEVICE_FONT_SIM }
  353.   CAPS_DEV_FONT_SIM_BOLD           = 1 ;
  354.   CAPS_DEV_FONT_SIM_ITALIC         = 2 ;
  355.   CAPS_DEV_FONT_SIM_UNDERSCORE     = 4 ;
  356.   CAPS_DEV_FONT_SIM_STRIKEOUT      = 8 ;
  357.  
  358.   CAPS_BACKMIX_OR                  =  $00000001 ;
  359.   CAPS_BACKMIX_COPY                =  $00000002 ;
  360.   CAPS_BACKMIX_UNDERPAINT          =  $00000004 ;
  361.   CAPS_BACKMIX_XOR                 =  $00000008 ;
  362.   CAPS_BACKMIX_INVISIBLE           =  $00000010 ;
  363.  
  364.  
  365. { #define CAPS_RASTER_BITBLT      0x00000001L    defined in pmdev.h }
  366. { #define CAPS_RASTER_BANDING     0x00000002L                       }
  367. { #define CAPS_RASTER_STRETCHBLT  0x00000004L                       }
  368. { #define CAPS_RASTER_SETPEL      0x00000010L                       }
  369.   CAPS_FONT_OUTLINE_MANAGE         = 16 ;
  370.   CAPS_FONT_IMAGE_MANAGE           = 32 ;
  371.   SFONT_RASTER                     = 100;
  372.   SFONT_OUTLINE                    = 101;
  373.   FONT                             = 1000;                  { must not conflict with RT_XXX }
  374.                                             { constants in BSEDOS.H         }
  375.  
  376. { DCCaps }
  377.  
  378.   DCCAPS_LINE                      =  $0100;
  379.   DCCAPS_CURVE                     =  $0200;
  380.   DCCAPS_AREA                      =  $0400;
  381.   DCCAPS_MARKER                    =  $0800;
  382.   DCCAPS_TEXT                      =  $1000;
  383.  
  384. { DeviceDeleteBitmap }
  385.   BITMAP_USAGE_TRANSLATE           =  $0004;
  386.  
  387. { DeleteBitmap return structure }
  388.  
  389. Type
  390.   DELETERETURN = Record                 { dr }
  391.     pInfo,
  392.     pBits: ULONG
  393.   End;
  394.   pDELETERETURN = ^DELETERETURN;
  395.  
  396. { Short Line Header }
  397.  
  398.  
  399. Const
  400.   SLH_FORMAT_IS_16_DOT_16 = 1;
  401.   PSL_YMAJOR                       =  $8000;                { bit mask for usStyle }
  402.  
  403.  
  404. Type
  405.   pSHORTLINEHEADER = ^SHORTLINEHEADER;
  406.   SHORTLINEHEADER = Record              { slh }
  407.     usStyle,
  408.     usFormat: USHORT;
  409.     ptsStart,
  410.     ptsStop: POINTS;
  411.     sxLeft,
  412.     sxRight: SHORT;
  413.     pslhNext,
  414.     pslhPrev: pSHORTLINEHEADER
  415.   End;
  416.  
  417. { Short Line }
  418.  
  419.   SHORTLINE = Record                    { sl }
  420.     slh: SHORTLINEHEADER;
  421.     ax: Array[0..0] Of SHORT
  422.   End;
  423.   pSHORTLINE = ^SHORTLINE;
  424.  
  425.   SCANDATA = Record                     { sd }
  426.     pslFirstLeft,
  427.     pslLastLeft,
  428.     pslFirstRight,
  429.     pslLastRight: PSHORTLINE;
  430.     c: ULONG;
  431.     rclBound: RECTL
  432.   End;
  433.   pSCANDATA = ^SCANDATA;
  434.  
  435. { Index for Set/GetDriverInfo }
  436.  
  437.  
  438. Const
  439.   DI_HDC                  =  $00000000 ;
  440.   DI_HBITMAP                       =  $00000001 ;
  441.  
  442. { RealizeFont }
  443.  
  444.   REALIZE_FONT                     = 1;
  445.   REALIZE_ENGINE_FONT              = 2;
  446.   DELETE_FONT                      = 3;
  447.  
  448. { Device Line Bundle }
  449.  
  450.  
  451. Type
  452.   LINEDEFS = Record                     { ldef }
  453.     defType: ULONG
  454.   End;
  455.   pLINEDEFS = ^LINEDEFS;
  456.  
  457.   DLINEBUNDLE = Record                  { dlbnd }
  458.     cAttr,
  459.     cDefs: SHORT;
  460.     lbnd: LINEBUNDLE;
  461.     ldef: LINEDEFS
  462.   End;
  463.   pDLINEBUNDLE = ^DLINEBUNDLE;
  464.  
  465. { Device Area Bundle }
  466.  
  467.   AREADEFS = Record                     { adef }
  468.     defSet: ULONG;
  469.     fFlags,
  470.     CodePage: UINT
  471.   End;
  472.   pAREADEFS = ^AREADEFS;
  473.  
  474.   DAREABUNDLE = Record                  { dabnd }
  475.     cAttr,
  476.     cDefs: SHORT;
  477.     abnd: AREABUNDLE;
  478.     adef: AREADEFS
  479.   End;
  480.   pDAREABUNDLE = ^DAREABUNDLE;
  481.  
  482. { Device Character Bundle }
  483.  
  484.   CHARDEFS = Record                     { cdef }
  485.     defSet: ULONG;
  486.     fFlags,
  487.     CodePage,
  488.     charSpacing: UINT
  489.   End;
  490.   pCHARDEFS = ^CHARDEFS;
  491.  
  492.   DCHARBUNDLE = Record                  { dcbnd }
  493.     cAttr,
  494.     cDefs: SHORT;
  495.     cbnd: CHARBUNDLE;
  496.     cdef: CHARDEFS
  497.   End;
  498.   pDCHARBUNDLE = ^DCHARBUNDLE;
  499.  
  500. { Device Image Bundle }
  501.  
  502. {$ifdef BOGUS}
  503.   IMAGEDEFS = Record
  504.   End;
  505. {$EndIf}
  506.  
  507.   DIMAGEBUNDLE = Record                 { dibnd }
  508.     cAttr,
  509.     cDefs: SHORT;
  510.     ibnd: IMAGEBUNDLE                   {    IMAGEDEFS idef; }
  511.   End;
  512.   pDIMAGEBUNDLE = ^DIMAGEBUNDLE;
  513.  
  514. { Device Marker Bundle }
  515.  
  516.   MARKERDEFS = Record                   { mdef }
  517.     defSet: ULONG;
  518.     fFlags,
  519.     CodePage: UINT
  520.   End;
  521.   pMARKERDEFS = ^MARKERDEFS;
  522.  
  523.   DMARKERBUNDLE = Record                { dmbnd }
  524.     cAttr,
  525.     cDefs: SHORT;
  526.     mbnd: MARKERBUNDLE;
  527.     mdef: MARKERDEFS
  528.   End;
  529.   pDMARKERBUNDLE = ^DMARKERBUNDLE;
  530.  
  531.  
  532. { Signatures of Path data structures }
  533.  
  534. Const
  535.   CURVE_IDENTIFIER        =  $43;
  536.   SUBPATH_IDENTIFIER               =  $53;
  537.   PATH_IDENTIFIER                  =  $50;
  538.   PATHSEGMENT_IDENTIFIER           =  $5350;
  539.  
  540. { Curve types }
  541.  
  542.   LINE_IDENTIFIER                  =  $4C;
  543.   FILLET_SHARP_IDENTIFIER          =  $46;
  544.   FILLET_EQN_IDENTIFIER            =  $45;
  545.   CURVEATTR_IDENTIFIER             =  $41;
  546.  
  547. { Subpath types }
  548.  
  549.   SUBPATH_CLOSED                   =  $43;
  550.   SUBPATH_OPEN                     =  $4F;
  551.  
  552. { Path types }
  553.  
  554.   BEGINAREA_IDENTIFIER             =  $41;
  555.   BEGINPATH_IDENTIFIER             =  $50;
  556.   PATHSEGMENT_FORMAT_16_16         = 1;
  557.  
  558. { Flags for curve data structures }
  559.  
  560.   CURVE_FIRST_IN_SUBPATH           =  $0001;
  561.   CURVE_DO_FIRST_PEL               =  $0002;
  562.   CURVE_GOES_UP                    =  $0004;
  563.   CURVE_IS_HORIZONTAL              =  $0008;
  564.   CURVE_IS_X_MAJOR                 =  $0010;
  565.   CURVE_GOES_LEFT                  =  $0020;
  566.   CURVE_FIRST_CARVED               =  $0040;
  567.   CURVE_HALF_COOKED                =  $0400;
  568. { Flags for SubPath data structures }
  569.  
  570.   SUBPATH_DO_FIRST_PEL             =  $0002;
  571.  
  572. { Flags for Path data structures }
  573.  
  574.   PATH_HAS_LINES_PRESENT           =  $4000;
  575.   PATH_HAS_CONICS_PRESENT          =  $8000;
  576.  
  577. { Data structures to support the Path API }
  578.  
  579.  
  580. Type
  581.   pCURVE   = ^CURVE;
  582.   CURVE = Record                        { cv }
  583.     bIdent,
  584.     bType: BYTE;
  585.     usStyle,
  586.     fs: USHORT;
  587.     npcvNext,
  588.     npcvPrev,
  589.     npcvAttrs: pCURVE; {**** UNSURE}
  590.     ptfxA,
  591.     ptfxC: POINTFX;
  592.     Reserved2: Array[0..15] Of BYTE
  593.   End;
  594.  
  595.   LINE = Record                         { ln }
  596.     bIdent,
  597.     bType: BYTE;
  598.     usStyle,
  599.     fs: USHORT;
  600.     npcvNext,
  601.     npcvPrev,
  602.     npcvAttrs: pCURVE;
  603.     ptfxA,
  604.     ptfxC: POINTFX;
  605.     ptsA,
  606.     ptsC: POINTS;
  607.     lRslope: FIXED;
  608.     Reserved2: Array[0..3] Of BYTE
  609.   End;
  610.   pLINE    = ^LINE;
  611.  
  612.   FILLETEQN = Record                    { fse }
  613.     bIdent,
  614.     bType: BYTE;
  615.     usReferences: USHORT;
  616.     ptsA,
  617.     ptsC,
  618.     ptsB: POINTS;
  619.     usNumerator,
  620.     usDenominator: USHORT;
  621.     lAlpha,
  622.     lBeta,
  623.     lGamma,
  624.     lDelta,
  625.     lEpsilon,
  626.     lZeta: LongInt
  627.   End;
  628.   pFILLETEQN = ^FILLETEQN;
  629.  
  630.   FILLETSHARP = Record                  { fs }
  631.     bIdent,
  632.     bType: BYTE;
  633.     usStyle,
  634.     fs: USHORT;
  635.     npcvNext,
  636.     npcvPrev,
  637.     npcvAttrs: pCURVE;
  638.     ptfxA,
  639.     ptfxC,
  640.     ptfxB: POINTFX;
  641.     lSharpness: FIXED;
  642.     npEquation: ^FILLETEQN;
  643.     Reserved2: Array[0..1] Of BYTE
  644.   End;
  645.   pFILLETSHARP = ^FILLETSHARP;
  646.  
  647.   CURVEATTR = Record                    { cva }
  648.     bIdent,
  649.     bType: BYTE;
  650.     flAttrs: ULONG;
  651.     Reserved1: Array[0..3] Of BYTE;
  652.     npcvAttrs: pCURVE;
  653.     flDefs: ULONG;
  654.     lbnd: LINEBUNDLE;
  655.     Reserved2: Array[0..1] Of BYTE
  656.   End;
  657.   pCURVEATTR = ^CURVEATTR;
  658.  
  659.   pSUBPATH = ^SUBPATH;
  660.   SUBPATH = Record                      { sp }
  661.     bIdent,
  662.     bType: BYTE;
  663.     usStyle,
  664.     fs: USHORT;
  665.     npspNext,
  666.     npspPrev: pSUBPATH;
  667.     ccv: USHORT;
  668.     flFlags: ULONG;
  669.     npcvFirst,
  670.     npcvLast: pCURVE;
  671.     rcsBounding: RECTS;
  672.     npcvAttrs: pCURVE;
  673.     Reserved1: Array[0..13] Of BYTE
  674.   End;
  675.  
  676.  
  677. Const
  678.   PH_FORMAT_IS_16_DOT_16  = 1;
  679.  
  680.  
  681. Type
  682.   PATH = Record                         { ph }
  683.     bIdent,
  684.     bType: BYTE;
  685.     usFormat,
  686.     usStyle,
  687.     fs: USHORT;
  688.     npspFirst,
  689.     npspLast: pSUBPATH;
  690.     csp: USHORT;
  691.     flFlags: ULONG;
  692.     usDimension: USHORT;
  693.     bSubpathType: BYTE;
  694.     alColor: LongInt;
  695.     ausMixMode,
  696.     ausDefault: USHORT;
  697.     aptlRefPoint: POINTL;
  698.     npcvAttrs: pCURVE;
  699.     Reserved1: Array [0..6] Of BYTE
  700.   End;
  701.   pPATH    = ^PATH;
  702.  
  703.   PATHSEGMENT = Record                  { phs }
  704.     usIdent: USHORT;
  705.     Reserved0: SHORT;
  706.     npcvFree: pCURVE;
  707.     ccvFree,
  708.     cReferences,
  709.     usSize: USHORT;
  710.     npph: pPATH;
  711.     Reserved1: Array[0..1] Of BYTE;
  712.     fsrs: DosFSRSEM {UNSURE: was "FSRSEM"}
  713.   End;
  714.   pPATHSEGMENT = ^PATHSEGMENT;
  715.  
  716. { Argument to DrawCookedPath, etc. }
  717.  
  718.   PIPELINEINFO = Record                 { pi }
  719.     pcv: pCURVE;
  720.     ccv: ULONG
  721.   End;
  722.   pPIPELINEINFO = ^PIPELINEINFO;
  723.  
  724. Const
  725.   JNL_TEMP_FILE           =  $00000001 ;
  726.   JNL_PERM_FILE                    =  $00000002 ;
  727.   JNL_ENGINERAM_FILE               =  $00000004 ;
  728.   JNL_USERRAM_FILE                 =  $00000008 ;
  729.   JNL_DRAW_OPTIMIZATION            =  $00000010 ;
  730.   JNL_BOUNDS_OPTIMIZATION          =  $00000020 ;
  731.  
  732. { QueryDeviceBitmaps }
  733.  
  734.  
  735. Type
  736.   BITMAPFORMAT = Record                 { bmf }
  737.     cPlanes,
  738.     cBitCount: ULONG
  739.   End;
  740.   pBITMAPFORMAT = ^BITMAPFORMAT;
  741.  
  742. Implementation
  743.   Function GetDriverInfo;                 External 'PMGRE'    Index   30;
  744.   Function GreInitialize;                 External 'PMGRE'    Index    4;
  745.   Function PostDeviceModes;               External 'PMGRE'    Index   32;
  746.   Function SetDriverInfo;                 External 'PMGRE'    Index   31;
  747. End.
  748.  
  749.