14.1.12 Setting and Reading the WM_ICON_SIZE Property

Xlib provides functions that you can use to set and read the WM_ICON_SIZE property for a given window. These functions use the XIconSize structure, which is defined in the X11/Xutil.h header file.

To allocate an XIconSize structure, use XAllocIconSize().

The XIconSize structure contains:


typedef struct {
	int min_width, min_height;
	int max_width, max_height;
	int width_inc, height_inc;
} XIconSize;

The width_inc and height_inc members define an arithmetic progression of sizes (minimum to maximum) that represent the supported icon sizes.

To set a window's WM_ICON_SIZE property, use XSetIconSizes().

To read a window's WM_ICON_SIZE property, use XGetIconSizes().

Next: Using Window Manager Convenience Functions

Christophe Tronche, ch.tronche@computer.org