GSP
Quick Navigator

Search Site

Unix VPS
A - Starter
B - Basic
C - Preferred
D - Commercial
MPS - Dedicated
Previous VPSs
* Sign Up! *

Support
Contact Us
Online Help
Handbooks
Domain Status
Man Pages

FAQ
Virtual Servers
Pricing
Billing
Technical

Network
Facilities
Connectivity
Topology Map

Miscellaneous
Server Agreement
Year 2038
Credits
 

USA Flag

 

 

Man Pages


Manual Reference Pages  -  XMTBLOCK (3)

NAME

XmtBlock() - process events in a recursive event loop.

CONTENTS

SYNOPSIS

   #include <Xmt/Xmt.h>

   void XmtBlock(Widget w, Boolean *block)

ARGUMENTS

INPUTS
w Any widget in the application context for which events are to be processed.
block A pointer to a flag that indicates when this function should return.

DESCRIPTION

XmtBlock() processes events in the application context of w by repeatedly calling XtAppProcessEvent() until the Boolean value pointed to by block becomes False. Then it performs an XSync() for the display of w and calls XmUpdateDisplay() to dispatch any pending expose events.

XmtBlock() is a recursive event loop, and processes events in the same way that XtAppMainLoop() does.

USAGE

XmtBlock() is intended for use when you want to write a function that appears to the caller to block and synchronously return a value. The Xmt simple dialog input routines, such as XmtAskForBoolean() are functions of this sort. True blocking is not possible in X applications because of the asynchronous, event-driven nature of the X programming model.

XmtBlock() should generally only be called when a modal dialog is active, or when the user is in some other way prevented from repeating whatever action caused XmtBlock() to be called. Otherwise it is possible for the application to enter event loops within recursive event loops.

When you use XmtBlock() you should be very sure that you know what will cause the flag block to be set to False and the loop to exit. This is usually done in a callback or action procedure triggered by some user action. It is equally important that you indicate to the user what action they must take to end the modal, synchronous input.

SEE ALSO

Chapter 8, Utility Functions,
XtAppMainLoop(), XtAppProcessEvent().
Search for    or go to Top of page |  Section 3 |  Main Index


Xmt XMTBLOCK (3) Motif Tools

Powered by GSP Visit the GSP FreeBSD Man Page Interface.
Output converted with manServer 1.07.