summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2022-07-10 11:55:11 -0700
committerAlan Coopersmith <alan.coopersmith@oracle.com>2022-07-15 22:35:49 +0000
commit9a90b3a63d02da92dc8692ed3f6269d3e0c7c8cc (patch)
treeeadb9f661e7ac5a637c2be5ee8a42d0e5002479c
parent0beb0cf46ae48b0d4322ff8a0221f47bdb7d2296 (diff)
downloadxorg-lib-libX11-9a90b3a63d02da92dc8692ed3f6269d3e0c7c8cc.tar.gz
doc: Document possible return values for XkbGetKeyboard()
Fixes: #160 Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-rw-r--r--man/xkb/XkbGetKeyboard.man23
1 files changed, 19 insertions, 4 deletions
diff --git a/man/xkb/XkbGetKeyboard.man b/man/xkb/XkbGetKeyboard.man
index ef44afb7..8bfd2563 100644
--- a/man/xkb/XkbGetKeyboard.man
+++ b/man/xkb/XkbGetKeyboard.man
@@ -47,7 +47,7 @@ determines events to be selected / deselected
1=>select, 0->deselect; for events in bits_to_change
.SH DESCRIPTION
.LP
-.I XkbGetKeyboard
+.B XkbGetKeyboard
allocates and returns a pointer to a keyboard description. It queries the server for those
components specified in the
.I which
@@ -76,17 +76,32 @@ XkbGeometryMask geom (1L<<6)
XkbAllComponentsMask All Fields (1L<<7)
.TE
-.I XkbGetKeyboard
+.B XkbGetKeyboard
is used to read the current description for one or more components of a keyboard device. It calls
-.I XkbGetKeyboardByName
+.BR XkbGetKeyboardByName (__libmansuffix__)
as follows:
.I XkbGetKeyboardByName(dpy, device_spec,
NULL,
.I which, which,
False).
+.LP
+If successful,
+.B XkbGetKeyboard
+returns a pointer to a newly allocated
+.B XkbDescRec
+structure,
+which is described in
+.BR XkbGetKeyboardByName (__libmansuffix__),
+and which should be freed with
+.BR XkbFreeKeyboard (__libmansuffix__).
+If
+.B XkbGetKeyboard
+does not succeed, it returns
+.BR NULL .
.SH DIAGNOSTICS
.TP 15
.SM BadAlloc
Unable to allocate storage
-
+.SH "SEE ALSO"
+.BR XkbGetKeyboardByName (__libmansuffix__)