home *** CD-ROM | disk | FTP | other *** search
/ Geek Gadgets 1 / ADE-1.bin / ade-bin / x11r6.1 / man / cat3 / xevent.0 < prev    next >
Encoding:
Text File  |  1996-10-17  |  4.5 KB  |  133 lines

  1.  
  2.  
  3.  
  4. XAnyEvent(3X11)          XLIB FUNCTIONS      XAnyEvent(3X11)
  5.  
  6.  
  7. NNAAMMEE
  8.        XAnyEvent, XEvent - generic X event structures
  9.  
  10. SSTTRRUUCCTTUURREESS
  11.        All the event structures declared in <_X_1_1_/_X_l_i_b_._h> have the
  12.        following common members:
  13.        typedef struct {
  14.         int type;
  15.         unsigned long serial;    /* # of last request processed by server */
  16.         Bool send_event;         /* true if this came from a SendEvent request */
  17.         Display *display;         /* Display the event was read from */
  18.         Window window;
  19.        } XAnyEvent;
  20.  
  21.        The type member is set to the event type constant name
  22.        that uniquely identifies it.  For example, when the X
  23.        server reports a _G_r_a_p_h_i_c_s_E_x_p_o_s_e event to a client applica-
  24.        tion, it sends an _X_G_r_a_p_h_i_c_s_E_x_p_o_s_e_E_v_e_n_t structure with the
  25.        type member set to _G_r_a_p_h_i_c_s_E_x_p_o_s_e.  The display member is
  26.        set to a pointer to the display the event was read on.
  27.        The send_event member is set to _T_r_u_e if the event came
  28.        from a _S_e_n_d_E_v_e_n_t protocol request.  The serial member is
  29.        set from the serial number reported in the protocol but
  30.        expanded from the 16-bit least-significant bits to a full
  31.        32-bit value.  The window member is set to the window that
  32.        is most useful to toolkit dispatchers.
  33.  
  34.        The _X_E_v_e_n_t structure is a union of the individual struc-
  35.        tures declared for each event type:
  36.        typedef union _XEvent {
  37.         int type;             /* must not be changed */
  38.         XAnyEvent xany;
  39.         XKeyEvent xkey;
  40.         XButtonEvent xbutton;
  41.         XMotionEvent xmotion;
  42.         XCrossingEvent xcrossing;
  43.         XFocusChangeEvent xfocus;
  44.         XExposeEvent xexpose;
  45.         XGraphicsExposeEvent xgraphicsexpose;
  46.         XNoExposeEvent xnoexpose;
  47.         XVisibilityEvent xvisibility;
  48.         XCreateWindowEvent xcreatewindow;
  49.         XDestroyWindowEvent xdestroywindow;
  50.         XUnmapEvent xunmap;
  51.         XMapEvent xmap;
  52.         XMapRequestEvent xmaprequest;
  53.         XReparentEvent xreparent;
  54.         XConfigureEvent xconfigure;
  55.         XGravityEvent xgravity;
  56.         XResizeRequestEvent xresizerequest;
  57.         XConfigureRequestEvent xconfigurerequest;
  58.         XCirculateEvent xcirculate;
  59.         XCirculateRequestEvent xcirculaterequest;
  60.         XPropertyEvent xproperty;
  61.  
  62.  
  63.  
  64. X Version 11           Release 6.1                1
  65.  
  66.  
  67.  
  68.  
  69.  
  70. XAnyEvent(3X11)          XLIB FUNCTIONS      XAnyEvent(3X11)
  71.  
  72.  
  73.         XSelectionClearEvent xselectionclear;
  74.         XSelectionRequestEvent xselectionrequest;
  75.         XSelectionEvent xselection;
  76.         XColormapEvent xcolormap;
  77.         XClientMessageEvent xclient;
  78.         XMappingEvent xmapping;
  79.         XErrorEvent xerror;
  80.         XKeymapEvent xkeymap;
  81.         long pad[24];
  82.        } XEvent;
  83.  
  84.        An _X_E_v_e_n_t structure's first entry always is the type mem-
  85.        ber, which is set to the event type.  The second member
  86.        always is the serial number of the protocol request that
  87.        generated the event.  The third member always is
  88.        send_event, which is a _B_o_o_l that indicates if the event
  89.        was sent by a different client.    The fourth member always
  90.        is a display, which is the display that the event was read
  91.        from.  Except for keymap events, the fifth member always
  92.        is a window, which has been carefully selected to be use-
  93.        ful to toolkit dispatchers.  To avoid breaking toolkits,
  94.        the order of these first five entries is not to change.
  95.        Most events also contain a time member, which is the time
  96.        at which an event occurred.  In addition, a pointer to the
  97.        generic event must be cast before it is used to access any
  98.        other information in the structure.
  99.  
  100. SSEEEE AALLSSOO
  101.        XButtonEvent(3X11), XCreateWindowEvent(3X11), XCircula-
  102.        teEvent(3X11), XCirculateRequestEvent(3X11), XCol-
  103.        ormapEvent(3X11), XConfigureEvent(3X11), XConfigur-
  104.        eRequestEvent(3X11), XCrossingEvent(3X11), XDestroyWindow-
  105.        Event(3X11), XErrorEvent(3X11), XExposeEvent(3X11), XFo-
  106.        cusChangeEvent(3X11), XGraphicsExposeEvent(3X11), XGravi-
  107.        tyEvent(3X11), XKeymapEvent(3X11), XMapEvent(3X11),
  108.        XMapRequestEvent(3X11), XPropertyEvent(3X11), XRepar-
  109.        entEvent(3X11), XResizeRequestEvent(3X11), XSelection-
  110.        ClearEvent(3X11), XSelectionEvent(3X11), XSelectionRe-
  111.        questEvent(3X11), XUnmapEvent(3X11), XVisibili-
  112.        tyEvent(3X11)
  113.        _X_l_i_b _- _C _L_a_n_g_u_a_g_e _X _I_n_t_e_r_f_a_c_e
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.  
  130. X Version 11           Release 6.1                2
  131.  
  132.  
  133.