14.1.8 Setting and Reading the WM_CLASS Property

Xlib provides functions that you can use to set and get the XAllocClassHint().

The XClassHint contains:


typedef struct {
	char *res_name;
	char *res_class;
} XClassHint;

The res_name member contains the application name, and the res_class member contains the application class. Note that the name set in this property may differ from the name set as WM_NAME specifies what should be displayed in the title bar and, therefore, can contain temporal information (for example, the name of a file currently in an editor's buffer). On the other hand, the name specified as part of WM_CLASS property, use XSetClassHint().

To read a window's XGetClassHint().

Next: Setting and Reading the WM_TRANSIENT_FOR Property

Christophe Tronche, ch.tronche@computer.org