unsigned long length;
int private_id;
int *data_id;
XmClipboardCopy() copies the data in buffer to the clipboard. The format of the data is described by the
format_name parameter. This value is not a type, but a string -describing the type. For example, "STRING"
indicates that the data is a text string. The length parameter is the size of the data. Text strings, can use strlen
(data).
The item_id parameter is the ID returned by XmClipboardStartCopy(). The data_id parameter returns the
format ID. You may pass NULL for this parameter if you are not interested in the value, however you may need it for
other functions. For example, you will need it if you wish to withdraw an item from the clipboard. We will discuss
this issue later when we talk about registration by name. The private_id parameter is an arbitrary number that is
application−defined. The value is passed back to various functions, including those that handle calling by name, so we
will address it further in Section #sclipbyname.
When copying is done, XmClipboardEndCopy() is called to free the internal data structures associated with the
clipboard item. The routine takes the following form:
int
XmClipboardEndCopy(display, window, item_id)
Display *display;
Window window;
long item_id;
The item_id parameter is the ID returned by the call to XmClipboardStartCopy().
The clipboard copy functions return one of three status values: ClipboardSuccess, ClipboardLocked, or
ClipboardFail. If the client is successful in gaining access to the ...