The following paragraphs describe CLX functions and macros used to:
queue-event | display event-key &rest event-slots &key :append-p & allow-other-keys | Function |
Places an event of the type given by event-key into the event queue. When :append-p is true, the event is placed at the tail of the queue; otherwise, the event is placed at the head of the queue. The actual event-slots passed depend on the event type. The keyword symbols used for each event type are event slot names defined by the declare-event macro and are described in paragraph 12.12.8, Declaring Event Types. |
discard-current-event | display | Function |
Discards the current event for the display. Returns nil when the event queue is empty; otherwise, returns t . This function provides extra flexibility for discarding events, but it should be used carefully; use event-cond instead, if possible. Typically, discard-current-event is called inside a handler function or a clause of an event-case form and is followed by another call to process-event, event-case , or event-cond.
|
event-listen | display & optional (timeout 0) | Function |
Returns the number of events queued locally. If the event queue is empty, event-listen waits for an event to arrive. If timeout is non-nil and no event arrives within the specified timeout interval (given in seconds), event-listen returns nil; if timeout is nil , event-listen will not return until an event arrives.
|
with-event-queue | display &body body | Macro |
Executes the body in a critical region in which the executing client process has exclusive access to the event queue. |