1XkbAddGeomColor(3) XKB FUNCTIONS XkbAddGeomColor(3)
2
3
4
6 XkbAddGeomColor - Add one color name to an existing keyboard geometry
7 description
8
10 XkbColorPtr XkbAddGeomColor (XkbGeometryPtr geom, _Xconst char *spec,
11 unsigned int pixel);
12
14 geom geometry to be updated
15
16 spec color to be added
17
18 pixel color to be added
19
21 Xkb provides functions to add a single new element to the top-level
22 keyboard geometry. In each case the num_ * fields of the corresponding
23 structure is incremented by 1. These functions do not change sz_* un‐
24 less there is no more room in the array. Some of these functions fill
25 in the values of the element's structure from the arguments. For other
26 functions, you must explicitly write code to fill the structure's ele‐
27 ments.
28
29 The top-level geometry description includes a list of geometry proper‐
30 ties. A geometry property associates an arbitrary string with an
31 equally arbitrary name. Programs that display images of keyboards can
32 use geometry properties as hints, but they are not interpreted by Xkb.
33 No other geometry structures refer to geometry properties.
34
35 XkbAddGeomColor adds the specified color name and pixel to the speci‐
36 fied geometry geom. The top-level geometry description includes a list
37 of up to MaxColors (32) color names. A color name is a string whose
38 interpretation is not specified by Xkb and neither is the pixel value's
39 interpretation. All other geometry data structures refer to colors us‐
40 ing their indices in this global list or pointers to colors in this
41 list. XkbAddGeomColor returns NULL if any of the parameters is empty
42 or if it was not able to allocate space for the color. To allocate
43 space for an arbitrary number of colors to a geometry, use the XkbAl‐
44 locGeomColors function.
45
47 typedef struct _XkbColor {
48 unsigned int pixel; /* color */
49 char * spec; /* color name */
50 } XkbColorRec,*XkbColorPtr;
51
52
54 XkbAllocGeomColors(3)
55
56
57
58
59X Version 11 libX11 1.8.7 XkbAddGeomColor(3)