wintab.h 19 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789
  1. /*
  2. * Copyright (C) 1991-1998 by LCS/Telegraphics
  3. * Copyright (C) 2002 Patrik Stridvall
  4. *
  5. * This library is free software; you can redistribute it and/or
  6. * modify it under the terms of the GNU Lesser General Public
  7. * License as published by the Free Software Foundation; either
  8. * version 2.1 of the License, or (at your option) any later version.
  9. *
  10. * This library is distributed in the hope that it will be useful,
  11. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
  13. * Lesser General Public License for more details.
  14. *
  15. * You should have received a copy of the GNU Lesser General Public
  16. * License along with this library; if not, write to the Free Software
  17. * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
  18. */
  19. #ifndef __WINE_WINTAB_H
  20. #define __WINE_WINTAB_H
  21. #ifdef __cplusplus
  22. extern "C" {
  23. #endif /* defined(__cplusplus) */
  24. /***********************************************************************
  25. * Messages
  26. */
  27. #ifndef NOWTMESSAGES
  28. #define WT_DEFBASE 0x7FF0
  29. #define WT_MAXOFFSET 0xF
  30. #define _WT_PACKET(b) ((b)+0)
  31. #define _WT_CTXOPEN(b) ((b)+1)
  32. #define _WT_CTXCLOSE(b) ((b)+2)
  33. #define _WT_CTXUPDATE(b) ((b)+3)
  34. #define _WT_CTXOVERLAP(b) ((b)+4)
  35. #define _WT_PROXIMITY(b) ((b)+5)
  36. #define _WT_INFOCHANGE(b) ((b)+6)
  37. #define _WT_CSRCHANGE(b) ((b)+7) /* 1.1 */
  38. #define _WT_MAX(b) ((b)+WT_MAXOFFSET)
  39. #define WT_PACKET _WT_PACKET(WT_DEFBASE)
  40. #define WT_CTXOPEN _WT_CTXOPEN(WT_DEFBASE)
  41. #define WT_CTXCLOSE _WT_CTXCLOSE(WT_DEFBASE)
  42. #define WT_CTXUPDATE _WT_CTXUPDATE(WT_DEFBASE)
  43. #define WT_CTXOVERLAP _WT_CTXOVERLAP(WT_DEFBASE)
  44. #define WT_PROXIMITY _WT_PROXIMITY(WT_DEFBASE)
  45. #define WT_INFOCHANGE _WT_INFOCHANGE(WT_DEFBASE)
  46. #define WT_CSRCHANGE _WT_CSRCHANGE(WT_DEFBASE) /* 1.1 */
  47. #define WT_MAX _WT_MAX(WT_DEFBASE)
  48. #endif
  49. /***********************************************************************
  50. * COMMON DATA DEFS
  51. */
  52. DECLARE_HANDLE(HMGR); /* manager handle */
  53. DECLARE_HANDLE(HCTX); /* context handle */
  54. DECLARE_HANDLE(HWTHOOK); /* hook handle */
  55. typedef DWORD WTPKT; /* packet mask */
  56. #ifndef NOWTPKT
  57. /* WTPKT bits */
  58. #define PK_CONTEXT 0x0001 /* reporting context */
  59. #define PK_STATUS 0x0002 /* status bits */
  60. #define PK_TIME 0x0004 /* time stamp */
  61. #define PK_CHANGED 0x0008 /* change bit vector */
  62. #define PK_SERIAL_NUMBER 0x0010 /* packet serial number */
  63. #define PK_CURSOR 0x0020 /* reporting cursor */
  64. #define PK_BUTTONS 0x0040 /* button information */
  65. #define PK_X 0x0080 /* x axis */
  66. #define PK_Y 0x0100 /* y axis */
  67. #define PK_Z 0x0200 /* z axis */
  68. #define PK_NORMAL_PRESSURE 0x0400 /* normal or tip pressure */
  69. #define PK_TANGENT_PRESSURE 0x0800 /* tangential or barrel pressure */
  70. #define PK_ORIENTATION 0x1000 /* orientation info: tilts */
  71. #define PK_ROTATION 0x2000 /* rotation info; 1.1 */
  72. #endif
  73. typedef DWORD FIX32; /* fixed-point arithmetic type */
  74. #ifndef NOFIX32
  75. #define INT(x) HIWORD(x)
  76. #define FRAC(x) LOWORD(x)
  77. #define CASTFIX32(x) ((FIX32)((x)*65536L))
  78. #define ROUND(x) (INT(x) + (FRAC(x) > (WORD)0x8000))
  79. #define FIX_MUL(c, a, b) \
  80. (c = (((DWORD)FRAC(a) * FRAC(b)) >> 16) + \
  81. (DWORD)INT(a) * FRAC(b) + \
  82. (DWORD)INT(b) * FRAC(a) + \
  83. ((DWORD)INT(a) * INT(b) << 16))
  84. #ifdef _WINDLL
  85. # define FIX_DIV_SC static
  86. #else
  87. # define FIX_DIV_SC
  88. # endif
  89. #define FIX_DIV(c, a, b) \
  90. { \
  91. FIX_DIV_SC DWORD temp, rem, btemp; \
  92. \
  93. /* fraction done bytewise */ \
  94. temp = ((a / b) << 16); \
  95. rem = a % b; \
  96. btemp = b; \
  97. if (INT(btemp) < 256) { \
  98. rem <<= 8; \
  99. } else { \
  100. btemp >>= 8; \
  101. } \
  102. temp += ((rem / btemp) << 8); \
  103. rem %= btemp; \
  104. rem <<= 8; \
  105. temp += rem / btemp; \
  106. c = temp; \
  107. }
  108. #endif
  109. /***********************************************************************
  110. * INFO DATA DEFS
  111. */
  112. #ifndef NOWTINFO
  113. #ifndef NOWTAXIS
  114. typedef struct tagAXIS {
  115. LONG axMin;
  116. LONG axMax;
  117. UINT axUnits;
  118. FIX32 axResolution;
  119. } AXIS, *PAXIS, *NPAXIS, *LPAXIS;
  120. /* unit specifiers */
  121. #define TU_NONE 0
  122. #define TU_INCHES 1
  123. #define TU_CENTIMETERS 2
  124. #define TU_CIRCLE 3
  125. #endif
  126. #ifndef NOWTSYSBUTTONS
  127. /* system button assignment values */
  128. #define SBN_NONE 0x00
  129. #define SBN_LCLICK 0x01
  130. #define SBN_LDBLCLICK 0x02
  131. #define SBN_LDRAG 0x03
  132. #define SBN_RCLICK 0x04
  133. #define SBN_RDBLCLICK 0x05
  134. #define SBN_RDRAG 0x06
  135. #define SBN_MCLICK 0x07
  136. #define SBN_MDBLCLICK 0x08
  137. #define SBN_MDRAG 0x09
  138. /* for Pen Windows */
  139. #define SBN_PTCLICK 0x10
  140. #define SBN_PTDBLCLICK 0x20
  141. #define SBN_PTDRAG 0x30
  142. #define SBN_PNCLICK 0x40
  143. #define SBN_PNDBLCLICK 0x50
  144. #define SBN_PNDRAG 0x60
  145. #define SBN_P1CLICK 0x70
  146. #define SBN_P1DBLCLICK 0x80
  147. #define SBN_P1DRAG 0x90
  148. #define SBN_P2CLICK 0xA0
  149. #define SBN_P2DBLCLICK 0xB0
  150. #define SBN_P2DRAG 0xC0
  151. #define SBN_P3CLICK 0xD0
  152. #define SBN_P3DBLCLICK 0xE0
  153. #define SBN_P3DRAG 0xF0
  154. #endif
  155. #ifndef NOWTCAPABILITIES
  156. /* hardware capabilities */
  157. #define HWC_INTEGRATED 0x0001
  158. #define HWC_TOUCH 0x0002
  159. #define HWC_HARDPROX 0x0004
  160. #define HWC_PHYSID_CURSORS 0x0008 /* 1.1 */
  161. #endif
  162. #ifndef NOWTIFC
  163. #ifndef NOWTCURSORS
  164. /* cursor capabilities */
  165. #define CRC_MULTIMODE 0x0001 /* 1.1 */
  166. #define CRC_AGGREGATE 0x0002 /* 1.1 */
  167. #define CRC_INVERT 0x0004 /* 1.1 */
  168. #endif
  169. /* info categories */
  170. #define WTI_INTERFACE 1
  171. #define IFC_WINTABID 1
  172. #define IFC_SPECVERSION 2
  173. #define IFC_IMPLVERSION 3
  174. #define IFC_NDEVICES 4
  175. #define IFC_NCURSORS 5
  176. #define IFC_NCONTEXTS 6
  177. #define IFC_CTXOPTIONS 7
  178. #define IFC_CTXSAVESIZE 8
  179. #define IFC_NEXTENSIONS 9
  180. #define IFC_NMANAGERS 10
  181. #define IFC_MAX 10
  182. #endif
  183. #ifndef NOWTSTATUS
  184. #define WTI_STATUS 2
  185. #define STA_CONTEXTS 1
  186. #define STA_SYSCTXS 2
  187. #define STA_PKTRATE 3
  188. #define STA_PKTDATA 4
  189. #define STA_MANAGERS 5
  190. #define STA_SYSTEM 6
  191. #define STA_BUTTONUSE 7
  192. #define STA_SYSBTNUSE 8
  193. #define STA_MAX 8
  194. #endif
  195. #ifndef NOWTDEFCONTEXT
  196. #define WTI_DEFCONTEXT 3
  197. #define WTI_DEFSYSCTX 4
  198. #define WTI_DDCTXS 400 /* 1.1 */
  199. #define WTI_DSCTXS 500 /* 1.1 */
  200. #define CTX_NAME 1
  201. #define CTX_OPTIONS 2
  202. #define CTX_STATUS 3
  203. #define CTX_LOCKS 4
  204. #define CTX_MSGBASE 5
  205. #define CTX_DEVICE 6
  206. #define CTX_PKTRATE 7
  207. #define CTX_PKTDATA 8
  208. #define CTX_PKTMODE 9
  209. #define CTX_MOVEMASK 10
  210. #define CTX_BTNDNMASK 11
  211. #define CTX_BTNUPMASK 12
  212. #define CTX_INORGX 13
  213. #define CTX_INORGY 14
  214. #define CTX_INORGZ 15
  215. #define CTX_INEXTX 16
  216. #define CTX_INEXTY 17
  217. #define CTX_INEXTZ 18
  218. #define CTX_OUTORGX 19
  219. #define CTX_OUTORGY 20
  220. #define CTX_OUTORGZ 21
  221. #define CTX_OUTEXTX 22
  222. #define CTX_OUTEXTY 23
  223. #define CTX_OUTEXTZ 24
  224. #define CTX_SENSX 25
  225. #define CTX_SENSY 26
  226. #define CTX_SENSZ 27
  227. #define CTX_SYSMODE 28
  228. #define CTX_SYSORGX 29
  229. #define CTX_SYSORGY 30
  230. #define CTX_SYSEXTX 31
  231. #define CTX_SYSEXTY 32
  232. #define CTX_SYSSENSX 33
  233. #define CTX_SYSSENSY 34
  234. #define CTX_MAX 34
  235. #endif
  236. #ifndef NOWTDEVICES
  237. #define WTI_DEVICES 100
  238. #define DVC_NAME 1
  239. #define DVC_HARDWARE 2
  240. #define DVC_NCSRTYPES 3
  241. #define DVC_FIRSTCSR 4
  242. #define DVC_PKTRATE 5
  243. #define DVC_PKTDATA 6
  244. #define DVC_PKTMODE 7
  245. #define DVC_CSRDATA 8
  246. #define DVC_XMARGIN 9
  247. #define DVC_YMARGIN 10
  248. #define DVC_ZMARGIN 11
  249. #define DVC_X 12
  250. #define DVC_Y 13
  251. #define DVC_Z 14
  252. #define DVC_NPRESSURE 15
  253. #define DVC_TPRESSURE 16
  254. #define DVC_ORIENTATION 17
  255. #define DVC_ROTATION 18 /* 1.1 */
  256. #define DVC_PNPID 19 /* 1.1 */
  257. #define DVC_MAX 19
  258. #endif
  259. #ifndef NOWTCURSORS
  260. #define WTI_CURSORS 200
  261. #define CSR_NAME 1
  262. #define CSR_ACTIVE 2
  263. #define CSR_PKTDATA 3
  264. #define CSR_BUTTONS 4
  265. #define CSR_BUTTONBITS 5
  266. #define CSR_BTNNAMES 6
  267. #define CSR_BUTTONMAP 7
  268. #define CSR_SYSBTNMAP 8
  269. #define CSR_NPBUTTON 9
  270. #define CSR_NPBTNMARKS 10
  271. #define CSR_NPRESPONSE 11
  272. #define CSR_TPBUTTON 12
  273. #define CSR_TPBTNMARKS 13
  274. #define CSR_TPRESPONSE 14
  275. #define CSR_PHYSID 15 /* 1.1 */
  276. #define CSR_MODE 16 /* 1.1 */
  277. #define CSR_MINPKTDATA 17 /* 1.1 */
  278. #define CSR_MINBUTTONS 18 /* 1.1 */
  279. #define CSR_CAPABILITIES 19 /* 1.1 */
  280. /* from http://www.wacomeng.com/devsupport/ibmpc/wacomwindevfaq.html */
  281. #define CSR_TYPE 20
  282. #define CSR_MAX 20
  283. #endif
  284. #ifndef NOWTEXTENSIONS
  285. #define WTI_EXTENSIONS 300
  286. #define EXT_NAME 1
  287. #define EXT_TAG 2
  288. #define EXT_MASK 3
  289. #define EXT_SIZE 4
  290. #define EXT_AXES 5
  291. #define EXT_DEFAULT 6
  292. #define EXT_DEFCONTEXT 7
  293. #define EXT_DEFSYSCTX 8
  294. #define EXT_CURSORS 9
  295. #define EXT_MAX 109 /* Allow 100 cursors */
  296. #endif
  297. #endif
  298. /***********************************************************************
  299. * CONTEXT DATA DEFS
  300. */
  301. #define LCNAMELEN 40
  302. #define LC_NAMELEN 40
  303. typedef struct tagLOGCONTEXTA {
  304. char lcName[LCNAMELEN];
  305. UINT lcOptions;
  306. UINT lcStatus;
  307. UINT lcLocks;
  308. UINT lcMsgBase;
  309. UINT lcDevice;
  310. UINT lcPktRate;
  311. WTPKT lcPktData;
  312. WTPKT lcPktMode;
  313. WTPKT lcMoveMask;
  314. DWORD lcBtnDnMask;
  315. DWORD lcBtnUpMask;
  316. LONG lcInOrgX;
  317. LONG lcInOrgY;
  318. LONG lcInOrgZ;
  319. LONG lcInExtX;
  320. LONG lcInExtY;
  321. LONG lcInExtZ;
  322. LONG lcOutOrgX;
  323. LONG lcOutOrgY;
  324. LONG lcOutOrgZ;
  325. LONG lcOutExtX;
  326. LONG lcOutExtY;
  327. LONG lcOutExtZ;
  328. FIX32 lcSensX;
  329. FIX32 lcSensY;
  330. FIX32 lcSensZ;
  331. BOOL lcSysMode;
  332. int lcSysOrgX;
  333. int lcSysOrgY;
  334. int lcSysExtX;
  335. int lcSysExtY;
  336. FIX32 lcSysSensX;
  337. FIX32 lcSysSensY;
  338. } LOGCONTEXTA, *PLOGCONTEXTA, *NPLOGCONTEXTA, *LPLOGCONTEXTA;
  339. typedef struct tagLOGCONTEXTW {
  340. WCHAR lcName[LCNAMELEN];
  341. UINT lcOptions;
  342. UINT lcStatus;
  343. UINT lcLocks;
  344. UINT lcMsgBase;
  345. UINT lcDevice;
  346. UINT lcPktRate;
  347. WTPKT lcPktData;
  348. WTPKT lcPktMode;
  349. WTPKT lcMoveMask;
  350. DWORD lcBtnDnMask;
  351. DWORD lcBtnUpMask;
  352. LONG lcInOrgX;
  353. LONG lcInOrgY;
  354. LONG lcInOrgZ;
  355. LONG lcInExtX;
  356. LONG lcInExtY;
  357. LONG lcInExtZ;
  358. LONG lcOutOrgX;
  359. LONG lcOutOrgY;
  360. LONG lcOutOrgZ;
  361. LONG lcOutExtX;
  362. LONG lcOutExtY;
  363. LONG lcOutExtZ;
  364. FIX32 lcSensX;
  365. FIX32 lcSensY;
  366. FIX32 lcSensZ;
  367. BOOL lcSysMode;
  368. int lcSysOrgX;
  369. int lcSysOrgY;
  370. int lcSysExtX;
  371. int lcSysExtY;
  372. FIX32 lcSysSensX;
  373. FIX32 lcSysSensY;
  374. } LOGCONTEXTW, *PLOGCONTEXTW, *NPLOGCONTEXTW, *LPLOGCONTEXTW;
  375. DECL_WINELIB_TYPE_AW(LOGCONTEXT)
  376. DECL_WINELIB_TYPE_AW(PLOGCONTEXT)
  377. DECL_WINELIB_TYPE_AW(NPLOGCONTEXT)
  378. DECL_WINELIB_TYPE_AW(LPLOGCONTEXT)
  379. /* context option values */
  380. #define CXO_SYSTEM 0x0001
  381. #define CXO_PEN 0x0002
  382. #define CXO_MESSAGES 0x0004
  383. #define CXO_MARGIN 0x8000
  384. #define CXO_MGNINSIDE 0x4000
  385. #define CXO_CSRMESSAGES 0x0008 /* 1.1 */
  386. /* context status values */
  387. #define CXS_DISABLED 0x0001
  388. #define CXS_OBSCURED 0x0002
  389. #define CXS_ONTOP 0x0004
  390. /* context lock values */
  391. #define CXL_INSIZE 0x0001
  392. #define CXL_INASPECT 0x0002
  393. #define CXL_SENSITIVITY 0x0004
  394. #define CXL_MARGIN 0x0008
  395. #define CXL_SYSOUT 0x0010
  396. /***********************************************************************
  397. * EVENT DATA DEFS
  398. */
  399. /* For packet structure definition, see pktdef.h */
  400. /* packet status values */
  401. #define TPS_PROXIMITY 0x0001
  402. #define TPS_QUEUE_ERR 0x0002
  403. #define TPS_MARGIN 0x0004
  404. #define TPS_GRAB 0x0008
  405. #define TPS_INVERT 0x0010 /* 1.1 */
  406. typedef struct tagORIENTATION {
  407. int orAzimuth;
  408. int orAltitude;
  409. int orTwist;
  410. } ORIENTATION, *PORIENTATION, *NPORIENTATION, *LPORIENTATION;
  411. typedef struct tagROTATION { /* 1.1 */
  412. int roPitch;
  413. int roRoll;
  414. int roYaw;
  415. } ROTATION, *PROTATION, *NPROTATION, *LPROTATION;
  416. /* grandfather in obsolete member names. */
  417. #define rotPitch roPitch
  418. #define rotRoll roRoll
  419. #define rotYaw roYaw
  420. /* relative buttons */
  421. #define TBN_NONE 0
  422. #define TBN_UP 1
  423. #define TBN_DOWN 2
  424. /***********************************************************************
  425. * DEVICE CONFIG CONSTANTS
  426. */
  427. #ifndef NOWTDEVCFG
  428. #define WTDC_NONE 0
  429. #define WTDC_CANCEL 1
  430. #define WTDC_OK 2
  431. #define WTDC_RESTART 3
  432. #endif
  433. /***********************************************************************
  434. * HOOK CONSTANTS
  435. */
  436. #ifndef NOWTHOOKS
  437. #define WTH_PLAYBACK 1
  438. #define WTH_RECORD 2
  439. #define WTHC_GETLPLPFN (-3)
  440. #define WTHC_LPLPFNNEXT (-2)
  441. #define WTHC_LPFNNEXT (-1)
  442. #define WTHC_ACTION 0
  443. #define WTHC_GETNEXT 1
  444. #define WTHC_SKIP 2
  445. #endif
  446. /***********************************************************************
  447. * PREFERENCE FUNCTION CONSTANTS
  448. */
  449. #ifndef NOWTPREF
  450. #define WTP_LPDEFAULT ((LPVOID)-1L)
  451. #define WTP_DWDEFAULT ((DWORD)-1L)
  452. #endif
  453. /***********************************************************************
  454. * EXTENSION TAGS AND CONSTANTS
  455. */
  456. #ifndef NOWTEXTENSIONS
  457. /* constants for use with pktdef.h */
  458. #define PKEXT_ABSOLUTE 1
  459. #define PKEXT_RELATIVE 2
  460. /* Extension tags. */
  461. #define WTX_OBT 0 /* Out of bounds tracking */
  462. #define WTX_FKEYS 1 /* Function keys */
  463. #define WTX_TILT 2 /* Raw Cartesian tilt; 1.1 */
  464. #define WTX_CSRMASK 3 /* select input by cursor type; 1.1 */
  465. #define WTX_XBTNMASK 4 /* Extended button mask; 1.1 */
  466. typedef struct tagXBTNMASK {
  467. BYTE xBtnDnMask[32];
  468. BYTE xBtnUpMask[32];
  469. } XBTNMASK;
  470. typedef struct tagTILT { /* 1.1 */
  471. int tiltX;
  472. int tiltY;
  473. } TILT;
  474. #endif
  475. /***********************************************************************
  476. * Functions
  477. */
  478. #ifndef NOWTCALLBACKS
  479. #ifndef NOWTMANAGERFXNS
  480. /* callback function types */
  481. typedef BOOL (WINAPI * WTENUMPROC)(HCTX, LPARAM); /* changed CALLBACK->WINAPI, 1.1 */
  482. typedef BOOL (WINAPI * WTCONFIGPROC)(HCTX, HWND);
  483. typedef LRESULT (WINAPI * WTHOOKPROC)(int, WPARAM, LPARAM);
  484. typedef WTHOOKPROC *LPWTHOOKPROC;
  485. #endif
  486. #endif
  487. #ifndef NOWTFUNCTIONS
  488. #ifndef NOWTBASICFXNS
  489. /* BASIC FUNCTIONS */
  490. #define ORD_WTInfoA 20
  491. #define ORD_WTInfoW 1020
  492. #define ORD_WTInfo WINELIB_NAME_AW(ORD_WTInfo)
  493. #define ORD_WTOpenA 21
  494. #define ORD_WTOpenW 1021
  495. #define ORD_WTOpen WINELIB_NAME_AW(ORD_WTOpen)
  496. #define ORD_WTClose 22
  497. #define ORD_WTPacketsGet 23
  498. #define ORD_WTPacket 24
  499. UINT WINAPI WTInfoA(UINT, UINT, LPVOID);
  500. UINT WINAPI WTInfoW(UINT, UINT, LPVOID);
  501. #define WTInfo WINELIB_NAME_AW(WTInfo)
  502. HCTX WINAPI WTOpenA(HWND, LPLOGCONTEXTA, BOOL);
  503. HCTX WINAPI WTOpenW(HWND, LPLOGCONTEXTW, BOOL);
  504. #define WTOpen WINELIB_NAME_AW(WTOpen)
  505. BOOL WINAPI WTClose(HCTX);
  506. int WINAPI WTPacketsGet(HCTX, int, LPVOID);
  507. BOOL WINAPI WTPacket(HCTX, UINT, LPVOID);
  508. #endif
  509. #ifndef NOWTVISIBILITYFXNS
  510. /* VISIBILITY FUNCTIONS */
  511. #define ORD_WTEnable 40
  512. #define ORD_WTOverlap 41
  513. BOOL WINAPI WTEnable(HCTX, BOOL);
  514. BOOL WINAPI WTOverlap(HCTX, BOOL);
  515. #endif
  516. #ifndef NOWTCTXEDITFXNS
  517. /* CONTEXT EDITING FUNCTIONS */
  518. #define ORD_WTConfig 60
  519. #define ORD_WTGetA 61
  520. #define ORD_WTGetW 1061
  521. #define ORD_WTGet WINELIB_NAME_AW(ORD_WTGet)
  522. #define ORD_WTSetA 62
  523. #define ORD_WTSetW 1062
  524. #define ORD_WTSet WINELIB_NAME_AW(ORD_WTSet)
  525. #define ORD_WTExtGet 63
  526. #define ORD_WTExtSet 64
  527. #define ORD_WTSave 65
  528. #define ORD_WTRestore 66
  529. BOOL WINAPI WTConfig(HCTX, HWND);
  530. BOOL WINAPI WTGetA(HCTX, LPLOGCONTEXTA);
  531. BOOL WINAPI WTGetW(HCTX, LPLOGCONTEXTW);
  532. #define WTGet WINELIB_NAME_AW(WTGet)
  533. BOOL WINAPI WTSetA(HCTX, LPLOGCONTEXTA);
  534. BOOL WINAPI WTSetW(HCTX, LPLOGCONTEXTW);
  535. #define WTSet WINELIB_NAME_AW(WTSet)
  536. BOOL WINAPI WTExtGet(HCTX, UINT, LPVOID);
  537. BOOL WINAPI WTExtSet(HCTX, UINT, LPVOID);
  538. BOOL WINAPI WTSave(HCTX, LPVOID);
  539. HCTX WINAPI WTRestore(HWND, LPVOID, BOOL);
  540. #endif
  541. #ifndef NOWTQUEUEFXNS
  542. /* ADVANCED PACKET AND QUEUE FUNCTIONS */
  543. #define ORD_WTPacketsPeek 80
  544. #define ORD_WTDataGet 81
  545. #define ORD_WTDataPeek 82
  546. #define ORD_WTQueueSizeGet 84
  547. #define ORD_WTQueueSizeSet 85
  548. int WINAPI WTPacketsPeek(HCTX, int, LPVOID);
  549. int WINAPI WTDataGet(HCTX, UINT, UINT, int, LPVOID, LPINT);
  550. int WINAPI WTDataPeek(HCTX, UINT, UINT, int, LPVOID, LPINT);
  551. int WINAPI WTQueueSizeGet(HCTX);
  552. BOOL WINAPI WTQueueSizeSet(HCTX, int);
  553. #endif
  554. #ifndef NOWTHMGRFXNS
  555. /* MANAGER HANDLE FUNCTIONS */
  556. #define ORD_WTMgrOpen 100
  557. #define ORD_WTMgrClose 101
  558. HMGR WINAPI WTMgrOpen(HWND, UINT);
  559. BOOL WINAPI WTMgrClose(HMGR);
  560. #endif
  561. #ifndef NOWTMGRCTXFXNS
  562. /* MANAGER CONTEXT FUNCTIONS */
  563. #define ORD_WTMgrContextEnum 120
  564. #define ORD_WTMgrContextOwner 121
  565. #define ORD_WTMgrDefContext 122
  566. #define ORD_WTMgrDefContextEx 206
  567. BOOL WINAPI WTMgrContextEnum(HMGR, WTENUMPROC, LPARAM);
  568. HWND WINAPI WTMgrContextOwner(HMGR, HCTX);
  569. HCTX WINAPI WTMgrDefContext(HMGR, BOOL);
  570. HCTX WINAPI WTMgrDefContextEx(HMGR, UINT, BOOL); /* 1.1 */
  571. #endif
  572. #ifndef NOWTMGRCONFIGFXNS
  573. /* MANAGER CONFIG BOX FUNCTIONS */
  574. #define ORD_WTMgrDeviceConfig 140
  575. UINT WINAPI WTMgrDeviceConfig(HMGR, UINT, HWND);
  576. #endif
  577. #ifndef NOWTMGRHOOKFXNS
  578. /* MANAGER PACKET HOOK FUNCTIONS */
  579. /* OBSOLETE IN WIN32! */
  580. #endif
  581. #ifndef NOWTMGRPREFFXNS
  582. /* MANAGER PREFERENCE DATA FUNCTIONS */
  583. #define ORD_WTMgrExt 180
  584. #define ORD_WTMgrCsrEnable 181
  585. #define ORD_WTMgrCsrButtonMap 182
  586. #define ORD_WTMgrCsrPressureBtnMarks 183
  587. #define ORD_WTMgrCsrPressureResponse 184
  588. #define ORD_WTMgrCsrExt 185
  589. BOOL WINAPI WTMgrExt(HMGR, UINT, LPVOID);
  590. BOOL WINAPI WTMgrCsrEnable(HMGR, UINT, BOOL);
  591. BOOL WINAPI WTMgrCsrButtonMap(HMGR, UINT, LPBYTE, LPBYTE);
  592. BOOL WINAPI WTMgrCsrPressureBtnMarks(HMGR, UINT, DWORD, DWORD);
  593. BOOL WINAPI WTMgrCsrPressureResponse(HMGR, UINT, UINT *, UINT *);
  594. BOOL WINAPI WTMgrCsrExt(HMGR, UINT, UINT, LPVOID);
  595. #endif
  596. /***********************************************************************
  597. * Win32 replacements for non-portable functions.
  598. */
  599. #ifndef NOWTQUEUEFXNS
  600. /* ADVANCED PACKET AND QUEUE FUNCTIONS */
  601. #define ORD_WTQueuePacketsEx 200
  602. BOOL WINAPI WTQueuePacketsEx(HCTX, UINT *, UINT *);
  603. #endif
  604. #ifndef NOWTMGRCONFIGFXNS
  605. /* MANAGER CONFIG BOX FUNCTIONS */
  606. #define ORD_WTMgrConfigReplaceExA 202
  607. #define ORD_WTMgrConfigReplaceExW 1202
  608. #define ORD_WTMgrConfigReplaceEx WINELIB_NAME_AW(ORD_WTMgrConfigReplaceEx)
  609. BOOL WINAPI WTMgrConfigReplaceExA(HMGR, BOOL, LPSTR, LPSTR);
  610. BOOL WINAPI WTMgrConfigReplaceExW(HMGR, BOOL, LPWSTR, LPSTR);
  611. #define WTMgrConfigReplaceEx WINELIB_NAME_AW(WTMgrConfigReplaceEx)
  612. #endif
  613. #ifndef NOWTMGRHOOKFXNS
  614. /* MANAGER PACKET HOOK FUNCTIONS */
  615. #define ORD_WTMgrPacketHookExA 203
  616. #define ORD_WTMgrPacketHookExW 1203
  617. #define ORD_WTMgrPacketHookEx WINELIB_NAME_AW(ORD_WTMgrPacketHookEx)
  618. #define ORD_WTMgrPacketUnhook 204
  619. #define ORD_WTMgrPacketHookNext 205
  620. HWTHOOK WINAPI WTMgrPacketHookExA(HMGR, int, LPSTR, LPSTR);
  621. HWTHOOK WINAPI WTMgrPacketHookExW(HMGR, int, LPWSTR, LPSTR);
  622. #define WTMgrPacketHookEx WINELIB_NAME_AW(WTMgrPacketHookEx)
  623. BOOL WINAPI WTMgrPacketUnhook(HWTHOOK);
  624. LRESULT WINAPI WTMgrPacketHookNext(HWTHOOK, int, WPARAM, LPARAM);
  625. #endif
  626. #ifndef NOWTMGRPREFFXNS
  627. /* MANAGER PREFERENCE DATA FUNCTIONS */
  628. #define ORD_WTMgrCsrPressureBtnMarksEx 201
  629. BOOL WINAPI WTMgrCsrPressureBtnMarksEx(HMGR, UINT, UINT *, UINT *);
  630. #endif
  631. #endif
  632. #ifdef __cplusplus
  633. } /* extern "C" */
  634. #endif /* defined(__cplusplus) */
  635. #endif /* defined(__WINE_WINTAB_H */