home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: Graphics / Graphics.zip / os2apipm.zip / OS2API / OS2-RES.ADS < prev    next >
Text File  |  1996-07-18  |  6KB  |  97 lines

  1.  
  2. -- ╔═══════════════════════════════════════════════════════════════════╗
  3. -- ║       D E S I G N   E N G I N E R I N G              ║D║S║        ║
  4. -- ║            S O F T W A R E                           ╚═╩═╝        ║
  5. -- ║                                                                   ║
  6. -- ║        Package  SYSTEM.RES                                        ║
  7. -- ║                                                                   ║
  8. -- ║        Author :  Leonid Dulman     1995 , 1996                    ║
  9. -- ║                                                                   ║
  10. -- ║             GNU ADA RUNTIME LIBRARY (GNARL) COMPONENTS            ║
  11. -- ║                                                                   ║
  12. -- ║               Resource  part of os/2 api functions                ║
  13. -- ║                                                                   ║
  14. -- ╚═══════════════════════════════════════════════════════════════════╝
  15.  
  16.  
  17. with Interfaces.C;         use Interfaces.C;
  18. with Interfaces.C.Strings; use Interfaces.C.Strings;
  19.  
  20. package Os2.Res  is
  21. pragma Preelaborate (Res);
  22.  
  23.    --** Resource support --
  24.  
  25.    -- Predefined resource types --
  26.  
  27.  RT_POINTER     :constant Long:=   1; -- mouse pointer shape
  28.  RT_BITMAP      :constant Long:=   2; -- bitmap
  29.  RT_MENU        :constant Long:=   3; -- menu template
  30.  RT_DIALOG      :constant Long:=   4; -- dialog template
  31.  RT_STRING      :constant Long:=   5; -- string tables
  32.  RT_FONTDIR     :constant Long:=   6; -- font directory
  33.  RT_FONT        :constant Long:=   7; -- font
  34.  RT_ACCELTABLE  :constant Long:=   8; -- accelerator tables
  35.  RT_RCDATA      :constant Long:=   9; -- binary data
  36.  RT_MESSAGE     :constant Long:=  10; -- error msg tables
  37.  RT_DLGINCLUDE  :constant Long:=  11; -- dialog include file name
  38.  RT_VKEYTBL     :constant Long:=  12; -- key to vkey tables
  39.  RT_KEYTBL      :constant Long:=  13; -- key to UGL tables
  40.  RT_CHARTBL     :constant Long:=  14; -- glyph to character tables
  41.  RT_DISPLAYINFO :constant Long:=  15; -- screen display information
  42.  RT_FKASHORT    :constant Long:=  16; -- function key area short form
  43.  RT_FKALONG     :constant Long:=  17; -- function key area long form
  44.  RT_HELPTABLE   :constant Long:=  18; -- Help table for Cary Help manager
  45.  RT_HELPSUBTABLE:constant Long:=  19; -- Help subtable for Cary Help manager
  46.  RT_FDDIR       :constant Long:=  20; -- DBCS uniq/font driver directory
  47.  RT_FD          :constant Long:=  21; -- DBCS uniq/font driver
  48.  RT_MAX         :constant Long:=  22; -- 1st unused Resource Type
  49.  -- RF_ORDINALID   :constant Long:= 16#80000000#; ?? -- ordinal id flag in resource table
  50.  
  51. --      DosGetResource2 DosGetResource
  52.  
  53. function   DosGetResource(hmod  :HMODULE ;
  54.                           idType:ULONG   ;
  55.                           idName:ULONG   ;
  56.                           ppb   :PPVOID  )return apiret;
  57. pragma Import(c,DosGetResource, Link_name=>"_DosGetResource");
  58.  
  59. function   DosFreeResource(pb:PVOID )return apiret;
  60. pragma Import(c,DosFreeResource, Link_name=>"_DosFreeResource");
  61.  
  62. function   DosQueryResourceSize(hmod   :HMODULE ;
  63.                                 idt    :ULONG   ;
  64.                                 idn    :ULONG   ;
  65.                                 pulsize:PULONG  )return apiret;
  66. pragma Import(c,DosQueryResourceSize, Link_name=>"_DosQueryResourceSize");
  67.  
  68.        --** Resource support --
  69.        -- Predefined resource types --
  70. --    ╔═══════════════════════════════════════════════════════════════════════════════╗
  71. --    ║ RT_POINTER      1   -- mouse pointer shape --                          ║
  72. --    ║ RT_BITMAP       2   -- bitmap --                                       ║
  73. --    ║ RT_MENU         3   -- menu template --                                ║
  74. --    ║ RT_DIALOG       4   -- dialog template --                              ║
  75. --    ║ RT_STRING       5   -- string tables --                                ║
  76. --    ║ RT_FONTDIR      6   -- font directory --                               ║
  77. --    ║ RT_FONT         7   -- font --                                         ║
  78. --    ║ RT_ACCELTABLE   8   -- accelerator tables --                           ║
  79. --    ║ RT_RCDATA       9   -- binary data --                                  ║
  80. --    ║ RT_MESSAGE      10  -- error msg     tables --                         ║
  81. --    ║ RT_DLGINCLUDE   11  -- dialog include file name --                     ║
  82. --    ║ RT_VKEYTBL      12  -- key to vkey tables --                           ║
  83. --    ║ RT_KEYTBL       13  -- key to UGL tables --                            ║
  84. --    ║ RT_CHARTBL      14  -- glyph to character tables --                    ║
  85. --    ║ RT_DISPLAYINFO  15  -- screen display information --                   ║
  86. --    ║ RT_FKASHORT     16  -- function key area short form --                 ║
  87. --    ║ RT_FKALONG      17  -- function key area long form --                  ║
  88. --    ║ RT_HELPTABLE    18  -- Help table for Cary Help manager --             ║
  89. --    ║ RT_HELPSUBTABLE 19  -- Help subtable for Cary Help manager --          ║
  90. --    ║ RT_FDDIR        20  -- DBCS uniq/font driver directory --              ║
  91. --    ║ RT_FD           21  -- DBCS uniq/font driver --                        ║
  92. --    ║ RT_MAX          22  -- 1st unused Resource Type --                     ║
  93. --    ║ RF_ORDINALID    0x80000000L     -- ordinal id flag in resource table --║
  94. --    ╚═══════════════════════════════════════════════════════════════════════════════╝
  95. --
  96. end Os2.Res;
  97.