home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / ddkx86v1.zip / DDKX86 / H / PMGPIP.H < prev    next >
C/C++ Source or Header  |  1995-04-14  |  9KB  |  258 lines

  1. /*DDK*************************************************************************/
  2. /*                                                                           */
  3. /* COPYRIGHT    Copyright (C) 1995 IBM Corporation                           */
  4. /*                                                                           */
  5. /*    The following IBM OS/2 WARP source code is provided to you solely for  */
  6. /*    the purpose of assisting you in your development of OS/2 WARP device   */
  7. /*    drivers. You may use this code in accordance with the IBM License      */
  8. /*    Agreement provided in the IBM Device Driver Source Kit for OS/2. This  */
  9. /*    Copyright statement may not be removed.                                */
  10. /*                                                                           */
  11. /*****************************************************************************/
  12. /****************************** Module Header ******************************\
  13. *
  14. * Module Name: PMGPIP.H
  15. *
  16. * OS/2 Presentation Manager GPI PRIVATE function declarations
  17. *
  18. *
  19. *
  20. * ===========================================================================
  21. *
  22. * Comments at the end of each typedef line give the name tags used in
  23. * the assembler include version of this file.
  24. *
  25. * The assembler include version of this file excludes lines between NOINC
  26. * and INC comments.
  27. *
  28. #ifndef __IBMC__
  29.    * The 32-bit version of this file (as placed into the IBMH directory)
  30.    * excludes all non 32-bit material marked in this file as well
  31.    * as any areas specifically marked with __IBMC__ conditional
  32.    * sections - including this paragraph. The H2IBMH rexx command file
  33.    * removes these sections.
  34. #endif
  35. * ===========================================================================
  36. *
  37. */
  38.  
  39. /* NOINC */
  40. #ifdef __IBMC__
  41.    #pragma checkout( suspend )
  42.       #ifndef __CHKHDR__
  43.          #pragma checkout( suspend )
  44.       #endif
  45.    #pragma checkout( resume )
  46. #endif
  47. /* INC */
  48.  
  49. #define PMGPIP_INCLUDED
  50.  
  51. #ifndef INCL_32         /* If neither INCL_32 or INCL_16 set already */
  52.    #ifndef INCL_16      /* find out from compiler if 32-bit or not.  */
  53.      #ifdef M_I386
  54.         #define INCL_32 /* Compiling for 32-bit */
  55.      #else
  56.         #define INCL_16 /* Compiling for 16-bit */
  57.      #endif
  58.   #endif
  59. #endif
  60.  
  61. /* data truncated error on GpiMoveData and others */
  62. #define GPI_TRUNCATED    2
  63.  
  64. /* control parameter for GpiSetDrawControl */
  65. #define DCTL_PICKMODE         6L
  66. #define DCTL_CORRELATE_FORMAT 7L
  67.  
  68. /* correlation type GpiSetDrawControl */
  69. #define DCTL_CORRELATE_ALL    0L
  70. #define DCTL_CORRELATE_FIRST  1L
  71. #define DCTL_CORRELATE_LAST   2L
  72.  
  73. /* correlate format type GpiSetDrawControl */
  74. #define DCTL_FORMAT_0         0L
  75. #define DCTL_FORMAT_1         1L
  76.  
  77. /* segment attributes used by GpiSet/QuerySegmentAttrs and others */
  78. #define ATTR_PROLOG           7L
  79.                                                               /* 2@P2D */
  80.                                                               /* 2@P1D */
  81.                                                                /* @P2D */
  82.                                                               /* 4@P1D */
  83.                                                               /* 3@P2D */
  84.  
  85. /* NOINC */
  86. #ifdef INCL_16
  87. #ifndef INCL_NOXLATE_WIN16
  88.     #define GpiVectorSymbol Gpi16VectorSymbol
  89.     #define GpiOpenMetafile Gpi16OpenMetafile
  90.     #define GpiCloseMetafile Gpi16CloseMetafile
  91.     #define GpiConvPsH Gpi16ConvPsH
  92.     #define GpiMTAssociate Gpi16MTAssociate
  93.     #define GpiMTDisassociate Gpi16MTDisassociate
  94.     #define GpiAccessMetaFile Gpi16AccessMetaFile
  95.     #define GpiResumePlay Gpi16ResumePlay
  96.     #define GpiSuspendPlay Gpi16SuspendPlay
  97.     #define GpiSetDCOwner Gpi16SetDCOwner
  98.     #define GpiSetBitmapOwner Gpi16SetBitmapOwner
  99.     #define GpiSetRegionOwner Gpi16SetRegionOwner
  100.     #define GpiInstallIFIFont Gpi16InstallIFIFont
  101. #endif  /* INCL_NOXLATE_WIN16  */
  102. #endif /* INCL_16 */
  103. /* INC */
  104.  
  105. LONG  APIENTRY GpiVectorSymbol( HPS, HDC, PBYTE );
  106.  
  107. BOOL  APIENTRY GpiOpenMetafile( HDC, PBYTE );
  108.  
  109. HMF   APIENTRY GpiCloseMetafile( HDC );
  110.  
  111. HDC   APIENTRY GpiConvPsH( HPS );
  112.  
  113. BOOL  APIENTRY GpiMTAssociate( HDC );
  114.  
  115. BOOL  APIENTRY GpiMTDisassociate( HDC );
  116.  
  117. BOOL  APIENTRY GpiAccessMetaFile( HMF );
  118.  
  119. BOOL  APIENTRY GpiResumePlay( HPS );
  120.  
  121. BOOL  APIENTRY GpiSuspendPlay( HPS );
  122.  
  123. BOOL  APIENTRY GpiSetDCOwner( HDC, ULONG );                   /* @D2A*/
  124.  
  125. BOOL  APIENTRY GpiSetBitmapOwner( HPS, HBITMAP, ULONG );      /* @D2A*/
  126.  
  127. BOOL  APIENTRY GpiSetRegionOwner( HPS, HRGN, ULONG );         /* @D2A*/
  128.  
  129. LONG  APIENTRY GpiInstallIFIFont ( ULONG, PSZ, PSZ, PSZ );
  130.  
  131. #ifdef INCL_32
  132.    //@bidi
  133.    //
  134.    // For use in GpiSet/QueryAttrs.
  135.    // This is the value that sets/queries the BidiAttr field
  136.    // in the DC structure.
  137.    //
  138.    #define PRIM_BIDIATTR   65
  139.  
  140.    #ifdef INCL_GPIP_NLSEX
  141.  
  142.       /* Definition for flNlsProcess.  */
  143.       #define GNLS_PROCESS_BIDI      0x00000001
  144.       #define GNLS_PROCESS_HEBREW    0x00000002
  145.       #define GNLS_PROCESS_ARABIC    0x00000004
  146.  
  147.       /* structure for extended NLS */
  148.       typedef struct _GNLSEX {  /* gnlsex */
  149.            ULONG   flNlsProcess;      //leave at beginning of struc for performance
  150.            ULONG   ulCodepageOverride;
  151.            PULONG  pProcess_BidiAttr;
  152.            PFN     pfnBidiConvertString;
  153.            ULONG   ulCodepageOverrideEBCDIC;          //@Ebcdic
  154.            ULONG   ulReserved;
  155.       }  GNLSEX ;
  156.       typedef GNLSEX *PGNLSEX;
  157.    #endif //incl_GpiNlsEx
  158.  
  159.    //@bidi end
  160. #endif
  161.  
  162. #ifdef INCL_GPIDISPPRF
  163.    /* structures for Disp Profile Functions */
  164.    typedef struct _DSPINFO {  /* dspnfo */
  165.       PSZ   pszDriverName;
  166.       ULONG cchDriverName;
  167.       PSZ   pszDesc;
  168.       ULONG cchDesc;
  169.       PSZ   pszFileName;
  170.       ULONG cchFileName;
  171.       PSZ   pszOptionalParameters;
  172.       ULONG cchOptionalParameters;
  173.    } DSPINFO;
  174.    typedef DSPINFO FAR *PDSPINFO;
  175.  
  176.    typedef struct _SCREENRESCOUNT {  /* scrcnt */
  177.       ULONG maxcount;
  178.       ULONG count;
  179.       ULONG res_struct_length;
  180.    } SCREENRESCOUNT;
  181.    typedef SCREENRESCOUNT FAR *PSCREENRESCOUNT;
  182.  
  183.    typedef struct _SCREENRESOLUTION { /* scrres */
  184.       ULONG width;
  185.       ULONG height;
  186.       ULONG colors;
  187.       ULONG planes;
  188.       ULONG floptions;
  189.    } SCREENRESOLUTION;
  190.    typedef SCREENRESOLUTION FAR *PSCREENRESOLUTION;
  191.  
  192.    #define DSP_DELETE_DRIVER                  1
  193.    #define DSP_OPT_PARMS_PRESENT              2
  194.    #define DSP_QUERY_OPT_PARMS                2
  195.    #define DSP_SET_DEFAULT_DRIVER             4
  196.    #define DSP_QUERY_DEFAULT_DRIVER           4
  197.    #define DSP_SET_INSTALL_ON_IPL             8
  198.    #define DSP_QUERY_INSTALL_ON_IPL           8
  199.    #define DSP_SET_CURRENT_DRIVER            16
  200.    #define DSP_QUERY_CURRENT_DRIVER          16
  201.    #define DSP_SET_DEFAULT_RESOLUTION        32
  202.    #define DSP_RESOLUTION_OBTAINABLE         64
  203.    #define DSP_RESOLUTION_DEFAULT           128
  204.    #define DSP_FILENAME_PRESENT             256
  205.    #define DSP_QUERY_FILENAME               256
  206.    #define DSP_DESC_PRESENT                 512
  207.    #define DSP_QUERY_DESC                   512
  208.  
  209.    #ifndef INCL_DDIDEFS
  210.  
  211.       #ifdef INCL_16
  212.          /* NOINC */
  213.          #ifndef INCL_NOXLATE_WIN16
  214.             #define DspSetDriverInfo             Dsp16SetDriverInfo
  215.             #define DspQueryDriverInfo           Dsp16QueryDriverInfo
  216.             #define DspQueryDriverNames          Dsp16QueryDriverNames
  217.             #define DspDefaultResolution         Dsp16DefaultResolution
  218.             #define DevQueryDisplayResolutions   Dev16QueryDisplayResolutions
  219.             #define DspInitSystemDriverName      Dsp16InitSystemDriverName
  220.          #endif
  221.          /* INC */
  222.       #endif /* INCL_16 */
  223.  
  224.       /*** Display Driver functions */
  225.       BOOL  APIENTRY DspSetDriverInfo(PDSPINFO pDSPInfo,
  226.                                       ULONG flOptions);
  227.  
  228.       ULONG APIENTRY DspQueryDriverInfo(PDSPINFO pDSPInfo,
  229.                                         ULONG flOptions);
  230.  
  231.       ULONG APIENTRY DspQueryDriverNames(PVOID pBuffer,
  232.                                          ULONG ulCount);
  233.  
  234.       BOOL  APIENTRY DspDefaultResolution(PVOID pScreenResolution,
  235.                                           PULONG pcbScreenResolution,
  236.                                           ULONG flOptions);
  237.  
  238.       ULONG APIENTRY DevQueryDisplayResolutions(PSZ pszDriverName,
  239.                                                 PVOID pBuf,
  240.                                                 PULONG pcbBuf);
  241.  
  242.       BOOL  APIENTRY DspInitSystemDriverName(PSZ pszDriverFileName,
  243.                                              ULONG ccbDriverFileName );
  244.    #endif /* no INCL_DDIDEFS */
  245. #endif /* non-common GPIDISPPRF */
  246.  
  247. /* NOINC */
  248. #ifdef __IBMC__
  249.    #pragma checkout( suspend )
  250.       #ifndef __CHKHDR__
  251.          #pragma checkout( resume )
  252.       #endif
  253.    #pragma checkout( resume )
  254. #endif
  255. /* INC */
  256.  
  257. /**************************** end of file **********************************/
  258.