Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ XtAppNextEv(3x) — HP-UX 9.10

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

XtAppAddInput(1)

XtAppAddTimeOut(1)

XtAppAddWorkProc(1)

XtAppMainLoop(1)

XtAppPeekEvent(1)

XtAppPending(1)

XtAppProcessEvent(1)

XtDispatchEvent(1)

 

NAME

XtAppNextEvent − dispatch timer and alternate input event and return the next X event. 

Synopsis

void XtAppNextEvent(app_context, event_return)

    XtAppContext app_context;
    XEvent *event_return;

Inputs

app_contextSpecifies the application context. 

Outputs

event_return
Returns the dequeued event structure.

Description

If there is an X event pending on any of the Displays in app_context, XtAppNextEvent() returns that event in event_return.  Otherwise, it flushes the X output buffer of each Display, and if there is a background work procedure registered (see XtAppAddWorkProc()), XtAppNextEvent() calls it and starts over by checking for pending events.  If there are no pending events and no work procedures, XtAppNextEvent() blocks while waiting for input on any of the Display connections, activity on any of the alternate input sources registered with XtAppAddInput(), or the expiration of any timers registered with XtAppAddTimeOut().  If there is activity on an alternate input source or if a timeout interval elapses, XtAppNextEvent() calls the callback that was registered with the input source or with the timer.  If an X event occurs, XtAppNextEvent() removes that event from the queue and returns it in event_return. 

Usage

Programs rarely need this much control over the event dispatching mechanism.  Most programs use XtAppMainLoop().  If you want to process a single X, input, or timer event, consider XtAppProcessEvent(). 

See Also

XtAppAddInput(1), XtAppAddTimeOut(1), XtAppAddWorkProc(1), XtAppMainLoop(1), XtAppPeekEvent(1), XtAppPending(1), XtAppProcessEvent(1), XtDispatchEvent(1). 

Copyright O’Reilly & Assoc.  —  X Toolkit Intrinsics Reference Manual © O’Reilly & Associates

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026