home *** CD-ROM | disk | FTP | other *** search
/ BUG 4 / BUGCD1997_05.BIN / aplic / clip4win / clip4win.exe / C4W30E.HUF / INCLUDE / WINDOWS.CH < prev    next >
Text File  |  1995-11-24  |  45KB  |  1,560 lines

  1. ////////////////////
  2. //
  3. //    windows.ch
  4. //
  5. //    Written by:    John M. Skelton,  1992.
  6. //
  7. //    Copyright (C) 1992 Skelton Software, Kendal Cottage, Hillam, Leeds, UK.
  8. //    All Rights Reserved.
  9. //
  10. ////////////////////
  11.  
  12.  
  13. // Borland Resource Workshop (BRW) already knows about Windows definitions,
  14. // but not about special Clip-4-Win ones.  There don't seem to be any
  15. // that are needed, so here's a quick way to keep BRW happy...
  16.  
  17. #ifdef    WORKSHOP_INVOKED
  18.   #ifndef    C4W_WINDOWS_CH
  19.   #define    C4W_WINDOWS_CH    C_4_W
  20.   #endif    // C4W_WINDOWS_CH
  21. #endif    // WORKSHOP_INVOKED
  22.  
  23.  
  24. #ifndef    C4W_WINDOWS_CH
  25. #define    C4W_WINDOWS_CH
  26.  
  27. #define MAKEINTRESOURCE(i)  (i)
  28.  
  29.  
  30. #ifdef    WIN_WANT_ALL
  31. // Low system memory notification message
  32. #define WM_COMPACTING 65    /* 0x0041 */
  33.  
  34. #define WM_WININICHANGE 26    /* 0x001A */
  35.  
  36. #define WM_SYSCOLORCHANGE 21    /* 0x0015 */
  37.  
  38. /* Palette window messages */
  39. #define WM_QUERYNEWPALETTE 783    /* 0x030F */
  40. #define WM_PALETTEISCHANGING 784    /* 0x0310 */
  41. #define WM_PALETTECHANGED 785    /* 0x0311 */
  42.  
  43. #define WM_FONTCHANGE 29    /* 0x001D */
  44.  
  45. /* Spooler status notification message */
  46. #define WM_SPOOLERSTATUS 42    /* 0x002A */
  47.  
  48. #define WM_DEVMODECHANGE 27    /* 0x001B */
  49. #define WM_TIMECHANGE 30    /* 0x001E */
  50. #endif    // WIN_WANT_ALL
  51.  
  52.  
  53. #define WM_NULL 0    /* 0x0000 */
  54.  
  55. /* NOTE: All messages below 1024 are RESERVED by Windows */
  56. #define WM_USER 1024    /* 0x0400 */
  57.  
  58.  
  59. #ifdef    WIN_WANT_ALL
  60. /* PenWindows specific messages */
  61. #define WM_PENWINFIRST 896    /* 0x0380 */
  62. #define WM_PENWINLAST 911    /* 0x038F */
  63.  
  64. /* Coalescing messages */
  65. #define WM_COALESCE_FIRST 912    /* 0x0390 */
  66. #define WM_COALESCE_LAST 927    /* 0x039F */
  67.  
  68. /****** Power management ****************************************************/
  69. #define WM_POWER 72    /* 0x0048 */
  70.  
  71. /****** Application termination *********************************************/
  72.  
  73. #define WM_QUERYENDSESSION 17    /* 0x0011 */
  74. #define WM_ENDSESSION 22    /* 0x0016 */
  75.  
  76. #define WM_QUIT 18    /* 0x0012 */
  77. #endif    // WIN_WANT_ALL
  78.  
  79. #ifdef    WIN_WANT_ALL
  80. #define WM_SYSTEMERROR 23    /* 0x0017 */
  81. #endif    // WIN_WANT_ALL
  82.  
  83. /* Class styles */
  84. #define CS_VREDRAW 1    /* 0x0001 */
  85. #define CS_HREDRAW 2    /* 0x0002 */
  86.  
  87. #define CS_OWNDC 32    /* 0x0020 */
  88. #define CS_CLASSDC 64    /* 0x0040 */
  89. #define CS_PARENTDC 128    /* 0x0080 */
  90.  
  91. #define CS_SAVEBITS 2048    /* 0x0800 */
  92.  
  93. #define CS_DBLCLKS 8    /* 0x0008 */
  94.  
  95. #define CS_BYTEALIGNCLIENT 4096    /* 0x1000 */
  96. #define CS_BYTEALIGNWINDOW 8192    /* 0x2000 */
  97.  
  98. #define CS_NOCLOSE 512    /* 0x0200 */
  99.  
  100. #define CS_KEYCVTWINDOW 4    /* 0x0004 */
  101. #define CS_NOKEYCVT 256    /* 0x0100 */
  102.  
  103. #define CS_GLOBALCLASS 16384    /* 0x4000 */
  104.  
  105. /* Window Styles */
  106.  
  107. /* Basic window types */
  108. #define WS_OVERLAPPED    0        /* 0x00000000L */
  109. #define WS_POPUP    2147483648    /* 0x80000000L */
  110. #define WS_CHILD    1073741824    /* 0x40000000L */
  111.  
  112. /* Clipping styles */
  113. #define WS_CLIPSIBLINGS 67108864    /* 0x04000000L */
  114. #define WS_CLIPCHILDREN 33554432    /* 0x02000000L */
  115.  
  116. /* Generic window states */
  117. #define WS_VISIBLE    268435456    /* 0x10000000L */
  118. #define WS_DISABLED    134217728    /* 0x08000000L */
  119.  
  120. /* Main window states */
  121. #define WS_MINIMIZE    536870912    /* 0x20000000L */
  122. #define WS_MAXIMIZE    16777216    /* 0x01000000L */
  123.  
  124. /* Main window styles */
  125. #define WS_CAPTION 12582912    /* 0x00C00000L */ /* WS_BORDER | WS_DLGFRAME */
  126. #define WS_BORDER 8388608    /* 0x00800000L */
  127. #define WS_DLGFRAME 4194304    /* 0x00400000L */
  128. #define WS_VSCROLL 2097152    /* 0x00200000L */
  129. #define WS_HSCROLL 1048576    /* 0x00100000L */
  130. #define WS_SYSMENU 524288    /* 0x00080000L */
  131. #define WS_THICKFRAME 262144    /* 0x00040000L */
  132. #define WS_MINIMIZEBOX 131072    /* 0x00020000L */
  133. #define WS_MAXIMIZEBOX 65536    /* 0x00010000L */
  134.  
  135. /* Control window styles */
  136. #define WS_GROUP 131072        /* 0x00020000L */
  137. #define WS_TABSTOP 65536    /* 0x00010000L */
  138.  
  139. /* Common Window Styles */
  140. #define WS_OVERLAPPEDWINDOW (WS_OVERLAPPED + WS_CAPTION + WS_SYSMENU + WS_THICKFRAME + WS_MINIMIZEBOX + WS_MAXIMIZEBOX)
  141. #define WS_POPUPWINDOW        (WS_POPUP + WS_BORDER + WS_SYSMENU)
  142. #define WS_CHILDWINDOW        (WS_CHILD)
  143.  
  144. #ifdef    WIN_WANT_ALL
  145. /* Extended Window Styles */
  146. #define WS_EX_DLGMODALFRAME 1    /* 0x00000001L */
  147. #define WS_EX_NOPARENTNOTIFY 4    /* 0x00000004L */
  148.  
  149. #define WS_EX_TOPMOST 8        /* 0x00000008L */
  150. #define WS_EX_ACCEPTFILES 16    /* 0x00000010L */
  151. #define WS_EX_TRANSPARENT 32    /* 0x00000020L */
  152.  
  153. /* Obsolete style names */
  154. #define WS_TILED        WS_OVERLAPPED
  155. #define WS_ICONIC        WS_MINIMIZE
  156. #define WS_SIZEBOX        WS_THICKFRAME
  157. #define WS_TILEDWINDOW        WS_OVERLAPPEDWINDOW
  158. #endif    // WIN_WANT_ALL
  159.  
  160.  
  161. #define WM_CREATE 1        /* 0x0001 */
  162. #ifdef    WIN_WANT_ALL
  163. #define WM_DESTROY 2        /* 0x0002 */
  164. #endif    // WIN_WANT_ALL
  165.  
  166. #ifdef    WIN_WANT_ALL
  167. #define WM_NCCREATE 129        /* 0x0081 */
  168. #define WM_NCDESTROY 130    /* 0x0082 */
  169.  
  170. /* Obsolete ShowWindow() command names */
  171.  
  172. #define WM_SHOWWINDOW 24    /* 0x0018 */
  173.  
  174. /* Obsolete constant names */
  175.  
  176. #define WM_SETREDRAW 11        /* 0x000B */
  177. #endif    // WIN_WANT_ALL
  178.  
  179. /* Enabled state */
  180.  
  181. #ifdef    WIN_WANT_ALL
  182. #define WM_ENABLE 10    /* 0x000A */
  183.  
  184. /* Window text */
  185.  
  186. #define WM_SETTEXT 12    /* 0x000C */
  187. #define WM_GETTEXT 13    /* 0x000D */
  188. #define WM_GETTEXTLENGTH 14    /* 0x000E */
  189. #endif    // WIN_WANT_ALL
  190.  
  191. #ifdef    WIN_WANT_ALL
  192. #define WM_WINDOWPOSCHANGING 70    /* 0x0046 */
  193. #define WM_WINDOWPOSCHANGED 71    /* 0x0047 */
  194.  
  195. /* WM_WINDOWPOSCHANGING/CHANGED struct pointed to by lParam */
  196.  
  197. #define WM_MOVE 3    /* 0x0003 */
  198. #define WM_SIZE 5    /* 0x0005 */
  199.  
  200. // WM_SIZE message nwParam values:
  201. #define SIZE_RESTORED    0
  202. #define SIZE_MINIMIZED    1
  203. #define SIZE_MAXIMIZED    2
  204. #define SIZE_MAXSHOW    3
  205. #define SIZE_MAXHIDE    4
  206.  
  207. #endif    // WIN_WANT_ALL
  208.  
  209.  
  210. #ifdef    WIN_WANT_ALL
  211. #define WM_QUERYOPEN 19    /* 0x0013 */
  212. #endif    // WIN_WANT_ALL
  213.  
  214. #define WM_CLOSE 16    /* 0x0010 */
  215.  
  216. #ifdef    WIN_WANT_ALL
  217. /* Struct pointed to by WM_GETMINMAXINFO lParam */
  218. #define WM_GETMINMAXINFO 36    /* 0x0024 */
  219. #endif    // WIN_WANT_ALL
  220.  
  221. #define WM_PAINT 15    /* 0x000F */
  222. #ifdef    WIN_WANT_ALL
  223. #define WM_ERASEBKGND 20    /* 0x0014 */
  224. #define WM_ICONERASEBKGND 39    /* 0x0027 */
  225. #endif    // WIN_WANT_ALL
  226.  
  227.  
  228. #ifdef    WIN_WANT_ALL
  229. #define WM_NCPAINT 133    /* 0x0085 */
  230.  
  231. #define WM_NCCALCSIZE 131    /* 0x0083 */
  232.  
  233. #define WM_NCHITTEST 132    /* 0x0084 */
  234. #endif    // WIN_WANT_ALL
  235.  
  236. // Drag-and-drop support:
  237. #ifdef    WIN_WANT_ALL
  238. #define WM_QUERYDRAGICON 55    /* 0x0037 */
  239. #define WM_DROPFILES 563    /* 0x0233 */
  240. #endif    // WIN_WANT_ALL
  241.  
  242. #ifdef    WIN_WANT_ALL
  243.  
  244. /* WM_ACTIVATE state values */
  245.  
  246. #define WM_ACTIVATE 6    /* 0x0006 */
  247. #define WM_ACTIVATEAPP 28    /* 0x001C */
  248. #define WM_NCACTIVATE 134    /* 0x0086 */
  249.  
  250.  
  251. #define WM_SETFOCUS 7    /* 0x0007 */
  252. #define WM_KILLFOCUS 8    /* 0x0008 */
  253.  
  254. #define WM_KEYDOWN 256    /* 0x0100 */
  255. #define WM_KEYUP 257    /* 0x0101 */
  256.  
  257. #define WM_CHAR 258    /* 0x0102 */
  258. #define WM_DEADCHAR 259    /* 0x0103 */
  259.  
  260. #define WM_SYSKEYDOWN 260    /* 0x0104 */
  261. #define WM_SYSKEYUP 261    /* 0x0105 */
  262.  
  263. #define WM_SYSCHAR 262    /* 0x0106 */
  264. #define WM_SYSDEADCHAR 263    /* 0x0107 */
  265.  
  266.  
  267. /* Keyboard message range */
  268. #define WM_KEYFIRST 256    /* 0x0100 */
  269. #define WM_KEYLAST 264    /* 0x0108 */
  270.  
  271. /* WM_KEYUP/DOWN/CHAR HIWORD(lParam) flags */
  272.  
  273. /* Virtual key codes */
  274.  
  275. /* VK_A thru VK_Z are the same as their ASCII equivalents: 'A' thru 'Z' */
  276. /* VK_0 thru VK_9 are the same as their ASCII equivalents: '0' thru '0' */
  277.  
  278. /* Mouse input messages */
  279. #define WM_MOUSEMOVE 512    /* 0x0200 */
  280. #define WM_LBUTTONDOWN 513    /* 0x0201 */
  281. #define WM_LBUTTONUP 514    /* 0x0202 */
  282. #define WM_LBUTTONDBLCLK 515    /* 0x0203 */
  283. #define WM_RBUTTONDOWN 516    /* 0x0204 */
  284. #define WM_RBUTTONUP 517    /* 0x0205 */
  285. #define WM_RBUTTONDBLCLK 518    /* 0x0206 */
  286. #define WM_MBUTTONDOWN 519    /* 0x0207 */
  287. #define WM_MBUTTONUP 520    /* 0x0208 */
  288. #define WM_MBUTTONDBLCLK 521    /* 0x0209 */
  289.  
  290. /* Mouse input message range */
  291. #define WM_MOUSEFIRST 512    /* 0x0200 */
  292. #define WM_MOUSELAST 521    /* 0x0209 */
  293.  
  294. #endif    // WIN_WANT_ALL
  295.  
  296. /* Non-client mouse messages */
  297. #ifdef    WIN_WANT_ALL
  298. #define WM_NCMOUSEMOVE 160    /* 0x00A0 */
  299. #define WM_NCLBUTTONDOWN 161    /* 0x00A1 */
  300. #define WM_NCLBUTTONUP 162    /* 0x00A2 */
  301. #define WM_NCLBUTTONDBLCLK 163    /* 0x00A3 */
  302. #define WM_NCRBUTTONDOWN 164    /* 0x00A4 */
  303. #define WM_NCRBUTTONUP 165    /* 0x00A5 */
  304. #define WM_NCRBUTTONDBLCLK 166    /* 0x00A6 */
  305. #define WM_NCMBUTTONDOWN 167    /* 0x00A7 */
  306. #define WM_NCMBUTTONUP 168    /* 0x00A8 */
  307. #define WM_NCMBUTTONDBLCLK 169    /* 0x00A9 */
  308. #endif    // WIN_WANT_ALL
  309.  
  310. #ifdef    WIN_WANT_ALL
  311.  
  312. // Mouse click activation support
  313. #define WM_MOUSEACTIVATE 33    /* 0x0021 */
  314.  
  315. // Mode control
  316. #define WM_CANCELMODE 31    /* 0x001F */
  317.  
  318. #endif    // WIN_WANT_ALL
  319.  
  320. // Timer support
  321. #define WM_TIMER 275    /* 0x0113 */
  322.  
  323. #ifdef    WIN_WANT_ALL
  324.  
  325. /* Menu messages */
  326. #define WM_INITMENU 278    /* 0x0116 */
  327. #define WM_INITMENUPOPUP 279    /* 0x0117 */
  328.  
  329. #define WM_MENUSELECT 287    /* 0x011F */
  330. #define WM_MENUCHAR 288    /* 0x0120 */
  331.  
  332. /* Menu and control command messages */
  333. #define WM_COMMAND 273    /* 0x0111 */
  334.  
  335. // Scroll bar support
  336. #define WM_HSCROLL 276    /* 0x0114 */
  337. #define WM_VSCROLL 277    /* 0x0115 */
  338.  
  339. // Standard cursor resource ID's
  340. #define WM_SETCURSOR 32    /* 0x0020 */
  341.  
  342. // WM_SYSCOMMAND support
  343. #define WM_SYSCOMMAND 274    /* 0x0112 */
  344. #endif    // WIN_WANT_ALL
  345.  
  346. // MDI messages:
  347. #ifdef    WIN_WANT_ALL
  348. #define WM_MDICREATE 544    /* 0x0220 */
  349. #define WM_MDIDESTROY 545    /* 0x0221 */
  350. #define WM_MDIACTIVATE 546    /* 0x0222 */
  351. #define WM_MDIRESTORE 547    /* 0x0223 */
  352. #define WM_MDINEXT 548    /* 0x0224 */
  353. #define WM_MDIMAXIMIZE 549    /* 0x0225 */
  354. #define WM_MDITILE 550    /* 0x0226 */
  355. #define WM_MDICASCADE 551    /* 0x0227 */
  356. #define WM_MDIICONARRANGE 552    /* 0x0228 */
  357. #define WM_MDIGETACTIVE 553    /* 0x0229 */
  358. #define WM_MDISETMENU 560    /* 0x0230 */
  359. #endif    // WIN_WANT_ALL
  360.  
  361. #define WM_CHILDACTIVATE 34    /* 0x0022 */
  362.  
  363. /* Dialog messages */
  364. #define DM_GETDEFID        (WM_USER+0)
  365. #define DM_SETDEFID        (WM_USER+1)
  366.  
  367. /* Dialog notification messages */
  368. #define WM_INITDIALOG 272    /* 0x0110 */
  369. #define WM_NEXTDLGCTL 40    /* 0x0028 */
  370.  
  371. #define WM_PARENTNOTIFY 528    /* 0x0210 */
  372.  
  373. #define WM_ENTERIDLE 289    /* 0x0121 */
  374.  
  375. #define WM_GETDLGCODE 135    /* 0x0087 */
  376.  
  377. #ifdef    WIN_WANT_DLG_CODES
  378. // dialog codes:
  379. #define DLGC_WANTARROWS        1    // 0x0001
  380. #define DLGC_WANTTAB        2    // 0x0002
  381. #define DLGC_WANTALLKEYS    4    // 0x0004
  382. #define DLGC_WANTMESSAGE    4    // 0x0004
  383. #define DLGC_HASSETSEL        8    // 0x0008
  384. #define DLGC_DEFPUSHBUTTON    16    // 0x0010
  385. #define DLGC_UNDEFPUSHBUTTON    32    // 0x0020
  386. #define DLGC_RADIOBUTTON    64    // 0x0040
  387. #define DLGC_WANTCHARS        128    // 0x0080
  388. #define DLGC_STATIC        256    // 0x0100
  389. #define DLGC_BUTTON        8192    // 0x2000
  390. #endif    // WIN_WANT_DLG_CODES
  391.  
  392. #define WM_CTLCOLOR 25    /* 0x0019 */
  393.  
  394. #ifdef    WIN_WANT_CTL_CODES
  395. // WM_CTLCOLOR control codes:
  396. #define CTLCOLOR_MSGBOX        0
  397. #define CTLCOLOR_EDIT        1
  398. #define CTLCOLOR_LISTBOX    2
  399. #define CTLCOLOR_BTN        3
  400. #define CTLCOLOR_DLG        4
  401. #define CTLCOLOR_SCROLLBAR    5
  402. #define CTLCOLOR_STATIC        6
  403. #endif    // WIN_WANT_CTL_CODES
  404.  
  405. #define WM_SETFONT 48    /* 0x0030 */
  406. #define WM_GETFONT 49    /* 0x0031 */
  407.  
  408. #define WM_DRAWITEM 43    /* 0x002B */
  409.  
  410. // for ODT_*, ODA_*, ODS_* see DRAWITEM.CH
  411.  
  412. #define WM_MEASUREITEM 44    /* 0x002C */
  413.  
  414. #define WM_DELETEITEM 45    /* 0x002D */
  415.  
  416. #define WM_COMPAREITEM 57    /* 0x0039 */
  417.  
  418. // Scroll bar styles:
  419. #define SBS_HORZ            0
  420. #define SBS_VERT            1
  421. #ifdef    WIN_WANT_SBS
  422. #define SBS_TOPALIGN            2
  423. #define SBS_LEFTALIGN            2
  424. #define SBS_BOTTOMALIGN            4
  425. #define SBS_RIGHTALIGN            4
  426. #define SBS_SIZEBOXTOPLEFTALIGN        2
  427. #define SBS_SIZEBOXBOTTOMRIGHTALIGN 4
  428. #define SBS_SIZEBOX            8
  429. #endif    // WIN_WANT_SBS
  430.  
  431. // Edit control messages:
  432. #define EM_GETSEL            (WM_USER+0)
  433. #define EM_SETSEL            (WM_USER+1)
  434. #define EM_GETRECT            (WM_USER+2)
  435. #define EM_SETRECT            (WM_USER+3)
  436. #define EM_SETRECTNP            (WM_USER+4)
  437. #define EM_LINESCROLL            (WM_USER+6)
  438. #define EM_GETMODIFY            (WM_USER+8)
  439. #define EM_SETMODIFY            (WM_USER+9)
  440. #define EM_GETLINECOUNT         (WM_USER+10)
  441. #define EM_LINEINDEX            (WM_USER+11)
  442. #define EM_SETHANDLE            (WM_USER+12)
  443. #define EM_GETHANDLE            (WM_USER+13)
  444. #define EM_LINELENGTH            (WM_USER+17)
  445. #define EM_REPLACESEL            (WM_USER+18)
  446. //#define EM_SETFONT              (WM_USER+19)    /* NOT IMPLEMENTED: use WM_SETFONT */
  447. #define EM_GETLINE            (WM_USER+20)
  448. #define EM_LIMITTEXT            (WM_USER+21)
  449. #define EM_CANUNDO            (WM_USER+22)
  450. #define EM_UNDO             (WM_USER+23)
  451. #define EM_FMTLINES            (WM_USER+24)
  452. #define EM_LINEFROMCHAR         (WM_USER+25)
  453. //#define EM_SETWORDBREAK         (WM_USER+26)    /* NOT IMPLEMENTED: use EM_SETWORDBREAK */
  454. #define EM_SETTABSTOPS            (WM_USER+27)
  455. #define EM_SETPASSWORDCHAR      (WM_USER+28)
  456. #define EM_EMPTYUNDOBUFFER      (WM_USER+29)
  457. #define EM_GETFIRSTVISIBLELINE    (WM_USER+30)
  458. #define EM_SETREADONLY            (WM_USER+31)
  459. #define EM_SETWORDBREAKPROC     (WM_USER+32)
  460. #define EM_GETWORDBREAKPROC     (WM_USER+33)
  461. #define EM_GETPASSWORDCHAR      (WM_USER+34)
  462.  
  463. // Edit control notification codes:
  464. #ifdef WIN_WANT_EN
  465. #define EN_SETFOCUS    256    // 0x0100
  466. #define EN_KILLFOCUS    512    // 0x0200
  467. #define EN_CHANGE    768    // 0x0300
  468. #define EN_UPDATE    1024    // 0x0400
  469. #define EN_ERRSPACE    1280    // 0x0500
  470. #define EN_MAXTEXT    1281    // 0x0501
  471. #define EN_HSCROLL    1537    // 0x0601
  472. #define EN_VSCROLL    1538    // 0x0602
  473. #endif // WIN_WANT_EN
  474.  
  475. // Listbox styles:
  476. #ifdef WIN_WANT_LBS
  477. #define LBS_NOTIFY        1    // 0x0001L
  478. #define LBS_SORT        2    // 0x0002L
  479. #define LBS_NOREDRAW        4    // 0x0004L
  480. #define LBS_MULTIPLESEL        8    // 0x0008L
  481. #define LBS_OWNERDRAWFIXED    16    // 0x0010L
  482. #define LBS_OWNERDRAWVARIABLE    32    // 0x0020L
  483. #define LBS_HASSTRINGS        64    // 0x0040L
  484. #define LBS_USETABSTOPS        128    // 0x0080L
  485. #define LBS_NOINTEGRALHEIGHT    256    // 0x0100L
  486. #define LBS_MULTICOLUMN        512    // 0x0200L
  487. #define LBS_WANTKEYBOARDINPUT    1024    // 0x0400L
  488. #define LBS_EXTENDEDSEL        2048    // 0x0800L
  489. // Win 3.1:
  490. #define LBS_DISABLENOSCROLL    4096    // 0x1000L
  491. // end of 3.1
  492. #define LBS_STANDARD          (LBS_NOTIFY + LBS_SORT + WS_VSCROLL + WS_BORDER)
  493. #endif // WIN_WANT_LBS
  494.  
  495. // Listbox messages:
  496. #ifdef WIN_WANT_LB
  497. #define LB_ADDSTRING        (WM_USER+1)
  498. #define LB_INSERTSTRING        (WM_USER+2)
  499. #define LB_DELETESTRING        (WM_USER+3)
  500. #define LB_RESETCONTENT        (WM_USER+5)
  501. #define LB_SETSEL        (WM_USER+6)
  502. #define LB_SETCURSEL        (WM_USER+7)
  503. #define LB_GETSEL        (WM_USER+8)
  504. #define LB_GETCURSEL        (WM_USER+9)
  505. #define LB_GETTEXT        (WM_USER+10)
  506. #define LB_GETTEXTLEN        (WM_USER+11)
  507. #define LB_GETCOUNT        (WM_USER+12)
  508. #define LB_SELECTSTRING        (WM_USER+13)
  509. #define LB_DIR            (WM_USER+14)
  510. #define LB_GETTOPINDEX        (WM_USER+15)
  511. #define LB_FINDSTRING        (WM_USER+16)
  512. #define LB_GETSELCOUNT        (WM_USER+17)
  513. #define LB_GETSELITEMS        (WM_USER+18)
  514. #define LB_SETTABSTOPS        (WM_USER+19)
  515. #define LB_GETHORIZONTALEXTENT    (WM_USER+20)
  516. #define LB_SETHORIZONTALEXTENT    (WM_USER+21)
  517. #define LB_SETCOLUMNWIDTH    (WM_USER+22)
  518. #define LB_SETTOPINDEX        (WM_USER+24)
  519. #define LB_GETITEMRECT        (WM_USER+25)
  520. #define LB_GETITEMDATA        (WM_USER+26)
  521. #define LB_SETITEMDATA        (WM_USER+27)
  522. #define LB_SELITEMRANGE        (WM_USER+28)
  523. #define LB_SETCARETINDEX    (WM_USER+31)
  524. #define LB_GETCARETINDEX    (WM_USER+32)
  525. #define LB_SETITEMHEIGHT    (WM_USER+33)
  526. #define LB_GETITEMHEIGHT    (WM_USER+34)
  527. #define LB_FINDSTRINGEXACT    (WM_USER+35)
  528.  
  529. // Listbox notification codes:
  530. #define LBN_ERRSPACE    (-2)
  531. #define LBN_SELCHANGE    1
  532. #define LBN_DBLCLK    2
  533. #define LBN_SELCANCEL    3
  534. #define LBN_SETFOCUS    4
  535. #define LBN_KILLFOCUS    5
  536.  
  537. // List box message return values:
  538. #define LB_OKAY     0
  539. #define LB_ERR        (-1)
  540. #define LB_ERRSPACE    (-2)
  541. #endif // WIN_WANT_LB
  542.  
  543. // Listbox notification messages:
  544. #define WM_VKEYTOITEM 46    /* 0x002E */
  545. #define WM_CHARTOITEM 47    /* 0x002F */
  546.  
  547.  
  548. #ifdef WIN_WANT_CB
  549. // ComboBox styles:
  550. #define CBS_SIMPLE        1    // 0x0001
  551. #define CBS_DROPDOWN        2    // 0x0002
  552. #define CBS_DROPDOWNLIST    3    // 0x0003
  553. #define CBS_OWNERDRAWFIXED    16    // 0x0010
  554. #define CBS_OWNERDRAWVARIABLE    32    // 0x0020
  555. #define CBS_AUTOHSCROLL        64    // 0x0040
  556. #define CBS_OEMCONVERT        128    // 0x0080
  557. #define CBS_SORT        256    // 0x0100
  558. #define CBS_HASSTRINGS        512    // 0x0200
  559. #define CBS_NOINTEGRALHEIGHT    1024    // 0x0400
  560. // Win 3.1:
  561. #define CBS_DISABLENOSCROLL    2048    // 0x0800
  562. // end of 3.1
  563.  
  564. // Combo box messages:
  565. #define CB_GETEDITSEL             (WM_USER+0)
  566. #define CB_LIMITTEXT             (WM_USER+1)
  567. #define CB_SETEDITSEL             (WM_USER+2)
  568. #define CB_ADDSTRING             (WM_USER+3)
  569. #define CB_DELETESTRING             (WM_USER+4)
  570. #define CB_DIR                   (WM_USER+5)
  571. #define CB_GETCOUNT             (WM_USER+6)
  572. #define CB_GETCURSEL             (WM_USER+7)
  573. #define CB_GETLBTEXT             (WM_USER+8)
  574. #define CB_GETLBTEXTLEN             (WM_USER+9)
  575. #define CB_INSERTSTRING          (WM_USER+10)
  576. #define CB_RESETCONTENT             (WM_USER+11)
  577. #define CB_FINDSTRING             (WM_USER+12)
  578. #define CB_SELECTSTRING             (WM_USER+13)
  579. #define CB_SETCURSEL             (WM_USER+14)
  580. #define CB_SHOWDROPDOWN          (WM_USER+15)
  581. #define CB_GETITEMDATA           (WM_USER+16)
  582. #define CB_SETITEMDATA           (WM_USER+17)
  583. // Win 3.1:
  584. #define CB_GETDROPPEDCONTROLRECT (WM_USER+18)
  585. #define CB_SETITEMHEIGHT         (WM_USER+19)
  586. #define CB_GETITEMHEIGHT         (WM_USER+20)
  587. #define CB_SETEXTENDEDUI         (WM_USER+21)
  588. #define CB_GETEXTENDEDUI         (WM_USER+22)
  589. #define CB_GETDROPPEDSTATE       (WM_USER+23)
  590. #define CB_FINDSTRINGEXACT       (WM_USER+24)
  591. // end of 3.1
  592.  
  593. // Combo box notification codes:
  594. #define CBN_ERRSPACE        (-1)
  595. #define CBN_SELCHANGE        1
  596. #define CBN_DBLCLK        2
  597. #define CBN_SETFOCUS        3
  598. #define CBN_KILLFOCUS        4
  599. #define CBN_EDITCHANGE      5
  600. #define CBN_EDITUPDATE      6
  601. #define CBN_DROPDOWN        7
  602. // Win 3.1:
  603. #define CBN_CLOSEUP         8
  604. #define CBN_SELENDOK        9
  605. #define CBN_SELENDCANCEL    10
  606. // end of 3.1
  607.  
  608. // Combo box message return values:
  609. #define CB_OKAY     0
  610. #define CB_ERR        (-1)
  611. #define CB_ERRSPACE    (-2)
  612. #endif // WIN_WANT_CB
  613.  
  614.  
  615. #ifdef    WIN_WANT_ALL
  616. #define WM_QUEUESYNC 35    /* 0x0023 */
  617.  
  618. #define WM_COMMNOTIFY 68    /* 0x0044 */
  619. #endif    // WIN_WANT_ALL
  620.  
  621.  
  622. #define MB_OK            0    // 0x0000
  623. #define MB_OKCANCEL        1    // 0x0001
  624. #define MB_ABORTRETRYIGNORE 2    // 0x0002
  625. #define MB_YESNOCANCEL        3    // 0x0003
  626. #define MB_YESNO        4    // 0x0004
  627. #define MB_RETRYCANCEL        5    // 0x0005
  628. #define MB_TYPEMASK        15    // 0x000F
  629.  
  630. #define MB_ICONHAND        16    // 0x0010
  631. #define MB_ICONQUESTION        32    // 0x0020
  632. #define MB_ICONEXCLAMATION  48    // 0x0030
  633. #define MB_ICONASTERISK     64    // 0x0040
  634. #define MB_ICONMASK        240    // 0x00F0
  635.  
  636. #define MB_ICONINFORMATION  MB_ICONASTERISK
  637. #define MB_ICONSTOP         MB_ICONHAND
  638.  
  639. #define MB_DEFBUTTON1        0    // 0x0000
  640. #define MB_DEFBUTTON2        256    // 0x0100
  641. #define MB_DEFBUTTON3        512    // 0x0200
  642. #define MB_DEFMASK        3840 // 0x0F00
  643.  
  644. #define MB_APPLMODAL        0    // 0x0000
  645. #define MB_SYSTEMMODAL        4096 // 0x1000
  646. #define MB_TASKMODAL        8192 // 0x2000
  647.  
  648. #define MB_NOFOCUS        32768 // 0x8000
  649.  
  650.  
  651. #ifdef    WIN_WANT_MF
  652. #define MF_INSERT        0    // 0x0000
  653. #define MF_CHANGE        128    // 0x0080
  654. #define MF_APPEND        256    // 0x0100
  655. #define MF_DELETE        512    // 0x0200
  656. #define MF_REMOVE        4096 // 0x1000
  657.  
  658. /* Menu flags for Add/Check/EnableMenuItem() */
  659. #define MF_BYCOMMAND        0    // 0x0000
  660. #define MF_BYPOSITION        1024 // 0x0400
  661. #endif    // WIN_WANT_MF
  662.  
  663. #define MF_SEPARATOR        2048 // 0x0800
  664.  
  665. #define MF_ENABLED        0    // 0x0000
  666. #define MF_GRAYED        1    // 0x0001
  667. #define MF_DISABLED        2    // 0x0002
  668.  
  669. #define MF_UNCHECKED        0    // 0x0000
  670. #define MF_CHECKED        8    // 0x0008
  671. #define MF_USECHECKBITMAPS  512    // 0x0200
  672.  
  673. #define MF_STRING        0    // 0x0000
  674. #define MF_BITMAP        4    // 0x0004
  675. #ifdef    WIN_WANT_ALL
  676. #define MF_OWNERDRAW        256    // 0x0100
  677. #endif    // WIN_WANT_ALL
  678.  
  679. #define MF_POPUP        16    // 0x0010
  680. #define MF_MENUBARBREAK     32    // 0x0020
  681. #define MF_MENUBREAK        64    // 0x0040
  682.  
  683. #define MF_UNHILITE        0    // 0x0000
  684. #define MF_HILITE        128    // 0x0080
  685.  
  686. #define MF_SYSMENU        8192    // 0x2000
  687. #define MF_HELP         16384    // 0x4000
  688. #define MF_MOUSESELECT        32768    // 0x8000
  689.  
  690.  
  691. #define MF_END            128    // 0x0080  /* Only valid in menu resource templates */
  692.  
  693. // ShowWindow values
  694. #define SW_HIDE            0
  695. #define SW_SHOWNORMAL        1
  696. #define SW_NORMAL        1
  697. #define SW_SHOWMINIMIZED    2
  698. #define SW_SHOWMAXIMIZED    3
  699. #define SW_MAXIMIZE        3
  700. #define SW_SHOWNOACTIVATE   4
  701. #define SW_SHOW            5
  702. #define SW_MINIMIZE        6
  703. #define SW_SHOWMINNOACTIVE  7
  704. #define SW_SHOWNA        8
  705. #define SW_RESTORE          9
  706.  
  707. // CreateWindow/child window
  708. #define CW_USEDEFAULT        32768    // 0x8000
  709.  
  710. /* WM_H/VSCROLL commands */
  711. #define SB_LINEUP        0
  712. #define SB_LINELEFT        0
  713. #define SB_LINEDOWN        1
  714. #define SB_LINERIGHT        1
  715. #define SB_PAGEUP        2
  716. #define SB_PAGELEFT        2
  717. #define SB_PAGEDOWN        3
  718. #define SB_PAGERIGHT        3
  719. #define SB_THUMBPOSITION    4
  720. #define SB_THUMBTRACK        5
  721. #define SB_TOP            6
  722. #define SB_LEFT         6
  723. #define SB_BOTTOM        7
  724. #define SB_RIGHT        7
  725. #define SB_ENDSCROLL        8
  726.  
  727. /* Scroll bar selection constants */
  728. #define SB_HORZ            0
  729. #define SB_VERT            1
  730. #define SB_CTL            2
  731. #define SB_BOTH            3
  732.  
  733. /* Dialog styles */
  734. #define DS_ABSALIGN    1    // 0x01
  735. #define DS_SYSMODAL    2    // 0x02
  736. #define DS_LOCALEDIT    32    // 0x20
  737. #define DS_SETFONT      64    // 0x40
  738. #define DS_MODALFRAME   128    // 0x80
  739. #define DS_NOIDLEMSG    256    // 0x100
  740.  
  741. /* Returned in HIWORD() of DM_GETDEFID result if msg is supported */
  742. #ifdef    WIN_WANT_ALL
  743. #define DC_HASDEFID    21323    // 0x534B
  744. #endif    // WIN_WANT_ALL
  745.  
  746. // dialog button id's:
  747. #define IDOK            1
  748. #define IDCANCEL        2
  749. #define IDABORT         3
  750. #define IDRETRY         4
  751. #define IDIGNORE        5
  752. #define IDYES            6
  753. #define IDNO            7
  754.  
  755. // Button Control Messages:
  756. #define BM_GETCHECK        (WM_USER+0)
  757. #define BM_SETCHECK        (WM_USER+1)
  758. #define BM_GETSTATE        (WM_USER+2)
  759. #define BM_SETSTATE        (WM_USER+3)
  760. #define BM_SETSTYLE        (WM_USER+4)
  761.  
  762. // Button Control Styles:
  763. #define BS_PUSHBUTTON        0    // 0x00000000
  764. #define BS_DEFPUSHBUTTON    1    // 0x00000001
  765. #define BS_CHECKBOX        2    // 0x00000002
  766. #define BS_AUTOCHECKBOX     3    // 0x00000003
  767. #define BS_RADIOBUTTON        4    // 0x00000004
  768. #define BS_3STATE        5    // 0x00000005
  769. #define BS_AUTO3STATE        6    // 0x00000006
  770. #define BS_GROUPBOX        7    // 0x00000007
  771. #define BS_USERBUTTON        8    // 0x00000008
  772. #define BS_AUTORADIOBUTTON    9    // 0x00000009
  773. #ifdef    WIN_WANT_ALL
  774. #define BS_OWNERDRAW        11    // 0x0000000B
  775. #endif    // WIN_WANT_ALL
  776. #define BS_LEFTTEXT        32    // 0x00000020
  777.  
  778. // User Button Notification Codes
  779. #define BN_CLICKED        0
  780. // these are obsolete:
  781. //#define BN_PAINT        1
  782. //#define BN_HILITE        2
  783. //#define BN_UNHILITE        3
  784. //#define BN_DISABLE        4
  785. #define BN_DOUBLECLICKED  5        // only for owner draw (?)
  786.  
  787.  
  788. // typical menu item id's
  789. #ifdef    WIN_WANT_IDM
  790. #define    IDM_NEW        1
  791. #define    IDM_OPEN    2
  792. #define    IDM_SAVE    3
  793. #define    IDM_SAVEAS    4
  794. #define    IDM_EXIT    5
  795. #define    IDM_ABOUT    6
  796. #endif    // WIN_WANT_IDM
  797.  
  798.  
  799. /* Standard icon resource IDs */
  800. #define IDI_APPLICATION     MAKEINTRESOURCE(32512)
  801. #define IDI_HAND        MAKEINTRESOURCE(32513)
  802. #define IDI_QUESTION        MAKEINTRESOURCE(32514)
  803. #define IDI_EXCLAMATION     MAKEINTRESOURCE(32515)
  804. #define IDI_ASTERISK        MAKEINTRESOURCE(32516)
  805.  
  806. /* Standard cursor resource IDs */
  807. #define IDC_ARROW        MAKEINTRESOURCE(32512)
  808. #define IDC_IBEAM        MAKEINTRESOURCE(32513)
  809. #define IDC_WAIT        MAKEINTRESOURCE(32514)
  810. #define IDC_CROSS        MAKEINTRESOURCE(32515)
  811. #define IDC_UPARROW        MAKEINTRESOURCE(32516)
  812. #define IDC_SIZE        MAKEINTRESOURCE(32640)
  813. #define IDC_ICON        MAKEINTRESOURCE(32641)
  814. #define IDC_SIZENWSE        MAKEINTRESOURCE(32642)
  815. #define IDC_SIZENESW        MAKEINTRESOURCE(32643)
  816. #define IDC_SIZEWE        MAKEINTRESOURCE(32644)
  817. #define IDC_SIZENS        MAKEINTRESOURCE(32645)
  818.  
  819. /* GetWindow() constants */
  820. #ifdef    WIN_WANT_ALL
  821. #define GW_HWNDFIRST    0
  822. #define GW_HWNDLAST    1
  823. #define GW_HWNDNEXT    2
  824. #define GW_HWNDPREV    3
  825. #define GW_OWNER    4
  826. #define GW_CHILD    5
  827. #endif    // WIN_WANT_ALL
  828.  
  829. /* Special value for CreateWindow, et al. */
  830. #define HWND_DESKTOP        (0)
  831.  
  832. /* SetWindowPos() hwndInsertAfter field values */
  833. #ifdef    WIN_WANT_ALL
  834. #define HWND_TOP            (0)
  835. #define HWND_BOTTOM        (1)
  836. #define HWND_TOPMOST        (-1)
  837. #define HWND_NOTOPMOST      (-2)
  838. #endif    // WIN_WANT_ALL
  839.  
  840. /* Special HWND value for use with PostMessage() and SendMessage() */
  841. #ifdef    WIN_WANT_ALL
  842. #define HWND_BROADCAST    (-1)
  843. #endif    // WIN_WANT_ALL
  844.  
  845.  
  846. // Color support
  847. #ifndef RC_INVOKED
  848. #xtranslate RGB(<r>,<g>,<b>) => (((<r>) + (<g>)*256) + (<b>)*65536)
  849. #endif
  850.  
  851. #define COLOR_SCROLLBAR           0
  852. #define COLOR_BACKGROUND       1
  853. #define COLOR_ACTIVECAPTION       2
  854. #define COLOR_INACTIVECAPTION       3
  855. #define COLOR_MENU           4
  856. #define COLOR_WINDOW           5
  857. #define COLOR_WINDOWFRAME       6
  858. #define COLOR_MENUTEXT           7
  859. #define COLOR_WINDOWTEXT       8
  860. #define COLOR_CAPTIONTEXT         9
  861. #define COLOR_ACTIVEBORDER      10
  862. #define COLOR_INACTIVEBORDER      11
  863. #define COLOR_APPWORKSPACE      12
  864. #define COLOR_HIGHLIGHT          13
  865. #define COLOR_HIGHLIGHTTEXT      14
  866. #define COLOR_BTNFACE             15
  867. #define COLOR_BTNSHADOW           16
  868. #define COLOR_GRAYTEXT            17
  869. #define COLOR_BTNTEXT          18
  870. #define COLOR_INACTIVECAPTIONTEXT 19
  871. #define COLOR_BTNHIGHLIGHT        20
  872.  
  873. // Pen support
  874.  
  875. /* Pen Styles */
  876. #define PS_SOLID        0
  877. #define PS_DASH             1
  878. #define PS_DOT              2
  879. #define PS_DASHDOT          3
  880. #define PS_DASHDOTDOT       4
  881. #define PS_NULL         5
  882. #define PS_INSIDEFRAME         6
  883.  
  884. // Stock pens for use with GetStockObject()
  885. #define WHITE_PEN        6
  886. #define BLACK_PEN        7
  887. #define NULL_PEN        8
  888.  
  889. // Brush support
  890.  
  891. /* Brush Styles */
  892. #define BS_SOLID        0
  893. #define BS_NULL            1
  894. #define BS_HOLLOW        BS_NULL
  895. #define BS_HATCHED        2
  896. #define BS_PATTERN        3
  897. #define BS_INDEXED        4
  898. #define    BS_DIBPATTERN        5
  899.  
  900. /* Hatch Styles */
  901. #define HS_HORIZONTAL       0
  902. #define HS_VERTICAL         1
  903. #define HS_FDIAGONAL        2
  904. #define HS_BDIAGONAL        3
  905. #define HS_CROSS            4
  906. #define HS_DIAGCROSS        5
  907.  
  908. /* Stock brushes for use with GetStockObject() */
  909. #define WHITE_BRUSH        0
  910. #define LTGRAY_BRUSH        1
  911. #define GRAY_BRUSH        2
  912. #define DKGRAY_BRUSH        3
  913. #define BLACK_BRUSH        4
  914. #define NULL_BRUSH        5
  915. #define HOLLOW_BRUSH        NULL_BRUSH
  916.  
  917. // PolyFill Modes
  918. #define ALTERNATE   1
  919. #define WINDING     2
  920.  
  921. /* GetSystemMetrics() codes */
  922. #ifdef    WIN_WANT_SYSTEM_METRICS
  923. #define SM_CXSCREEN         0
  924. #define SM_CYSCREEN         1
  925. #define SM_CXVSCROLL         2
  926. #define SM_CYHSCROLL         3
  927. #define SM_CYCAPTION         4
  928. #define SM_CXBORDER         5
  929. #define SM_CYBORDER         6
  930. #define SM_CXDLGFRAME         7
  931. #define SM_CYDLGFRAME         8
  932. #define SM_CYVTHUMB         9
  933. #define SM_CXHTHUMB         10
  934. #define SM_CXICON         11
  935. #define SM_CYICON         12
  936. #define SM_CXCURSOR         13
  937. #define SM_CYCURSOR         14
  938. #define SM_CYMENU         15
  939. #define SM_CXFULLSCREEN      16
  940. #define SM_CYFULLSCREEN      17
  941. #define SM_CYKANJIWINDOW     18
  942. #define SM_MOUSEPRESENT      19
  943. #define SM_CYVSCROLL         20
  944. #define SM_CXHSCROLL         21
  945. #define SM_DEBUG         22
  946. #define SM_SWAPBUTTON         23
  947. #define SM_RESERVED1         24
  948. #define SM_RESERVED2         25
  949. #define SM_RESERVED3         26
  950. #define SM_RESERVED4         27
  951. #define SM_CXMIN         28
  952. #define SM_CYMIN         29
  953. #define SM_CXSIZE         30
  954. #define SM_CYSIZE         31
  955. #define SM_CXFRAME         32
  956. #define SM_CYFRAME         33
  957. #define SM_CXMINTRACK         34
  958. #define SM_CYMINTRACK         35
  959.  
  960. // Win 3.1 values:
  961. #define SM_CXDOUBLECLK       36
  962. #define SM_CYDOUBLECLK       37
  963. #define SM_CXICONSPACING     38
  964. #define SM_CYICONSPACING     39
  965. #define SM_MENUDROPALIGNMENT 40
  966. #define SM_PENWINDOWS        41
  967. #define SM_DBCSENABLED       42
  968. #endif    // WIN_WANT_SYSTEM_METRICS
  969.  
  970. #define SM_CMETRICS         43
  971.  
  972. /* System Menu Command Values */
  973. #ifdef    WIN_WANT_ALL
  974. #define SC_SIZE        61440    // 0xF000
  975. #define SC_MOVE        61456    // 0xF010
  976. #define SC_MINIMIZE    61472    // 0xF020
  977. #define SC_MAXIMIZE    61488    // 0xF030
  978. #define SC_NEXTWINDOW    61504    // 0xF040
  979. #define SC_PREVWINDOW    61520    // 0xF050
  980. #define SC_CLOSE    61536    // 0xF060
  981. #define SC_VSCROLL    61552    // 0xF070
  982. #define SC_HSCROLL    61568    // 0xF080
  983. #define SC_MOUSEMENU    61584    // 0xF090
  984. #define SC_KEYMENU    61696    // 0xF100
  985. #define SC_ARRANGE    61712    // 0xF110
  986. #define SC_RESTORE    61728    // 0xF120
  987. #define SC_TASKLIST    61744    // 0xF130
  988. #define SC_SCREENSAVE   61760    // 0xF140
  989. #define SC_HOTKEY       61776    // 0xF150
  990. #endif    // WIN_WANT_ALL
  991.  
  992. // Obsolete names
  993. #ifdef    WIN_WANT_ALL
  994. #define SC_ICON        SC_MINIMIZE
  995. #define SC_ZOOM     SC_MAXIMIZE
  996. #endif    // WIN_WANT_ALL
  997.  
  998. // Pre-defined bitmap numbers
  999. #define OBM_CLOSE        32754
  1000. #define OBM_UPARROW         32753
  1001. #define OBM_DNARROW         32752
  1002. #define OBM_RGARROW         32751
  1003. #define OBM_LFARROW         32750
  1004. #define OBM_REDUCE          32749
  1005. #define OBM_ZOOM            32748
  1006. #define OBM_RESTORE         32747
  1007. #define OBM_REDUCED         32746
  1008. #define OBM_ZOOMD           32745
  1009. #define OBM_RESTORED        32744
  1010. #define OBM_UPARROWD        32743
  1011. #define OBM_DNARROWD        32742
  1012. #define OBM_RGARROWD        32741
  1013. #define OBM_LFARROWD        32740
  1014. #define OBM_MNARROW         32739
  1015. #define OBM_COMBO           32738
  1016. // Win 3.1:
  1017. #define OBM_UPARROWI        32737
  1018. #define OBM_DNARROWI        32736
  1019. #define OBM_RGARROWI        32735
  1020. #define OBM_LFARROWI        32734
  1021. // end of 3.1
  1022. #define OBM_OLD_CLOSE       32767
  1023. #define OBM_SIZE            32766
  1024. #define OBM_OLD_UPARROW     32765
  1025. #define OBM_OLD_DNARROW     32764
  1026. #define OBM_OLD_RGARROW     32763
  1027. #define OBM_OLD_LFARROW     32762
  1028. #define OBM_BTSIZE          32761
  1029. #define OBM_CHECK           32760
  1030. #define OBM_CHECKBOXES      32759
  1031. #define OBM_BTNCORNERS      32758
  1032. #define OBM_OLD_REDUCE      32757
  1033. #define OBM_OLD_ZOOM        32756
  1034. #define OBM_OLD_RESTORE     32755
  1035.  
  1036.  
  1037. // Edit control
  1038.  
  1039. /* Edit control styles */
  1040. #define ES_LEFT     0    // 0x00000000L
  1041. #define ES_CENTER    1    // 0x00000001L
  1042. #define ES_RIGHT    2    // 0x00000002L
  1043. #define ES_MULTILINE    4    // 0x00000004L
  1044. #define ES_UPPERCASE    8    // 0x00000008L
  1045. #define ES_LOWERCASE    16    // 0x00000010L
  1046. #define ES_PASSWORD     32    // 0x00000020L
  1047. #define ES_AUTOVSCROLL    64    // 0x00000040L
  1048. #define ES_AUTOHSCROLL    128    // 0x00000080L
  1049. #define ES_NOHIDESEL    256    // 0x00000100L
  1050. #define ES_OEMCONVERT    1024    // 0x00000400L
  1051. // Win 3.1:
  1052. #define ES_READONLY    2048    // 0x00000800L
  1053. #define ES_WANTRETURN    4096    // 0x00001000L
  1054.  
  1055. // Static Control Styles
  1056. #define SS_LEFT            0    // 0x00000000L
  1057. #define SS_CENTER        1    // 0x00000001L
  1058. #define SS_RIGHT        2    // 0x00000002L
  1059. #define SS_ICON            3    // 0x00000003L
  1060. #define SS_BLACKRECT        4    // 0x00000004L
  1061. #define SS_GRAYRECT        5    // 0x00000005L
  1062. #define SS_WHITERECT        6    // 0x00000006L
  1063. #define SS_BLACKFRAME        7    // 0x00000007L
  1064. #define SS_GRAYFRAME        8    // 0x00000008L
  1065. #define SS_WHITEFRAME        9    // 0x00000009L
  1066. #define SS_SIMPLE        11    // 0x0000000BL
  1067. #define SS_LEFTNOWORDWRAP    12    // 0x0000000CL
  1068. #define SS_NOPREFIX        128    // 0x00000080L
  1069.  
  1070.  
  1071. // Dialog control classes
  1072. #define    DLG_BUTTON    128    // 0x80
  1073. #define    DLG_EDIT    129    // 0x81
  1074. #define    DLG_STATIC    130    // 0x82
  1075. #define    DLG_LISTBOX    131    // 0x83
  1076. #define    DLG_SCROLLBAR    132    // 0x84
  1077. #define    DLG_COMBOBOX    133    // 0x85
  1078.  
  1079.  
  1080. // Stock fonts for use with GetStockObject()
  1081. #define OEM_FIXED_FONT        10
  1082. #define ANSI_FIXED_FONT     11
  1083. #define ANSI_VAR_FONT        12
  1084. #define SYSTEM_FONT        13
  1085. #define DEVICE_DEFAULT_FONT 14
  1086. #define DEFAULT_PALETTE     15
  1087. #define SYSTEM_FIXED_FONT   16
  1088.  
  1089.  
  1090. // Device Capabilities
  1091.  
  1092. /* Device Parameters for GetDeviceCaps() */
  1093. #ifdef    WIN_WANT_GETDEVCAPS
  1094. #define DRIVERVERSION 0
  1095. #define TECHNOLOGY    2
  1096. #endif    // WIN_WANT_GETDEVCAPS
  1097. #define HORZSIZE      4
  1098. #define VERTSIZE      6
  1099. #define HORZRES       8
  1100. #define VERTRES       10
  1101. #ifdef    WIN_WANT_GETDEVCAPS
  1102. #define BITSPIXEL     12
  1103. #define PLANES        14
  1104. #define NUMBRUSHES    16
  1105. #define NUMPENS       18
  1106. #define NUMMARKERS    20
  1107. #define NUMFONTS      22
  1108. #define NUMCOLORS     24
  1109. #define PDEVICESIZE   26
  1110. #define CURVECAPS     28
  1111. #define LINECAPS      30
  1112. #define POLYGONALCAPS 32
  1113. #define TEXTCAPS      34
  1114. #define CLIPCAPS      36
  1115. #define RASTERCAPS    38
  1116. #define ASPECTX       40
  1117. #define ASPECTY       42
  1118. #define ASPECTXY      44
  1119.  
  1120. #define LOGPIXELSX    88
  1121. #define LOGPIXELSY    90
  1122.  
  1123. #define SIZEPALETTE  104
  1124. #define NUMRESERVED  106
  1125. #define COLORRES     108
  1126. #endif    // WIN_WANT_GETDEVCAPS
  1127.  
  1128.  
  1129. #ifdef    WIN_WANT_GETDEVCAPMASKS
  1130.  
  1131. // GetDeviceCaps() return values/masks
  1132.  
  1133. /* TECHNOLOGY */
  1134. #define DT_PLOTTER          0
  1135. #define DT_RASDISPLAY       1
  1136. #define DT_RASPRINTER       2
  1137. #define DT_RASCAMERA        3
  1138. #define DT_CHARSTREAM       4
  1139. #define DT_METAFILE         5
  1140. #define DT_DISPFILE         6
  1141.  
  1142. /* CURVECAPS */
  1143. #define CC_NONE        0    // 0x0000
  1144. #define CC_CIRCLES    1    // 0x0001
  1145. #define CC_PIE        2    // 0x0002
  1146. #define CC_CHORD    4    // 0x0004
  1147. #define CC_ELLIPSES    8    // 0x0008
  1148. #define CC_WIDE        16    // 0x0010
  1149. #define CC_STYLED    32    // 0x0020
  1150. #define CC_WIDESTYLED    64    // 0x0040
  1151. #define CC_INTERIORS    128    // 0x0080
  1152. #define CC_ROUNDRECT    256    // 0x0100
  1153.  
  1154. /* LINECAPS */
  1155. #define LC_NONE        0    // 0x0000
  1156. #define LC_POLYLINE    2    // 0x0002
  1157. #define LC_MARKER    4    // 0x0004
  1158. #define LC_POLYMARKER    8    // 0x0008
  1159. #define LC_WIDE        16    // 0x0010
  1160. #define LC_STYLED    32    // 0x0020
  1161. #define LC_WIDESTYLED    64    // 0x0040
  1162. #define LC_INTERIORS    128    // 0x0080
  1163.  
  1164. /* POLYGONALCAPS */
  1165. #define PC_NONE        0    // 0x0000
  1166. #define PC_POLYGON    1    // 0x0001
  1167. #define PC_RECTANGLE    2    // 0x0002
  1168. #define PC_WINDPOLYGON    4    // 0x0004
  1169. #define PC_SCANLINE    8    // 0x0008
  1170. #define PC_WIDE        16    // 0x0010
  1171. #define PC_STYLED    32    // 0x0020
  1172. #define PC_WIDESTYLED    64    // 0x0040
  1173. #define PC_INTERIORS    128    // 0x0080
  1174.  
  1175. /* TEXTCAPS */
  1176. #define TC_OP_CHARACTER    1    // 0x0001
  1177. #define TC_OP_STROKE    2    // 0x0002
  1178. #define TC_CP_STROKE    4    // 0x0004
  1179. #define TC_CR_90    8    // 0x0008
  1180. #define TC_CR_ANY    16    // 0x0010
  1181. #define TC_SF_X_YINDEP    32    // 0x0020
  1182. #define TC_SA_DOUBLE    64    // 0x0040
  1183. #define TC_SA_INTEGER    128    // 0x0080
  1184. #define TC_SA_CONTIN    256    // 0x0100
  1185. #define TC_EA_DOUBLE    512    // 0x0200
  1186. #define TC_IA_ABLE    1024    // 0x0400
  1187. #define TC_UA_ABLE    2048    // 0x0800
  1188. #define TC_SO_ABLE    4096    // 0x1000
  1189. #define TC_RA_ABLE    8192    // 0x2000
  1190. #define TC_VA_ABLE    16384    // 0x4000
  1191. #define TC_RESERVED    32768    // 0x8000
  1192.  
  1193. /* CLIPCAPS */
  1194. #define CP_NONE        0    // 0x0000
  1195. #define CP_RECTANGLE    1    // 0x0001
  1196. #define CP_REGION    2    // 0x0002
  1197.  
  1198. /* RASTERCAPS */
  1199. #define RC_NONE        0
  1200. #define RC_BITBLT    1    // 0x0001
  1201. #define RC_BANDING    2    // 0x0002
  1202. #define RC_SCALING    4    // 0x0004
  1203. #define RC_BITMAP64    8    // 0x0008
  1204. #define RC_GDI20_OUTPUT    16    // 0x0010
  1205. #define RC_GDI20_STATE    32    // 0x0020
  1206. #define RC_SAVEBITMAP    64    // 0x0040
  1207. #define RC_DI_BITMAP    128    // 0x0080
  1208. #define RC_PALETTE    256    // 0x0100
  1209. #define RC_DIBTODEV    512    // 0x0200
  1210. #define RC_BIGFONT    1024    // 0x0400
  1211. #define RC_STRETCHBLT    2048    // 0x0800
  1212. #define RC_FLOODFILL    4096    // 0x1000
  1213. #define RC_STRETCHDIB    8192    // 0x2000
  1214. #define RC_OP_DX_OUTPUT    16384    // 0x4000
  1215. #define RC_DEVBITS    32768    // 0x8000
  1216.  
  1217. #endif    // WIN_WANT_GETDEVCAPMASKS
  1218.  
  1219. #ifdef    WIN_WANT_HELP
  1220.  
  1221. // WinHelp() commands:
  1222. #define HELP_CONTEXT        1    // 0x0001
  1223. #define HELP_QUIT        2    // 0x0002
  1224. #define HELP_INDEX        3    // 0x0003
  1225. #define HELP_CONTENTS        3    // 0x0003
  1226. #define HELP_HELPONHELP        4    // 0x0004
  1227. #define HELP_SETINDEX        5    // 0x0005
  1228. #define HELP_SETCONTENTS    5    // 0x0005
  1229. #define HELP_CONTEXTPOPUP    8    // 0x0008
  1230. #define HELP_FORCEFILE        9    // 0x0009
  1231. #define HELP_KEY        257    // 0x0101
  1232. #define HELP_COMMAND        258    // 0x0102
  1233. #define HELP_PARTIALKEY        261    // 0x0105
  1234. #define HELP_MULTIKEY        513    // 0x0201
  1235. #define HELP_SETWINPOS        515    // 0x0203
  1236.  
  1237. #endif    // WIN_WANT_HELP
  1238.  
  1239. #ifdef    WIN_WANT_CLIPBOARD
  1240.  
  1241. // Predefined Clipboard Formats:
  1242. #define CF_TEXT          1
  1243. #define CF_BITMAP         2
  1244. #define CF_METAFILEPICT      3
  1245. #define CF_SYLK          4
  1246. #define CF_DIF             5
  1247. #define CF_TIFF          6
  1248. #define CF_OEMTEXT         7
  1249. #define CF_DIB             8
  1250. #define CF_PALETTE         9
  1251. #define CF_PENDATA          10
  1252. #define CF_RIFF             11
  1253. #define CF_WAVE             12
  1254.  
  1255. #define CF_OWNERDISPLAY        128    // 0x0080
  1256. #define CF_DSPTEXT        129    // 0x0081
  1257. #define CF_DSPBITMAP        130    // 0x0082
  1258. #define CF_DSPMETAFILEPICT    131    // 0x0083
  1259.  
  1260. // "Private" formats:
  1261. #define CF_PRIVATEFIRST    512    // 0x0200
  1262. #define CF_PRIVATELAST    767    // 0x02FF
  1263.  
  1264. // "GDIOBJ" formats do get DeleteObject()'d:
  1265. #define CF_GDIOBJFIRST    768    // 0x0300
  1266. #define CF_GDIOBJLAST    1023    // 0x03FF
  1267.  
  1268. // Clipboard command messages:
  1269. #define WM_CUT 768    /* 0x0300 */
  1270. #define WM_COPY 769    /* 0x0301 */
  1271. #define WM_PASTE 770    /* 0x0302 */
  1272. #define WM_CLEAR 771    /* 0x0303 */
  1273. #define WM_UNDO 772    /* 0x0304 */
  1274.  
  1275. // Clipboard owner messages:
  1276. #define WM_RENDERFORMAT 773    /* 0x0305 */
  1277. #define WM_RENDERALLFORMATS 774    /* 0x0306 */
  1278. #define WM_DESTROYCLIPBOARD 775    /* 0x0307 */
  1279.  
  1280. // Clipboard viewer messages:
  1281. #define WM_DRAWCLIPBOARD 776    /* 0x0308 */
  1282. #define WM_PAINTCLIPBOARD 777    /* 0x0309 */
  1283. #define WM_SIZECLIPBOARD 779    /* 0x030B */
  1284. #define WM_VSCROLLCLIPBOARD 778    /* 0x030A */
  1285. #define WM_HSCROLLCLIPBOARD 782    /* 0x030E */
  1286. #define WM_ASKCBFORMATNAME 780    /* 0x030C */
  1287. #define WM_CHANGECBCHAIN 781    /* 0x030D */
  1288.  
  1289. // handle Clipper 10-char limit on external names
  1290. #ifndef RC_INVOKED
  1291. #xtranslate EnumClipboardFormats    =>    EnumClipbFormats
  1292. #xtranslate GetClipboardData        =>    GetClipbData
  1293. #xtranslate GetClipboardFormatName    =>    GetClipbFormatName
  1294. #xtranslate GetClipboardOwner        =>    GetClipbOwner
  1295. #xtranslate GetClipboardViewer        =>    GetClipbViewer
  1296. #xtranslate IsClipboardFormatAvailable    =>    IsClipbFormatAvailable
  1297. #xtranslate RegisterClipboardFormat    =>    RegClipbFormat
  1298. #xtranslate SetClipboardData        =>    SetClipbData
  1299. #endif
  1300.  
  1301. #endif    // WIN_WANT_CLIPBOARD
  1302.  
  1303. #define WM_VBXFIREEVENT    864    // 0x0360
  1304.  
  1305. // DrawText() Format Flags:
  1306. #ifdef WIN_WANT_DRAWTEXT
  1307. #define DT_TOP        0
  1308. #define DT_LEFT        0
  1309. #define DT_CENTER    1
  1310. #define DT_RIGHT    2
  1311. #define DT_VCENTER    4
  1312. #define DT_BOTTOM    8
  1313. #define DT_WORDBREAK    16
  1314. #define DT_SINGLELINE    32
  1315. #define DT_EXPANDTABS    64
  1316. #define DT_TABSTOP    128
  1317. #define DT_NOCLIP    256
  1318. #define DT_EXTERNALLEADING 512
  1319. #define DT_CALCRECT    1024
  1320. #define DT_NOPREFIX    2048
  1321. #define DT_INTERNAL    4096
  1322. #endif // WIN_WANT_DRAWTEXT
  1323.  
  1324.  
  1325. // Background Modes:
  1326. #define TRANSPARENT     1
  1327. #define OPAQUE          2
  1328.  
  1329. // Text Alignment settings:
  1330. #ifdef WIN_WANT_TEXTALIGN
  1331. #define TA_NOUPDATECP    0
  1332. #define TA_UPDATECP    1
  1333. #define TA_LEFT     0
  1334. #define TA_RIGHT    2
  1335. #define TA_CENTER    6
  1336. #define TA_TOP        0
  1337. #define TA_BOTTOM    8
  1338. #define TA_BASELINE    24
  1339. #endif // WIN_WANT_TEXTALIGN
  1340.  
  1341.  
  1342. #ifdef WIN_WANT_RASTEROPS
  1343. // Binary raster operations:
  1344. #define R2_BLACK    1
  1345. #define R2_NOTMERGEPEN    2
  1346. #define R2_MASKNOTPEN    3
  1347. #define R2_NOTCOPYPEN    4
  1348. #define R2_MASKPENNOT    5
  1349. #define R2_NOT        6
  1350. #define R2_XORPEN    7
  1351. #define R2_NOTMASKPEN    8
  1352. #define R2_MASKPEN    9
  1353. #define R2_NOTXORPEN    10
  1354. #define R2_NOP        11
  1355. #define R2_MERGENOTPEN    12
  1356. #define R2_COPYPEN    13
  1357. #define R2_MERGEPENNOT    14
  1358. #define R2_MERGEPEN    15
  1359. #define R2_WHITE    16
  1360.  
  1361. // Ternary raster operations:
  1362. #define SRCCOPY        13369376    // 0x00CC0020L
  1363. #define SRCPAINT    15597702    // 0x00EE0086L
  1364. #define SRCAND        8913094        // 0x008800C6L
  1365. #define SRCINVERT    6684742        // 0x00660046L
  1366. #define SRCERASE    4457256        // 0x00440328L
  1367. #define NOTSRCCOPY    3342344        // 0x00330008L
  1368. #define NOTSRCERASE    1114278        // 0x001100A6L
  1369. #define MERGECOPY    12583114    // 0x00C000CAL
  1370. #define MERGEPAINT    12255782    // 0x00BB0226L
  1371. #define PATCOPY        15728673    // 0x00F00021L
  1372. #define PATPAINT    16452105    // 0x00FB0A09L
  1373. #define PATINVERT    5898313        // 0x005A0049L
  1374. #define DSTINVERT    5570569        // 0x00550009L
  1375. #define BLACKNESS    66        // 0x00000042L
  1376. #define WHITENESS    16711778    // 0x00FF0062L
  1377. #endif // WIN_WANT_RASTEROPS
  1378.  
  1379. // Spooler Error Codes
  1380. #ifdef    WIN_WANT_SPOOLER
  1381. #define SP_NOTREPORTED             16384
  1382. #define SP_ERROR             (-1)
  1383. #define SP_APPABORT             (-2)
  1384. #define SP_USERABORT             (-3)
  1385. #define SP_OUTOFDISK             (-4)
  1386. #define SP_OUTOFMEMORY             (-5)
  1387. #endif    // WIN_WANT_SPOOLER
  1388.  
  1389. // Window field offsets for GetWindowLong() and GetWindowWord()
  1390. #ifdef    WIN_WANT_GETWINDOW
  1391. //#define GWL_WNDPROC        (-4)    // use SubClassWindow()
  1392. #define GWW_HINSTANCE        (-6)
  1393. #define GWW_HWNDPARENT        (-8)
  1394. #define GWW_ID            (-12)
  1395. #define GWL_STYLE        (-16)
  1396. #define GWL_EXSTYLE        (-20)
  1397.  
  1398. // Get/SetWindowWord/Long offsets for use with DIALOG windows
  1399. #define DWL_MSGRESULT    0
  1400. #define DWL_DLGPROC    4
  1401. #define DWL_USER    8
  1402. #endif    // WIN_WANT_GETWINDOW
  1403.  
  1404. // Predefined Resource Types:
  1405. #ifdef    WIN_WANT_RESOURCE
  1406. #define RT_CURSOR    (1)
  1407. #define RT_BITMAP    (2)
  1408. #define RT_ICON     (3)
  1409. #define RT_MENU     (4)
  1410. #define RT_DIALOG    (5)
  1411. #define RT_STRING    (6)
  1412. #define RT_FONTDIR    (7)
  1413. #define RT_FONT     (8)
  1414. #define RT_ACCELERATOR    (9)
  1415. #define RT_RCDATA    (10)
  1416.  
  1417. #define RT_GROUP_CURSOR    (12)
  1418. #define RT_GROUP_ICON    (14)
  1419. #endif    // WIN_WANT_RESOURCE
  1420.  
  1421. // Flags for TrackPopupMenu():
  1422. #ifdef    WIN_WANT_TRACKPOPUP
  1423. #define TPM_LEFTBUTTON  0
  1424. #define TPM_RIGHTBUTTON 2
  1425. #define TPM_LEFTALIGN   0
  1426. #define TPM_CENTERALIGN 4
  1427. #define TPM_RIGHTALIGN  8
  1428. #endif    // WIN_WANT_TRACKPOPUP
  1429.  
  1430. // Flags for GetWinFlags():
  1431. #ifdef    WIN_WANT_WINFLAGS
  1432. #define WF_PMODE    1
  1433. #define WF_CPU286    2
  1434. #define WF_CPU386    4
  1435. #define WF_CPU486    8
  1436. #define WF_STANDARD    16
  1437. #define WF_WIN286    16
  1438. #define WF_ENHANCED    32
  1439. #define WF_WIN386    32
  1440. #define WF_CPU086    64
  1441. #define WF_CPU186    128
  1442. #define WF_LARGEFRAME    256
  1443. #define WF_SMALLFRAME    512
  1444. #define WF_80x87    1024
  1445. #define WF_PAGING    2048
  1446. #define WF_WLO        32768
  1447. #endif    // WIN_WANT_WINFLAGS
  1448.  
  1449. // Map modes for SetMapMode():
  1450. #ifdef    WIN_WANT_MAPMODE
  1451. #define MM_TEXT        1
  1452. #define MM_LOMETRIC    2
  1453. #define MM_HIMETRIC    3
  1454. #define MM_LOENGLISH    4
  1455. #define MM_HIENGLISH    5
  1456. #define MM_TWIPS    6
  1457. #define MM_ISOTROPIC    7
  1458. #define MM_ANISOTROPIC    8
  1459. #endif    // WIN_WANT_MAPMODE
  1460.  
  1461. // PeekMessage() nRemove values:
  1462. #define PM_NOREMOVE    0
  1463. #define PM_REMOVE    1
  1464. #define PM_NOYIELD    2
  1465.  
  1466. // WM_MOUSEMOVE nwParam bit settings:
  1467. #define MK_LBUTTON    1
  1468. #define MK_RBUTTON    2
  1469. #define MK_SHIFT    4
  1470. #define MK_CONTROL    8
  1471. #define MK_MBUTTON    16        // middle button (if you have one)
  1472.  
  1473. // RegisterClass() window types (for default msg processing)
  1474. #define    RCF_WINDOW    1        // use DefWindowProc()
  1475. #define    RCF_MDIFRAME    2        // use DefFrameProc()
  1476. #define    RCF_MDICHILD    4        // use DefMDIChildProc()
  1477.  
  1478. #define    OF_EXIST    16384        // for OpenFile()
  1479.  
  1480. // Events from _chkevent()
  1481. #define    EVENT_NONE    -1
  1482. #define    EVENT_OTHER    0        // probably treat like EVENT_NONE
  1483. #define    EVENT_KEY    1        // keystroke
  1484. #define    EVENT_MENU    2        // menu item selected
  1485. #define    EVENT_WINSEL    3
  1486. #define    EVENT_CLOSE    5
  1487. #define    EVENT_BUTTON    6
  1488. #define    EVENT_SCROLLBAR    7
  1489. #define    EVENT_QUIT    9        // quitting the application (either you
  1490.                     // can QUIT, or if you call ChkEvent()
  1491.                     // again, it will QUIT for you)
  1492. #define    EVENT_INC    10
  1493. #define    EVENT_DESTROY    11        // window being destroyed
  1494. #define    EVENT_WINMOVE    12        // window moved
  1495. #define    EVENT_WINSIZE    13        // window resized: see maxrow(),maxcol()
  1496. #define    EVENT_REDRAW    14        // need to re-draw window
  1497. #define    EVENT_SETFOCUS    15        // window given focus
  1498. #define    EVENT_KILLFOCUS    16        // window losing focus
  1499. #define    EVENT_LCLICK    17        // mouse left click: see MouseX(),MouseY()
  1500. #define    EVENT_RCLICK    18        // mouse right click: see MouseX(),MouseY()
  1501. #define    EVENT_MCLICK    19        // mouse middle click: see MouseX(),MouseY()
  1502. #define    EVENT_CONTROL    20        // notification from child control
  1503.                     // e.g. buttons
  1504. #define    EVENT_ACCELKEY    21        // accelerator key
  1505. #define    EVENT_HSCROLL    22        // msg from horiz scrollbar control
  1506. #define    EVENT_VSCROLL    23        // msg from vert scrollbar control
  1507. #define    EVENT_LDBLCLK    24        // left double click: see MouseX(),MouseY()
  1508. #define    EVENT_RDBLCLK    25        // right double click: see MouseX(),MouseY()
  1509. #define    EVENT_MDBLCLK    26        // middle double click: see MouseX(),MouseY()
  1510. #define    EVENT_TIMER    27        // time-out event
  1511. #define    EVENT_LBTNUP    28        // mouse left button up
  1512. #define    EVENT_RBTNUP    29        // mouse right button up
  1513. #define    EVENT_MBTNUP    30        // mouse middle button up
  1514.  
  1515. // events reserved for users: 1024-32767
  1516. #define    EVENT_USER    1024        // user-specific events start here
  1517.  
  1518.  
  1519. #ifndef RC_INVOKED
  1520. // handle Clipper 10-char limit on external names
  1521. #xtranslate    GetSystemMenu    =>    GetSysMenu
  1522. #xtranslate    GetDlgItemInt    =>    GetDlgItmInt
  1523. #xtranslate    GetDlgItemText    =>    GetDlgItmText
  1524. #xtranslate    GetViewportOrg    =>    GViewportOrg
  1525. #xtranslate    SetViewportOrg    =>    SViewportOrg
  1526. #xtranslate    TranslateMDISysAccel =>    TranslMDISysAccel
  1527.  
  1528. #xcommand DEFAULT <v> TO <x> [, <vN> TO <xN>]                ;
  1529.        => IF <v> == nil ; <v> := <x> ; END                ;
  1530.           [; IF <vN> == nil ; <vN> := <xN> ; END]
  1531.  
  1532. #ifndef    WIN_DEBUG
  1533. #xtranslate DbgTrace( [<p,...>] )    =>
  1534. #xtranslate DbgTrace( [<p,...>] ),    =>    nil,
  1535. #endif
  1536. #ifdef    WIN_DBWIN
  1537. #xtranslate DbgTrace( <p> [, <pN>] )                    ;
  1538.          => OutputDebugString(TRANSFORM(<p>, "")            ;
  1539.                               [+ " " + TRANSFORM(<pN>, "")]        ;
  1540.                               + CHR(13) + CHR(10) + CHR(0))
  1541. // no need for "DbgTrace(...),"
  1542.  
  1543. #command $ [<p,...>]                            ;
  1544.       => $$ [<p>,] CHR(13) + CHR(10)
  1545.  
  1546. #command $$ <p> [, <pN>]                        ;
  1547.       => OutputDebugString(TRANSFORM(IIF(<p> == NIL, "NIL", <p>), "")    ;
  1548.                            [+ TRANSFORM(IIF(<pN> == NIL, "NIL", <pN>), "")];
  1549.                            + CHR(0))
  1550. #else    // WIN_DBWIN
  1551.  
  1552. #command $ [<p,...>]        => 
  1553. #command $$ <p> [, <pN>]    => 
  1554.  
  1555. #endif    // WIN_DBWIN
  1556. #endif    // RC_INVOKED
  1557.  
  1558. #endif    // C4W_WINDOWS_CH
  1559.  
  1560.