annotate semiconginev2/thirdparty/x11/xtst.nim @ 1237:97813ac43cfb

add: multi-text with all properties animated
author sam <sam@basx.dev>
date Sun, 21 Jul 2024 00:03:48 +0700
parents 56781cc0fc7c
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1191
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
1 import x, xlib, xinput
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
2
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
3 const
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
4 libXtst = "libXtst.so(.6|)"
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
5
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
6 recordName* = "RECORD"
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
7 recordMajorVersion* = 1
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
8 recordMinorVersion* = 13
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
9 recordLowestMajorVersion* = 1
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
10 recordLowestMinorVersion* = 12
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
11
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
12 xRecordBadContext* = 0
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
13
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
14 recordNumErrors* = xRecordBadContext + 1
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
15 recordNumEvents* = 0
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
16
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
17 xRecordFromServerTime* = 0x01
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
18 xRecordFromClientTime* = 0x02
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
19 xRecordFromClientSequence* = 0x04
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
20
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
21 xRecordCurrentClients* = 1
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
22 xRecordFutureClients* = 2
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
23 xRecordAllClients* = 3
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
24
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
25 XRecordFromServer* = 0
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
26 XRecordFromClient* = 1
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
27 XRecordClientStarted* = 2
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
28 XRecordClientDied* = 3
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
29 XRecordStartOfData* = 4
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
30 XRecordEndOfData* = 5
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
31
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
32 type
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
33 PXRecordClientSpec* = ptr XRecordClientSpec
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
34 XRecordClientSpec* = culong
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
35
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
36 PXRecordContext* = ptr XRecordContext
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
37 XRecordContext* = culong
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
38
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
39 PXRecordRange8* = ptr XRecordRange8
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
40 XRecordRange8* {.final.} = object
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
41 first*: cuchar
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
42 last*: cuchar
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
43
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
44 PXRecordRange16* = ptr XRecordRange16
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
45 XRecordRange16* {.final.} = object
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
46 first*: cushort
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
47 last*: cushort
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
48
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
49 PXRecordExtRange* = ptr XRecordExtRange
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
50 XRecordExtRange* {.final.} = object
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
51 ext_major*: XRecordRange8
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
52 ext_minor*: XRecordRange16
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
53
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
54 PXRecordRange* = ptr XRecordRange
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
55 XRecordRange* {.final.} = object
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
56 core_requests*: XRecordRange8 ## core X requests
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
57 core_replies*: XRecordRange8 ## core X replies
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
58 ext_requests*: XRecordExtRange ## extension requests
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
59 ext_replies*: XRecordExtRange ## extension replies
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
60 delivered_events*: XRecordRange8 ## delivered core and ext events
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
61 device_events*: XRecordRange8 ## all core and ext device events
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
62 errors*: XRecordRange8 ## core X and ext errors
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
63 client_started*: XBool ## connection setup reply
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
64 client_died*: XBool ## notice of client disconnect
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
65
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
66 PXRecordClientInfo* = ptr XRecordClientInfo
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
67 XRecordClientInfo* {.final.} = object
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
68 client*: XRecordClientSpec
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
69 nranges*: culong
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
70 ranges*: ptr UncheckedArray[XRecordRange]
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
71
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
72 PXRecordState* = ptr XRecordState
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
73 XRecordState* {.final.} = object
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
74 enabled*: XBool
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
75 datum_flags*: cint
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
76 nclients*: culong
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
77 client_info*: ptr UncheckedArray[XRecordClientInfo]
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
78
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
79 PXRecordInterceptData* = ptr XRecordInterceptData
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
80 XRecordInterceptData* {.final.} = object
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
81 id_base*: XID
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
82 server_time*: Time
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
83 client_seq*: culong
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
84 category*: cint
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
85 client_swapped*: XBool
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
86 data*: cstring
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
87 data_len*: culong ## in 4-byte units
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
88
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
89 XRecordInterceptProc* = proc (a1: XPointer, a2: PXRecordInterceptData)
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
90
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
91 {.push cdecl, importc, dynlib: libXtst.}
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
92
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
93 proc XRecordIdBaseMask*(dpy: PDisplay): XID
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
94 proc XRecordQueryVersion*(a1: PDisplay, a2, a3: ptr cint): Status
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
95 proc XRecordCreateContext*(a1: PDisplay,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
96 a2: cint, a3: PXRecordClientSpec,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
97 a4: cint, a5: ptr UncheckedArray[XRecordRange],
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
98 a6: cint): XRecordContext
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
99 proc XRecordAllocRange*: PXRecordRange
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
100 proc XRecordRegisterClients*(a1: PDisplay,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
101 a2: XRecordContext,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
102 a3: cint, a4: PXRecordClientSpec,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
103 a5: cint, a6: ptr UncheckedArray[XRecordRange],
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
104 a7: cint): Status
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
105 proc XRecordUnregisterClients*(a1: PDisplay,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
106 a2: XRecordContext,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
107 a3: PXRecordClientSpec,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
108 a4: cint): Status
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
109 proc XRecordGetContext*(a1: PDisplay,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
110 a2: XRecordContext,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
111 a3: ptr UncheckedArray[XRecordState]): Status
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
112 proc XRecordFreeState*(a1: PXRecordState)
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
113 proc XRecordEnableContext*(a1: PDisplay,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
114 a2: XRecordContext,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
115 a3: XRecordInterceptProc,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
116 a4: XPointer): Status
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
117 proc XRecordEnableContextAsync*(a1: PDisplay, a2: XRecordContext,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
118 a3: XRecordInterceptProc,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
119 a4: XPointer): Status
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
120 proc XRecordProcessReplies*(a1: PDisplay)
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
121 proc XRecordFreeData*(a1: PXRecordInterceptData)
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
122 proc XRecordDisableContext*(a1: PDisplay, a2: XRecordContext): Status
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
123 proc XRecordFreeContext*(a1: PDisplay, a2: XRecordContext): Status
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
124 proc XTestQueryExtension*(a1: PDisplay, a2, a3, a4, a5: ptr cint): XBool
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
125 proc XTestCompareCursorWithWindow*(a1: PDisplay, a2: Window, a3: Cursor): XBool
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
126 proc XTestCompareCurrentCursorWithWindow*(a1: PDisplay, a2: Window): XBool
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
127 proc XTestFakeKeyEvent*(a1: PDisplay, a2: cuint, a3: XBool, a4: culong): cint
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
128 proc XTestFakeButtonEvent*(a1: PDisplay, a2: cuint, a3: XBool, a4: culong): cint
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
129 proc XTestFakeMotionEvent*(a1: PDisplay, a2, a3, a4: cint, a5: culong): cint
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
130 proc XTestFakeRelativeMotionEvent*(a1: PDisplay, a2, a3: cint, a4: culong): cint
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
131 proc XTestFakeDeviceKeyEvent*(a1: PDisplay, a2: PXDevice, a3: cuint, a4: XBool,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
132 a5: ptr cint, a6: cint, a7: culong): cint
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
133 proc XTestFakeDeviceButtonEvent*(a1: PDisplay, a2: PXDevice, a3: cuint, a4: XBool,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
134 a5: ptr cint, a6: cint, a7: culong): cint
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
135 proc XTestFakeProximityEvent*(a1: PDisplay, a2: PXDevice, a3: XBool, a4: ptr cint,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
136 a5: cint, a6: culong): cint
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
137 proc XTestFakeDeviceMotionEvent*(a1: PDisplay, a2: PXDevice, a3: XBool, a4: cint,
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
138 a5: ptr cint, a6: cint, a7: culong): cint
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
139 proc XTestGrabControl*(a1: PDisplay, a2: XBool): cint
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
140 proc XTestSetGContextOfGC*(a1: GC, a2: GContext)
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
141 proc XTestSetVisualIDOfVisual*(a1: PVisual, a2: VisualID)
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
142 proc XTestDiscard*(a1: PDisplay): Status
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
143
239adab121a3 sync from bedroom to office
sam <sam@basx.dev>
parents:
diff changeset
144 {.pop.}