xutil.pp 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903
  1. {
  2. $Id$
  3. }
  4. Unit XUtil;
  5. interface
  6. uses
  7. x,xlib;
  8. {$LinkLib c}
  9. {$LinkLib X11}
  10. {
  11. Bitmask returned by XParseGeometry(). Each bit tells if the corresponding
  12. value (x, y, width, height) was found in the parsed string.
  13. }
  14. Const
  15. NoValue = $0000;
  16. XValue = $0001;
  17. YValue = $0002;
  18. WidthValue = $0004;
  19. HeightValue = $0008;
  20. AllValues = $000F;
  21. XNegative = $0010;
  22. YNegative = $0020;
  23. {
  24. new version containing base_width, base_height, and win_gravity fields;
  25. used with WM_NORMAL_HINTS.
  26. }
  27. Type
  28. long = Cardinal; { Untill we know better. M.}
  29. Type
  30. TAspectRecord = record
  31. x,y : longint;
  32. end;
  33. TXSizeHints = record
  34. flags : Long; { marks which fields in this structure are defined }
  35. x, y : longint ; { obsolete for new window mgrs, but clients }
  36. width, height: longint ; { should set so old wm's don't mess up }
  37. min_width, min_height : longint ;
  38. max_width, max_height : longint ;
  39. width_inc, height_inc : longint ;
  40. min_aspect, max_aspect : TAspectRecord;
  41. base_width, base_height : longint ; { added by ICCCM version 1 }
  42. win_gravity : longint ; { added by ICCCM version 1 }
  43. end;
  44. PXSizeHints=^TXSizeHints;
  45. {
  46. The next block of definitions are for window manager properties that
  47. clients and applications use for communication.
  48. }
  49. { flags argument in size hints }
  50. Const
  51. USPosition = 1 shl 0; { user specified x, y }
  52. USSize = 1 shl 1; { user specified width, height }
  53. PPosition = 1 shl 2; { program specified position }
  54. PSize = 1 shl 3; { program specified size }
  55. PMinSize = 1 shl 4; { program specified minimum size }
  56. PMaxSize = 1 shl 5; { program specified maximum size }
  57. PResizeInc = 1 shl 6; { program specified resize increments }
  58. PAspect = 1 shl 7; { program specified min and max aspect ratios }
  59. PBaseSize = 1 shl 8; { program specified base for incrementing }
  60. PWinGravity = 1 shl 9; { program specified window gravity }
  61. { obsolete }
  62. PAllHints = PPosition or PSize or PMinSize or PMaxSize or PResizeInc or PAspect;
  63. Type
  64. TXWMHints = record
  65. flags : long; { marks which fields in this structure are defined }
  66. input : TBool ; { does this application rely on the window manager to
  67. get keyboard input? }
  68. initial_state : longint ; { see below }
  69. icon_pixmap : TPixmap ; { pixmap to be used as icon }
  70. icon_window : TWindow ; { window to be used as icon }
  71. icon_x, icon_y : longint ; { initial position of icon }
  72. icon_mask : TPixmap ; { icon mask bitmap }
  73. window_group : TXID ; { id of related window group }
  74. { this structure may be extended in the future }
  75. end;
  76. { definition for flags of XWMHints }
  77. Const
  78. InputHint = 1 shl 0;
  79. StateHint = 1 shl 1;
  80. IconPixmapHint = 1 shl 2;
  81. IconWindowHint = 1 shl 3;
  82. IconPositionHint = 1 shl 4;
  83. IconMaskHint = 1 shl 5;
  84. AllHints = InputHint or StateHint or IconPixmapHint or IconWindowHint or
  85. IconPositionHint or IconMaskHint {or WindowGroupHint};
  86. XUrgencyHint = 1 shl 8;
  87. { definitions for initial window state }
  88. WithdrawnState = 0; { for windows that are not mapped }
  89. NormalState = 1; { most applications want to start this way }
  90. IconicState = 3; { application wants to start as an icon }
  91. { Obsolete states no longer defined by ICCCM }
  92. DontCareState = 0; { don't know or care }
  93. ZoomState = 2; { application wants to start zoomed }
  94. InactiveState = 4; { application believes it is seldom used; }
  95. { some wm's may put it on inactive menu }
  96. {
  97. new structure for manipulating TEXT properties; used with WM_NAME,
  98. WM_ICON_NAME, WM_CLIENT_MACHINE, and WM_COMMAND.
  99. }
  100. type
  101. TXTextProperty = record
  102. value : pchar; { same as Property routines }
  103. encoding : TAtom; { prop type }
  104. format : longint ; { prop data format: 8, 16, or 32 }
  105. nitems : Cardinal; { number of data items in value }
  106. end;
  107. PXTextProperty = ^TXTextProperty;
  108. Const
  109. XNoMemory =-1;
  110. XLocaleNotSupported =-2;
  111. XConverterNotFound =-3;
  112. Type
  113. TXICCEncodingStyle = longint;
  114. Const
  115. XStringStyle = 0; { STRING }
  116. XCompoundTextStyle = 1; { COMPOUND_TEXT }
  117. XTextStyle = 2; { text in owner's encoding (current locale)}
  118. XStdICCTextStyle = 3; { STRING, else COMPOUND_TEXT }
  119. Type
  120. TXIconSize = record
  121. min_width, min_height,
  122. max_width, max_height,
  123. width_inc, height_inc : longint;
  124. end;
  125. PXIconSize = ^TXIconSize;
  126. type
  127. TXClassHint = record
  128. res_name,
  129. res_class : pchar;
  130. end;
  131. PXClassHint = ^TXClassHint;
  132. {
  133. * These macros are used to give some sugar to the image routines so that
  134. * naive people are more comfortable with them.
  135. }
  136. {
  137. XDestroyImage(ximage) \
  138. ((*((ximage)->f.destroy_image))((ximage)))
  139. XGetPixel(ximage, x, y) \
  140. ((*((ximage)->f.get_pixel))((ximage), (x), (y)))
  141. XPutPixel(ximage, x, y, pixel) \
  142. ((*((ximage)->f.put_pixel))((ximage), (x), (y), (pixel)))
  143. XSubImage(ximage, x, y, width, height) \
  144. ((*((ximage)->f.sub_image))((ximage), (x), (y), (width), (height)))
  145. XAddPixel(ximage, value) \
  146. ((*((ximage)->f.add_pixel))((ximage), (value)))
  147. }
  148. {
  149. * Compose sequence status structure, used in calling XLookupString.
  150. }
  151. TXComposeStatus = record
  152. compose_ptr : TXPointer ; { state table pointer }
  153. chars_matched : longint ; { match state }
  154. end;
  155. PTXComposeStatus = ^TXComposeStatus;
  156. {
  157. * Keysym macros, used on Keysyms to test for classes of symbols
  158. }
  159. {
  160. IsKeypadKey(keysym) \
  161. (((KeySym)(keysym) >= XK_KP_Space) && ((KeySym)(keysym) <= XK_KP_Equal))
  162. IsPrivateKeypadKey(keysym) \
  163. (((KeySym)(keysym) >= 0x11000000) && ((KeySym)(keysym) <= 0x1100FFFF))
  164. IsCursorKey(keysym) \
  165. (((KeySym)(keysym) >= XK_Home) && ((KeySym)(keysym) < XK_Select))
  166. IsPFKey(keysym) \
  167. (((KeySym)(keysym) >= XK_KP_F1) && ((KeySym)(keysym) <= XK_KP_F4))
  168. IsFunctionKey(keysym) \
  169. (((KeySym)(keysym) >= XK_F1) && ((KeySym)(keysym) <= XK_F35))
  170. IsMiscFunctionKey(keysym) \
  171. (((KeySym)(keysym) >= XK_Select) && ((KeySym)(keysym) <= XK_Break))
  172. IsModifierKey(keysym) \
  173. ((((KeySym)(keysym) >= XK_Shift_L) && ((KeySym)(keysym) <= XK_Hyper_R)) \
  174. or or ((KeySym)(keysym) == XK_Mode_switch) \
  175. or or ((KeySym)(keysym) == XK_Num_Lock))
  176. }
  177. {
  178. * opaque reference to Region data type
  179. }
  180. {
  181. typedef struct _XRegion *Region;
  182. }
  183. { Return values from XRectInRegion() }
  184. Const
  185. RectangleOut =0;
  186. RectangleIn =1;
  187. RectanglePart=2;
  188. {
  189. * Information used by the visual utility routines to find desired visual
  190. * type from the many visuals a display may support.
  191. }
  192. Type
  193. TXVisualInfo = record
  194. visual : PVisual;
  195. visualid : TVisualID ;
  196. screen : longint;
  197. depth : longint;
  198. c_class : longint;
  199. red_mask : cardinal;
  200. green_mask : cardinal;
  201. blue_mask : Cardinal;
  202. colormap_size : longint;
  203. bits_per_rgb : longint;
  204. end;
  205. PXVisualInfo = ^TXVisualInfo;
  206. Const
  207. VisualNoMask = $0;
  208. VisualIDMask = $1;
  209. VisualScreenMask = $2;
  210. VisualDepthMask = $4;
  211. VisualClassMask = $8;
  212. VisualRedMaskMask = $10;
  213. VisualGreenMaskMask = $20;
  214. VisualBlueMaskMask = $40;
  215. VisualColormapSizeMask = $80;
  216. VisualBitsPerRGBMask = $100;
  217. VisualAllMask = $1FF;
  218. {
  219. * This defines a window manager property that clients may use to
  220. * share standard color maps of type RGB_COLOR_MAP:
  221. }
  222. Type
  223. TXStandardColormap = record
  224. colormap : TColormap ;
  225. red_max : Cardinal;
  226. red_mult : Cardinal;
  227. green_max : Cardinal;
  228. green_mult : Cardinal;
  229. blue_max : Cardinal;
  230. blue_mult : Cardinal;
  231. base_pixel : Cardinal;
  232. visualid : TVisualID; { added by ICCCM version 1 }
  233. killid : TXID ; { added by ICCCM version 1 }
  234. end;
  235. PXStandardColormap= ^TXStandardColormap;
  236. Const
  237. ReleaseByFreeingColormap = 1; { for killid field above }
  238. { return codes for XReadBitmapFile and XWriteBitmapFile }
  239. BitmapSuccess =0;
  240. BitmapOpenFailed =1;
  241. BitmapFileInvalid =2;
  242. BitmapNoMemory =3;
  243. {***************************************************************
  244. * Context Management
  245. ***************************************************************}
  246. const
  247. { Associative lookup table return codes }
  248. XCSUCCESS =0; { No error. }
  249. XCNOMEM =1; { Out of memory }
  250. XCNOENT =2; { No entry in table }
  251. type
  252. TXContext = longint;
  253. {
  254. XUniqueContext() ((XContext) XrmUniqueQuark())
  255. XStringToContext(string) ((XContext) XrmStringToQuark(string))
  256. }
  257. function XGetVisualInfo(display: PDisplay; vinfo_mask: LongInt;
  258. vinfo_template: PXVisualInfo; var nitems_return: longint): PXVisualInfo;
  259. cdecl; external;
  260. (*
  261. _XFUNCPROTOBEGIN
  262. { The following declarations are alphabetized. }
  263. extern XClassHlongint *XAllocClassHlongint (
  264. #if NeedFunctionPrototypes
  265. void
  266. #endif
  267. );
  268. extern XIconSize *XAllocIconSize (
  269. #if NeedFunctionPrototypes
  270. void
  271. #endif
  272. );
  273. extern XSizeHints *XAllocSizeHints (
  274. #if NeedFunctionPrototypes
  275. void
  276. #endif
  277. );
  278. extern XStandardColormap *XAllocStandardColormap (
  279. #if NeedFunctionPrototypes
  280. void
  281. #endif
  282. );
  283. extern XWMHints *XAllocWMHints (
  284. #if NeedFunctionPrototypes
  285. void
  286. #endif
  287. );
  288. extern XClipBox(
  289. #if NeedFunctionPrototypes
  290. Region { r },
  291. XRectangle* { rect_return }
  292. #endif
  293. );
  294. extern Region XCreateRegion(
  295. #if NeedFunctionPrototypes
  296. void
  297. #endif
  298. );
  299. extern char *XDefaultString(
  300. #if NeedFunctionPrototypes
  301. void
  302. #endif
  303. );
  304. extern longint XDeleteContext(
  305. #if NeedFunctionPrototypes
  306. Display* { display },
  307. XID { rid },
  308. XContext { context }
  309. #endif
  310. );
  311. extern XDestroyRegion(
  312. #if NeedFunctionPrototypes
  313. Region { r }
  314. #endif
  315. );
  316. extern XEmptyRegion(
  317. #if NeedFunctionPrototypes
  318. Region { r }
  319. #endif
  320. );
  321. extern XEqualRegion(
  322. #if NeedFunctionPrototypes
  323. Region { r1 },
  324. Region { r2 }
  325. #endif
  326. );
  327. extern longint XFindContext(
  328. #if NeedFunctionPrototypes
  329. Display* { display },
  330. XID { rid },
  331. XContext { context },
  332. XPointer* { data_return }
  333. #endif
  334. );
  335. extern Status XGetClassHint(
  336. #if NeedFunctionPrototypes
  337. Display* { display },
  338. Window { w },
  339. XClassHint* { class_hints_return }
  340. #endif
  341. );
  342. extern Status XGetIconSizes(
  343. #if NeedFunctionPrototypes
  344. Display* { display },
  345. Window { w },
  346. XIconSize** { size_list_return },
  347. int* { count_return }
  348. #endif
  349. );
  350. extern Status XGetNormalHints(
  351. #if NeedFunctionPrototypes
  352. Display* { display },
  353. Window { w },
  354. XSizeHints* { hints_return }
  355. #endif
  356. );
  357. extern Status XGetRGBColormaps(
  358. #if NeedFunctionPrototypes
  359. Display* { display },
  360. Window { w },
  361. XStandardColormap** { stdcmap_return },
  362. int* { count_return },
  363. Atom { property }
  364. #endif
  365. );
  366. extern Status XGetSizeHints(
  367. #if NeedFunctionPrototypes
  368. Display* { display },
  369. Window { w },
  370. XSizeHints* { hints_return },
  371. Atom { property }
  372. #endif
  373. );
  374. extern Status XGetStandardColormap(
  375. #if NeedFunctionPrototypes
  376. Display* { display },
  377. Window { w },
  378. XStandardColormap* { colormap_return },
  379. Atom { property }
  380. #endif
  381. );
  382. extern Status XGetTextProperty(
  383. #if NeedFunctionPrototypes
  384. Display* { display },
  385. Window { window },
  386. XTextProperty* { text_prop_return },
  387. Atom { property }
  388. #endif
  389. );
  390. extern XVisualInfo *XGetVisualInfo(
  391. #if NeedFunctionPrototypes
  392. Display* { display },
  393. long { vinfo_mask },
  394. XVisualInfo* { vinfo_template },
  395. int* { nitems_return }
  396. #endif
  397. );
  398. extern Status XGetWMClientMachine(
  399. #if NeedFunctionPrototypes
  400. Display* { display },
  401. Window { w },
  402. XTextProperty* { text_prop_return }
  403. #endif
  404. );
  405. extern XWMHints *XGetWMHints(
  406. #if NeedFunctionPrototypes
  407. Display* { display },
  408. Window { w }
  409. #endif
  410. );
  411. extern Status XGetWMIconName(
  412. #if NeedFunctionPrototypes
  413. Display* { display },
  414. Window { w },
  415. XTextProperty* { text_prop_return }
  416. #endif
  417. );
  418. extern Status XGetWMName(
  419. #if NeedFunctionPrototypes
  420. Display* { display },
  421. Window { w },
  422. XTextProperty* { text_prop_return }
  423. #endif
  424. );
  425. extern Status XGetWMNormalHints(
  426. #if NeedFunctionPrototypes
  427. Display* { display },
  428. Window { w },
  429. XSizeHints* { hints_return },
  430. long* { supplied_return }
  431. #endif
  432. );
  433. extern Status XGetWMSizeHints(
  434. #if NeedFunctionPrototypes
  435. Display* { display },
  436. Window { w },
  437. XSizeHints* { hints_return },
  438. long* { supplied_return },
  439. Atom { property }
  440. #endif
  441. );
  442. extern Status XGetZoomHints(
  443. #if NeedFunctionPrototypes
  444. Display* { display },
  445. Window { w },
  446. XSizeHints* { zhints_return }
  447. #endif
  448. );
  449. extern XIntersectRegion(
  450. #if NeedFunctionPrototypes
  451. Region { sra },
  452. Region { srb },
  453. Region { dr_return }
  454. #endif
  455. );
  456. extern void XConvertCase(
  457. #if NeedFunctionPrototypes
  458. KeySym { sym },
  459. KeySym* { lower },
  460. KeySym* { upper }
  461. #endif
  462. );
  463. extern longint XLookupString(
  464. #if NeedFunctionPrototypes
  465. XKeyEvent* { event_struct },
  466. char* { buffer_return },
  467. int { bytes_buffer },
  468. KeySym* { keysym_return },
  469. XComposeStatus* { status_in_out }
  470. #endif
  471. );
  472. extern Status XMatchVisualInfo(
  473. #if NeedFunctionPrototypes
  474. Display* { display },
  475. int { screen },
  476. int { depth },
  477. int { class },
  478. XVisualInfo* { vinfo_return }
  479. #endif
  480. );
  481. extern XOffsetRegion(
  482. #if NeedFunctionPrototypes
  483. Region { r },
  484. int { dx },
  485. int { dy }
  486. #endif
  487. );
  488. extern Bool XPointInRegion(
  489. #if NeedFunctionPrototypes
  490. Region { r },
  491. int { x },
  492. int { y }
  493. #endif
  494. );
  495. extern Region XPolygonRegion(
  496. #if NeedFunctionPrototypes
  497. XPoint* { points },
  498. int { n },
  499. int { fill_rule }
  500. #endif
  501. );
  502. extern longint XRectInRegion(
  503. #if NeedFunctionPrototypes
  504. Region { r },
  505. int { x },
  506. int { y },
  507. unsigned int { width },
  508. unsigned int { height }
  509. #endif
  510. );
  511. extern longint XSaveContext(
  512. #if NeedFunctionPrototypes
  513. Display* { display },
  514. XID { rid },
  515. XContext { context },
  516. _Xconst char* { data }
  517. #endif
  518. );
  519. extern XSetClassHint(
  520. #if NeedFunctionPrototypes
  521. Display* { display },
  522. Window { w },
  523. XClassHint* { class_hints }
  524. #endif
  525. );
  526. extern XSetIconSizes(
  527. #if NeedFunctionPrototypes
  528. Display* { display },
  529. Window { w },
  530. XIconSize* { size_list },
  531. int { count }
  532. #endif
  533. );
  534. extern XSetNormalHints(
  535. #if NeedFunctionPrototypes
  536. Display* { display },
  537. Window { w },
  538. XSizeHints* { hints }
  539. #endif
  540. );
  541. extern void XSetRGBColormaps(
  542. #if NeedFunctionPrototypes
  543. Display* { display },
  544. Window { w },
  545. XStandardColormap* { stdcmaps },
  546. int { count },
  547. Atom { property }
  548. #endif
  549. );
  550. extern XSetSizeHints(
  551. #if NeedFunctionPrototypes
  552. Display* { display },
  553. Window { w },
  554. XSizeHints* { hints },
  555. Atom { property }
  556. #endif
  557. );
  558. extern XSetStandardProperties(
  559. #if NeedFunctionPrototypes
  560. Display* { display },
  561. Window { w },
  562. _Xconst char* { window_name },
  563. _Xconst char* { icon_name },
  564. Pixmap { icon_pixmap },
  565. char** { argv },
  566. int { argc },
  567. XSizeHints* { hints }
  568. #endif
  569. );
  570. extern void XSetTextProperty(
  571. #if NeedFunctionPrototypes
  572. Display* { display },
  573. Window { w },
  574. XTextProperty* { text_prop },
  575. Atom { property }
  576. #endif
  577. );
  578. extern void XSetWMClientMachine(
  579. #if NeedFunctionPrototypes
  580. Display* { display },
  581. Window { w },
  582. XTextProperty* { text_prop }
  583. #endif
  584. );
  585. extern XSetWMHints(
  586. #if NeedFunctionPrototypes
  587. Display* { display },
  588. Window { w },
  589. XWMHints* { wm_hints }
  590. #endif
  591. );
  592. extern void XSetWMIconName(
  593. #if NeedFunctionPrototypes
  594. Display* { display },
  595. Window { w },
  596. XTextProperty* { text_prop }
  597. #endif
  598. );
  599. extern void XSetWMName(
  600. #if NeedFunctionPrototypes
  601. Display* { display },
  602. Window { w },
  603. XTextProperty* { text_prop }
  604. #endif
  605. );
  606. extern void XSetWMNormalHints(
  607. #if NeedFunctionPrototypes
  608. Display* { display },
  609. Window { w },
  610. XSizeHints* { hints }
  611. #endif
  612. );
  613. extern void XSetWMProperties(
  614. #if NeedFunctionPrototypes
  615. Display* { display },
  616. Window { w },
  617. XTextProperty* { window_name },
  618. XTextProperty* { icon_name },
  619. char** { argv },
  620. int { argc },
  621. XSizeHints* { normal_hints },
  622. XWMHints* { wm_hints },
  623. XClassHint* { class_hints }
  624. #endif
  625. );
  626. extern void XmbSetWMProperties(
  627. #if NeedFunctionPrototypes
  628. Display* { display },
  629. Window { w },
  630. _Xconst char* { window_name },
  631. _Xconst char* { icon_name },
  632. char** { argv },
  633. int { argc },
  634. XSizeHints* { normal_hints },
  635. XWMHints* { wm_hints },
  636. XClassHint* { class_hints }
  637. #endif
  638. );
  639. extern void XSetWMSizeHints(
  640. #if NeedFunctionPrototypes
  641. Display* { display },
  642. Window { w },
  643. XSizeHints* { hints },
  644. Atom { property }
  645. #endif
  646. );
  647. extern XSetRegion(
  648. #if NeedFunctionPrototypes
  649. Display* { display },
  650. GC { gc },
  651. Region { r }
  652. #endif
  653. );
  654. extern void XSetStandardColormap(
  655. #if NeedFunctionPrototypes
  656. Display* { display },
  657. Window { w },
  658. XStandardColormap* { colormap },
  659. Atom { property }
  660. #endif
  661. );
  662. extern XSetZoomHints(
  663. #if NeedFunctionPrototypes
  664. Display* { display },
  665. Window { w },
  666. XSizeHints* { zhints }
  667. #endif
  668. );
  669. extern XShrinkRegion(
  670. #if NeedFunctionPrototypes
  671. Region { r },
  672. int { dx },
  673. int { dy }
  674. #endif
  675. );
  676. extern Status XStringListToTextProperty(
  677. #if NeedFunctionPrototypes
  678. char** { list },
  679. int { count },
  680. XTextProperty* { text_prop_return }
  681. #endif
  682. );
  683. extern XSubtractRegion(
  684. #if NeedFunctionPrototypes
  685. Region { sra },
  686. Region { srb },
  687. Region { dr_return }
  688. #endif
  689. );
  690. extern longint XmbTextListToTextProperty(
  691. #if NeedFunctionPrototypes
  692. Display* { display },
  693. char** { list },
  694. int { count },
  695. XICCEncodingStyle { style },
  696. XTextProperty* { text_prop_return }
  697. #endif
  698. );
  699. extern longint XwcTextListToTextProperty(
  700. #if NeedFunctionPrototypes
  701. Display* { display },
  702. wchar_t** { list },
  703. int { count },
  704. XICCEncodingStyle { style },
  705. XTextProperty* { text_prop_return }
  706. #endif
  707. );
  708. extern void XwcFreeStringList(
  709. #if NeedFunctionPrototypes
  710. wchar_t** { list }
  711. #endif
  712. );
  713. extern Status XTextPropertyToStringList(
  714. #if NeedFunctionPrototypes
  715. XTextProperty* { text_prop },
  716. char*** { list_return },
  717. int* { count_return }
  718. #endif
  719. );
  720. extern longint XmbTextPropertyToTextList(
  721. #if NeedFunctionPrototypes
  722. Display* { display },
  723. XTextProperty* { text_prop },
  724. char*** { list_return },
  725. int* { count_return }
  726. #endif
  727. );
  728. extern longint XwcTextPropertyToTextList(
  729. #if NeedFunctionPrototypes
  730. Display* { display },
  731. XTextProperty* { text_prop },
  732. wchar_t*** { list_return },
  733. int* { count_return }
  734. #endif
  735. );
  736. extern XUnionRectWithRegion(
  737. #if NeedFunctionPrototypes
  738. XRectangle* { rectangle },
  739. Region { src_region },
  740. Region { dest_region_return }
  741. #endif
  742. );
  743. extern XUnionRegion(
  744. #if NeedFunctionPrototypes
  745. Region { sra },
  746. Region { srb },
  747. Region { dr_return }
  748. #endif
  749. );
  750. extern longint XWMGeometry(
  751. #if NeedFunctionPrototypes
  752. Display* { display },
  753. int { screen_number },
  754. _Xconst char* { user_geometry },
  755. _Xconst char* { default_geometry },
  756. unsigned int { border_width },
  757. XSizeHints* { hints },
  758. int* { x_return },
  759. int* { y_return },
  760. int* { width_return },
  761. int* { height_return },
  762. int* { gravity_return }
  763. #endif
  764. );
  765. extern XXorRegion(
  766. #if NeedFunctionPrototypes
  767. Region { sra },
  768. Region { srb },
  769. Region { dr_return }
  770. #endif
  771. );
  772. _XFUNCPROTOEND
  773. #endif { _XUTIL_H_ }
  774. *)
  775. Implementation
  776. end.
  777. {
  778. $Log$
  779. Revision 1.6 2000-03-06 16:15:43 peter
  780. * removed comment warnings
  781. Revision 1.5 2000/03/01 09:16:13 sg
  782. * Changed all occurences of $linklib C into $linklib c
  783. Revision 1.4 2000/02/27 14:39:54 peter
  784. * added explicit linklib c
  785. Revision 1.3 2000/02/27 13:11:31 peter
  786. * cleanup, removed warnings
  787. * external decls moved from implementation to interface
  788. }