PDA

View Full Version : list for XEvent structure's type component?



sandbucket
09-19-2013, 08:02 AM
sorry about posting a similar question a while ago but i was silly and gave the name of my XEvent structure. so anybody know where i can find a list of possible values the XEvent's type variable? even a book would be fine.
thanks much

GClements
09-20-2013, 04:03 AM
anybody know where i can find a list of possible values the XEvent's type variable?
Theyr'e listed in the /usr/include/X11/X.h header file:


#define KeyPress 2
#define KeyRelease 3
#define ButtonPress 4
#define ButtonRelease 5
#define MotionNotify 6
#define EnterNotify 7
#define LeaveNotify 8
#define FocusIn 9
#define FocusOut 10
#define KeymapNotify 11
#define Expose 12
#define GraphicsExpose 13
#define NoExpose 14
#define VisibilityNotify 15
#define CreateNotify 16
#define DestroyNotify 17
#define UnmapNotify 18
#define MapNotify 19
#define MapRequest 20
#define ReparentNotify 21
#define ConfigureNotify 22
#define ConfigureRequest 23
#define GravityNotify 24
#define ResizeRequest 25
#define CirculateNotify 26
#define CirculateRequest 27
#define PropertyNotify 28
#define SelectionClear 29
#define SelectionRequest 30
#define SelectionNotify 31
#define ColormapNotify 32
#define ClientMessage 33
#define MappingNotify 34
#define GenericEvent 35


Also, the manual pages for specific event types list the possible type values which will occur in an event of that type (e.g. for XKeyEvent, type will be KeyPress or KeyRelease).