XRMESSAGEBOX(3X)

NAME
XrMessageBox - the Xrlib Message Box Manager.

SYNOPSIS
#include <X/Xlib.h>
#include <Xr/Xrlib.h>

XrMessageBox (msgInfo, message, data)
xrMsgBoxInfo msgInfo;
INT32 message;
INT8 * data;

DESCRIPTION
XrMessageBox is the Xrlib Message Box manager. Many times an applications programmer needs to warn a user or ask a simple multiple choice question. Message boxes provide this capability, and are easy to program.

A message box is made up of an icon, some descriptive text, and buttons. Icon placement, text formatting, and button placement is handled by the message box manager automatically.

STRUCTURES
The message box manager acquires all the information it needs about a message box in a message box information structure. This structure is shown below:
typedef struct
{
   POINT              messageOrigin;
   Window             relativeTo;
   xrPanelContext   * messageContext;
   INT32              rasterHeight;
   INT32              rasterWidth;
   Pixmap             rasterId;
   INT8             * messageText;
   INT8            ** messageButtons;
   INT32              numButtons;
} xrMsgBoxInfo;

MESSAGES
XrMessageBox currently has only two messages: MSG_EDIT, and MSG_SIZE. MSG_SIZE returns the size a message box would be if it were created with the given parameters. MSG_EDIT display a message box window and makes it active.

RETURN VALUE
XrMessage returns TRUE if successful, and NULL if on failure.

ERROR CONDITIONS
Messages to the message box manager will fail, set the xrErrno global and return a NULL value, under the following conditions:

MSG_EDIT

    data is set to NULL [XrINVALIDPTR].

    A call to 'X' failed [XrXCALLFAILED].

    Memory cannot be allocated[XrOUTOFMEM].

    Unknown message [XrINVALIDMSG].