upload tizen2.0 source
[framework/uifw/xorg/lib/libx11.git] / man / xkb / XkbResizeDeviceButtonActions.man
1 '\" t
2 .\" Copyright 1999 Oracle and/or its affiliates. All rights reserved.
3 .\"
4 .\" Permission is hereby granted, free of charge, to any person obtaining a
5 .\" copy of this software and associated documentation files (the "Software"),
6 .\" to deal in the Software without restriction, including without limitation
7 .\" the rights to use, copy, modify, merge, publish, distribute, sublicense,
8 .\" and/or sell copies of the Software, and to permit persons to whom the
9 .\" Software is furnished to do so, subject to the following conditions:
10 .\"
11 .\" The above copyright notice and this permission notice (including the next
12 .\" paragraph) shall be included in all copies or substantial portions of the
13 .\" Software.
14 .\"
15 .\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 .\" IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 .\" FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
18 .\" THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 .\" LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
20 .\" FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
21 .\" DEALINGS IN THE SOFTWARE.
22 .\"
23 .TH XkbResizeDeviceButtonActions __libmansuffix__ __xorgversion__ "XKB FUNCTIONS"
24 .SH NAME
25 XkbResizeDeviceButtonActions \- Allocate additional space for button actions in an XkbDeviceInfoRec structure
26 .SH SYNOPSIS
27 .HP
28 .B Status XkbResizeDeviceButtonActions
29 .BI "(\^XkbDeviceInfoPtr " "device_info" "\^,"
30 .BI "unsigned int " "new_total" "\^);"
31 .if n .ti +5n
32 .if t .ti +.5i
33 .SH ARGUMENTS
34 .TP
35 .I \- device_info
36 structure in which to allocate button actions
37 .TP
38 .I \- new_total
39 new total number of button actions needed
40 .SH DESCRIPTION
41 .LP
42 .I XkbResizeDeviceButtonActions 
43 reallocates space, if necessary, to make sure there is room for a total of
44 .I new_total 
45 button actions in the 
46 .I device_info 
47 structure. Any new entries allocated are zeroed. If successful,
48 .I XkbResizeDeviceButtonActions 
49 returns Success. If 
50 .I new_total 
51 is zero, all button actions are deleted, 
52 .I device_info->num_btns 
53 is set to zero, and 
54 .I device_info->btn_acts 
55 is set to NULL. If 
56 .I device_info 
57 is invalid or 
58 .I new_total 
59 is greater than 255, BadValue is returned. If a memory allocation failure occurs, a BadAlloc is returned. 
60
61 To free an XkbDeviceInfoRec structure, use 
62 .I XkbFreeDeviceInfo.
63 .SH STRUCTURES
64 .LP
65 Information about X Input Extension devices is transferred between a client program and the Xkb 
66 extension in an XkbDeviceInfoRec structure:
67 .nf
68
69     typedef struct {
70         char *               name;          /\(** name for device */
71         Atom                 type;          /\(** name for class of devices */
72         unsigned short       device_spec;   /\(** device of interest */
73         Bool                 has_own_state; /\(** True=>this device has its own state */
74         unsigned short       supported;     /\(** bits indicating supported capabilities */
75         unsigned short       unsupported;   /\(** bits indicating unsupported capabilities */
76         unsigned short       num_btns;      /\(** number of entries in btn_acts */
77         XkbAction *          btn_acts;      /\(** button actions */
78         unsigned short       sz_leds;       /\(** total number of entries in LEDs vector */
79         unsigned short       num_leds;      /\(** number of valid entries in LEDs vector */
80         unsigned short       dflt_kbd_fb;   /\(** input extension ID of default (core kbd) indicator */
81         unsigned short       dflt_led_fb;   /\(** input extension ID of default indicator feedback */
82         XkbDeviceLedInfoPtr  leds;          /\(** LED descriptions */
83     } XkbDeviceInfoRec, *XkbDeviceInfoPtr;
84 .fi
85 .SH DIAGNOSTICS
86 .TP 15
87 .B BadAlloc
88 Unable to allocate storage
89 .TP 15
90 .B BadValue
91 An argument is out of range
92 .SH "SEE ALSO"
93 .BR XkbFreeDeviceInfo (__libmansuffix__)