Git init
[framework/uifw/xorg/lib/libx11.git] / man / xkb / XkbAddGeomOverlay.man
1 .\" Copyright 1999 Oracle and/or its affiliates. All rights reserved.
2 .\"
3 .\" Permission is hereby granted, free of charge, to any person obtaining a
4 .\" copy of this software and associated documentation files (the "Software"),
5 .\" to deal in the Software without restriction, including without limitation
6 .\" the rights to use, copy, modify, merge, publish, distribute, sublicense,
7 .\" and/or sell copies of the Software, and to permit persons to whom the
8 .\" Software is furnished to do so, subject to the following conditions:
9 .\"
10 .\" The above copyright notice and this permission notice (including the next
11 .\" paragraph) shall be included in all copies or substantial portions of the
12 .\" Software.
13 .\"
14 .\" THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15 .\" IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16 .\" FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
17 .\" THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18 .\" LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
19 .\" FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
20 .\" DEALINGS IN THE SOFTWARE.
21 .\"
22 .TH XkbAddGeomOverlay __libmansuffix__ __xorgversion__ "XKB FUNCTIONS"
23 .SH NAME
24 XkbAddGeomOverlay \- Add one overlay to a section
25 .SH SYNOPSIS
26 .HP
27 .B XkbOverlayPtr XkbAddGeomOverlay
28 .BI "(\^XkbSectionPtr " "section" "\^,"
29 .BI "Atom " "name" "\^,"
30 .BI "int " "sz_rows" "\^);"
31 .if n .ti +5n
32 .if t .ti +.5i
33 .SH ARGUMENTS
34 .TP
35 .I \- section
36 section to which an overlay will be added
37 .TP
38 .I \- name
39 name of the overlay
40 .TP
41 .I \- sz_rows
42 number of rows to reserve in the overlay
43 .SH DESCRIPTION
44 .LP
45 Xkb provides functions to add a single new element to the top-level keyboard 
46 geometry. In each case the 
47 .I num_ * 
48 fields of the corresponding structure is incremented by 1. These functions do 
49 not change 
50 .I sz_* 
51 unless there is no more room in the array. Some of these functions fill in the 
52 values of the element's structure from the arguments. For other functions, you 
53 must explicitly write code to fill the structure's elements.
54
55 The top-level geometry description includes a list of 
56 .I geometry properties. 
57 A geometry property associates an arbitrary string with an equally arbitrary 
58 name. Programs that display images of keyboards can use geometry properties as 
59 hints, but they are not interpreted by Xkb. No other geometry structures refer 
60 to geometry properties.
61
62 .I XkbAddGeomOverlay 
63 adds an overlay with the specified name to the specified 
64 .I section. 
65 The new overlay is created with space allocated for 
66 .I sz_rows 
67 rows. If an overlay with name 
68 .I name 
69 already exists in the section, a pointer to the existing overlay is returned.
70 .I XkbAddGeomOverlay 
71 returns NULL if any of the parameters is empty or if it was not able to allocate 
72 space for the overlay. To allocate space for an arbitrary number of overlays to 
73 a section, use the 
74 .I XkbAllocGeomOverlay 
75 function.
76 .SH STRUCTURES
77 .LP
78 .nf
79
80     typedef struct _XkbOverlayRec {
81         Atom                  name;            /\(** overlay name */
82         XkbSectionPtr         section_under;   /\(** the section under this overlay */
83         unsigned short        num_rows;        /\(** number of rows in the rows array */
84         unsigned short        sz_rows;         /\(** size of the rows array */
85         XkbOverlayRowPtr      rows;            /\(** array of rows in the overlay */
86         XkbBoundsPtr          bounds;          /\(** bounding box for the overlay */
87     } XkbOverlayRec,*XkbOverlayPtr;
88     
89 .fi
90 .SH "SEE ALSO"
91 .BR XkbAllocGeomOverlay (__libmansuffix__)