XmuAddCloseDisplayHook(Xmu) 6 January 1993 XmuAddCloseDisplayHook(Xmu)
X Version 11 (Release 5)
Name
XmuAddCloseDisplayHook - add a callback to display
Syntax
cc . . . -lXmu
#include <X11/Xmu/CloseHook.h>
CloseHook XmuAddCloseDisplayHook(dpy, func, arg)
Display *dpy;
int (*func)();
caddr_t arg;
Arguments
dpy Specifies the connection to the X server.
func Specifies the function to call at display close.
arg Specifies arbitrary data to pass to func.
Description
The XmuAddCloseDisplayHook function adds a callback for the given dis-
play. When the display is closed, the given function will be called with
the given display and argument as:
(*func)(dpy, arg)
The function is declared to return an int even though the value is
ignored, because some compilers have problems with functions returning
void.
This routine returns NULL if it was unable to add the callback, otherwise
it returns an opaque handle that can be used to remove or lookup the
callback.
See also
XmuRemoveCloseDisplayHook(Xmu)
Xlib - C Language X Interface