XLIB FUNCTIONS XSetTextProperty(3x11)
NAME
XSetTextProperty, XGetTextProperty - set and read text pro-
perties SYNTAXcc [ flag... ] file... -lX11 [ library... ]
void XSetTextProperty(Display *display, Window w, XTextPro-
perty *text_prop, Atom property);
Status XGetTextProperty(Display *display, Window w,XTextProperty *text_prop_return, Atom property);
ARGUMENTS display Specifies the connection to the X server. property Specifies the property name.text_prop Specifies the XTextProperty structure to be used.
text_prop_return
Returns the XTextProperty structure.DESCRIPTION
The XSetTextProperty function replaces the existing speci-
fied property for the named window with the data, type, for-
mat, and number of items determined by the value field, the encoding field, the format field, and the nitems field, respectively, of the specified XTextProperty structure. Ifthe property does not already exist, XSetTextProperty sets
it for the specified window.XSetTextProperty can generate BadAlloc, BadAtom, BadValue,
and BadWindow errors. The XGetTextProperty function reads the specified property from the window and stores the data in the returned XTextProperty structure. It stores the data in the valuefield, the type of the data in the encoding field, the for-
mat of the data in the format field, and the number of items of data in the nitems field. An extra byte containing null (which is not included in the nitems member) is stored atthe end of the value field of text_prop_return. The partic-
ular interpretation of the property's encoding and data as text is left to the calling application. If the specified property does not exist on the window, XGetTextProperty sets the value field to NULL, the encoding field to None, the format field to zero, and the nitems field to zero.If it was able to read and store the data in the XTextPro-
perty structure, XGetTextProperty returns a nonzero status; otherwise, it returns a zero status. X Version 11 Last change: libX11 1.3.5 1XLIB FUNCTIONS XSetTextProperty(3x11)
XGetTextProperty can generate BadAtom and BadWindow errors. PROPERTIESWM_CLIENT_MACHINE
The string name of the machine on which the client application is running.WM_COMMAND
The command and arguments, null-separated, used to
invoke the application.WM_ICON_NAME
The name to be used in an icon.WM_NAME The name of the application.
DIAGNOSTICS BadAlloc The server failed to allocate the requested resource or server memory. BadAtom A value for an Atom argument does not name a defined Atom. BadValue Some numeric value falls outside the range of values accepted by the request. Unless a specific range is specified for an argument, the full range defined by the argument's type is accepted. Anyargument defined as a set of alternatives can gen-
erate this error. BadWindow A value for a Window argument does not name a defined Window.SEE ALSO
XAllocClassHint(3x11), XAllocIconSize(3x11), XAllocSizeHints(3x11), XAllocWMHints(3x11), XSetCommand(3x11), XSetTransientForHint(3x11), XSetWMClientMachine(3x11), XSetWMColormapWindows(3x11), XSetWMIconName(3x11), XSetWMName(3x11), XSetWMProperties(3x11), XSetWMProtocols(3x11), XStringListToTextProperty(3x11)Xlib - C Language X Interface
ATTRIBUTES
See attributes(5) for descriptions of the following attri-
butes: X Version 11 Last change: libX11 1.3.5 2XLIB FUNCTIONS XSetTextProperty(3x11)
____________________________________________________________
| ATTRIBUTE TYPE | ATTRIBUTE VALUE |
|_____________________________|_____________________________|
| Availability | x11/library/libx11 ||_____________________________|_____________________________|
| Interface Stability | Committed ||_____________________________|_____________________________|
| MT-Level | See XInitThreads(3X11) |
|_____________________________|_____________________________|
X Version 11 Last change: libX11 1.3.5 3