1XtAddEventHandler(3)             XT FUNCTIONS             XtAddEventHandler(3)
2
3
4

NAME

6       XtAddEventHandler, XtAddRawEventHandler, XtRemoveEventHandler,
7       XtRemoveRawEventHandler, XtInsertEventHandler, XtInsertRawEventHandler
8       - add and remove event handlers
9

SYNTAX

11       #include <X11/Intrinsic.h>
12
13       void XtAddEventHandler(Widget w, EventMask event_mask, Boolean nonmask‐
14              able, XtEventHandler proc, XtPointer client_data);
15
16       void XtAddRawEventHandler(Widget w, EventMask event_mask, Boolean non‐
17              maskable, XtEventHandler proc, XtPointer client_data);
18
19       void XtRemoveEventHandler(Widget w, EventMask event_mask, Boolean non‐
20              maskable, XtEventHandler proc, XtPointer client_data);
21
22       void XtRemoveRawEventHandler(Widget w, EventMask event_mask, Boolean
23              nonmaskable, XtEventHandler proc, XtPointer client_data);
24
25       void XtInsertEventHandler(Widget w, EventMask event_mask, Boolean non‐
26              maskable, XtEventHandler proc, XtPointer client_data, XtListPo‐
27              sition position);
28
29       void XtInsertRawEventHandler(Widget w, EventMask event_mask, Boolean
30              nonmaskable, XtEventHandler proc, XtPointer client_data, XtList‐
31              Position position);
32
33       typedef enum { XtListHead, XtListTail } XtListPosition;
34

ARGUMENTS

36       client_data
37                 Specifies additional data to be passed to the client's event
38                 handler.
39
40       event_mask
41                 Specifies the event mask for which to call or unregister this
42                 procedure.
43
44       nonmaskable
45                 Specifies a Boolean value that indicates whether this proce‐
46                 dure should be called or removed on the nonmaskable events (
47                 GraphicsExpose, NoExpose, SelectionClear, SelectionRequest,
48                 SelectionNotify, ClientMessage, and MappingNotify).
49
50       proc      Specifies the procedure that is to be added or removed.
51
52       w         Specifies the widget for which this event handler is being
53                 registered.
54
55       position  Specifies when the event handler is to be called relative to
56                 other previously registered handlers.
57

DESCRIPTION

59       The XtAddEventHandler function registers a procedure with the dispatch
60       mechanism that is to be called when an event that matches the mask
61       occurs on the specified widget.  If the procedure is already registered
62       with the same client_data, the specified mask is ORed into the existing
63       mask.  If the widget is realized, XtAddEventHandler calls XSelectInput,
64       if necessary.
65
66       The XtAddRawEventHandler function is similar to XtAddEventHandler
67       except that it does not affect the widget's mask and never causes an
68       XSelectInput for its events.  Note that the widget might already have
69       those mask bits set because of other nonraw event handlers registered
70       on it.
71
72       The XtRemoveRawEventHandler function stops the specified procedure from
73       receiving the specified events.  Because the procedure is a raw event
74       handler, this does not affect the widget's mask and never causes a call
75       on XSelectInput.
76
77       XtInsertEventHandler is identical to XtAddEventHandler with the addi‐
78       tional position argument. if position is XtListHead, the event handler
79       is registered to that it will be called before any event handlers that
80       were previously registered for the same widget.  If position is XtList‐
81       Tail, the event handler is registered to be called after any previously
82       registered event handlers. If the procedure is already registered with
83       the same client_data value, the specified mask augments the existing
84       mask and the procedure is repositioned in the list.
85
86       XtInsertRawEventHandler is similar to XtInsertEventHandler except that
87       it does not modify the widget's event mask and never causes an XSelect‐
88       Input for the specified events. If the procedure is already registered
89       with the same client_data value, the specified mask augments the exist‐
90       ing mask and the procedure is repositioned in the list.
91

SEE ALSO

93       XtAppNextEvent(3), XtBuildEventMask(3)
94       X Toolkit Intrinsics - C Language Interface
95       Xlib - C Language X Interface
96
97
98
99X Version 11                     libXt 1.1.5.1            XtAddEventHandler(3)
Impressum