1XkbAddDeviceLedInfo(3)           XKB FUNCTIONS          XkbAddDeviceLedInfo(3)
2
3
4

NAME

6       XkbAddDeviceLedInfo - Initialize an XkbDeviceLedInfoRec structure
7

SYNOPSIS

9       XkbDeviceLedInfoPtr  XkbAddDeviceLedInfo (XkbDeviceInfoPtr device_info,
10              unsigned int led_class, unsigned int led_id);
11

ARGUMENTS

13       device_info
14              structure in which to add LED info
15
16       led_class
17              input extension class for LED device of interest
18
19       led_id input extension ID for LED device of interest
20

DESCRIPTION

22       XkbAddDeviceLedInfo first checks  to  see  whether  an  entry  matching
23       led_class  and led_id already exists in the device_info->leds array. If
24       it finds a matching entry, it returns a pointer to that  entry.  Other‐
25       wise,  it  checks  to  be sure there is at least one empty entry in de‐
26       vice_info->leds and extends it if there is not enough room. It then in‐
27       crements device_info->num_leds and fills in the next available entry in
28       device_info->leds with led_class and led_id.
29
30       If successful, XkbAddDeviceLedInfo returns  a  pointer  to  the  XkbDe‐
31       viceLedInfoRec  structure  that  was initialized. If unable to allocate
32       sufficient storage, or if device_info points to an invalid XkbDeviceIn‐
33       foRec structure, or if led_class or led_id are inappropriate, XkbAddDe‐
34       viceLedInfo returns NULL.
35
36       To allocate additional space for button actions in an  XkbDeviceInfoRec
37       structure, use XkbResizeDeviceButtonActions.
38
39

STRUCTURES

41       Information  about  X  Input Extension devices is transferred between a
42       client program and the Xkb extension in an XkbDeviceInfoRec structure:
43
44           typedef struct {
45               char *               name;          /* name for device */
46               Atom                 type;          /* name for class of devices */
47               unsigned short       device_spec;   /* device of interest */
48               Bool                 has_own_state; /* True=>this device has its own state */
49               unsigned short       supported;     /* bits indicating supported capabilities */
50               unsigned short       unsupported;   /* bits indicating unsupported capabilities */
51               unsigned short       num_btns;      /* number of entries in btn_acts */
52               XkbAction *          btn_acts;      /* button actions */
53               unsigned short       sz_leds;       /* total number of entries in LEDs vector */
54               unsigned short       num_leds;      /* number of valid entries in LEDs vector */
55               unsigned short       dflt_kbd_fb;   /* input extension ID of default (core kbd) indicator */
56               unsigned short       dflt_led_fb;   /* input extension ID of default indicator feedback */
57               XkbDeviceLedInfoPtr  leds;          /* LED descriptions */
58           } XkbDeviceInfoRec, *XkbDeviceInfoPtr;
59
60
61           typedef struct {
62               unsigned short      led_class;        /* class for this LED device*/
63               unsigned short      led_id;           /* ID for this LED device */
64               unsigned int        phys_indicators;  /* bits for which LEDs physically present */
65               unsigned int        maps_present;     /* bits for which LEDs have maps in maps */
66               unsigned int        names_present;    /* bits for which LEDs are in names */
67               unsigned int        state;            /* 1 bit => corresponding LED is on */
68               Atom                names[XkbNumIndicators];   /* names for LEDs */
69               XkbIndicatorMapRec  maps;             /* indicator maps for each LED */
70           } XkbDeviceLedInfoRec, *XkbDeviceLedInfoPtr;
71
72

SEE ALSO

74       XkbResizeDeviceButtonActions(3)
75
76
77
78X Version 11                     libX11 1.8.7           XkbAddDeviceLedInfo(3)
Impressum