Commit graph

166 commits

Author SHA1 Message Date
Benno Schulenberg
a7968c47e3 docs: hard-wrap some items so that Table 2 fits within 80 characters
(Table 1 hard-wraps the first-column items in the same way.)

Also, correct the formatting of the subsequent paragraph.

Signed-off-by: Benno Schulenberg <bensberg@telfort.nl>
2022-06-23 16:11:23 +02:00
Alan Coopersmith
35d1513bc7 XkbOpenDisplay: Add _Xconst qualifier to display name argument
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2022-04-23 16:38:49 +00:00
Alan Coopersmith
c88ceaad4a XKBgeom.h: Add _Xconst qualifier to char * arguments in functions
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2022-04-23 16:38:49 +00:00
Benno Schulenberg
1adb531cd5 docs: unwrap the comments of structure elements in the man pages
It doesn't matter that these lines get wider than 80 columns, as it's
easy enough to make the pager scroll a bit to the right, or to have a
terminal that is a 100 or more columns wide.  It looks better to not
hard-wrap these comments.

Also, fix the layout of two table elements.

Signed-off-by: Benno Schulenberg <bensberg@telfort.nl>
2022-01-14 17:19:37 +00:00
Benno Schulenberg
da330a1644 docs: unwrap some mistakenly wrapped lines, and correct a comment
The wrapped lines messed up the table.  Also, add some blank lines
to make the table more readable.

Elsewhere, add spaces around an operator (for consistency),
and correct a copy-paste error.

Signed-off-by: Benno Schulenberg <bensberg@telfort.nl>
2022-01-14 17:19:37 +00:00
Hodong
150154c994 Fix a typo 2021-11-14 06:36:42 +00:00
Walter Harms
78027fdb7a fix same roff code
Signed-off-by: Walter Harms <wharms@bfs.de>
2020-11-28 21:05:33 +01:00
Walter Harms
4f15cfc645 Fix some roff code add see also
Signed-off-by: Walter Harms <wharms@bfs.de>
2020-11-28 20:56:35 +01:00
Walter Harms
daa106927f fix broken nroff coding for code comments
the comments /* */ are code as /\(**  */ that does not work.
the coding in other X11 man pages is /\&* */ so we do the same here.
2020-11-28 17:49:25 +01:00
Walter Harms
7bdeae239b FIX: warning: macro `hN' not defined
Signed-off-by: Walter Harms <wharms@bfs.de>
2020-11-27 22:43:21 +01:00
Walter Harms
b7ec67d3ea FIX: warning: macro `IN' not defined
just remove an other dead macro use.
2020-11-27 22:26:15 +01:00
Walter Harms
7ca3ceb917 fix warning: macro `s' not defined
this is caused by bad nroff coding, fix some more issues on the fly
2020-11-27 21:58:04 +01:00
Walter Harms
14fb4e5356 FIX: warning: macro `hN' not defined
this was found by checking man pages with
 groff -t -mandoc -Z  -wmac -Tutf8 $FILE >/dev/null

In most cases .hN could be replaced with .BR

Signed-off-by: Walter Harms <wharms@bfs.de>
2020-11-27 20:04:22 +01:00
Walter Harms
cb03da4447 FIX: warning: macro `Pn' not defined
The missing macro is found via:
roff -t -mandoc -Z  -wmac -Tutf8 XAnyEvent.man >/dev/null

To fix the problem the macro is replaced with .RB.

Signed-off-by: Walter Harms <wharms@bfs.de>
2020-11-27 19:00:00 +01:00
Carlos Garnacho
9f9c536581 Add XSetIOErrorExitHandler() function
This function complements XSetIOErrorHandler(), allowing to override
the default behavior that trusts on I/O errors never coming back
(i.e. exit()ing the process).

This is meant as a mechanism for Wayland compositors (that are too
a X11 client + compositing manager) to unfasten seatbelts and jump
through the car window. It might get lucky and land on a stack of
pillows.

In consequence, some functions labeled as _X_NORETURN can as a
matter of fact return. So those hints were removed.

Signed-off-by: Carlos Garnacho <carlosg@gnome.org>
Reviewed-by: Michel Dänzer <mdaenzer@redhat.com>
2020-10-15 11:14:53 +02:00
Christopher Chavez
780d222343 Fix typo GCCLipYOrigin -> GCClipYOrigin in XCreateGC() manpage 2020-08-10 17:08:39 +00:00
Alan Coopersmith
2b7598221d Fix spelling/wording issues
Found by using:
    codespell --builtin clear,rare,usage,informal,code,names

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2020-07-22 15:19:58 -07:00
Thomas E. Dickey
3ec9264d01
document an ancient performance problem (see Debian #954845).
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2020-04-25 14:44:06 -04:00
Thomas E. Dickey
791c93816c
update/correct function prototypes in manpages to match headers
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2020-04-25 14:44:00 -04:00
Thomas E. Dickey
f111bf3ac0
improve some formatting
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2019-07-30 16:53:27 -04:00
Thomas E. Dickey
1d0a6fe912
fix a substitution error from recent commit, e.g, "s/^\.EE/XDe/"
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2019-07-30 15:49:09 -04:00
Thomas E. Dickey
8fe8aafe7e
split lines at sentence endings
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2019-07-30 05:07:40 -04:00
Thomas E. Dickey
6f2cbcea5d
trim trailing whitespace from manpages
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2019-07-30 04:52:25 -04:00
Thomas E. Dickey
4abf482d8e
another fake-quote fix
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2019-07-30 04:36:24 -04:00
Thomas E. Dickey
c0f0651f2b
the last commit overlooked some fake-quote pairs
Signed-off-by: Thomas E. Dickey <dickey@invisible-island.net>
2019-07-30 04:34:54 -04:00
Walter Harms
ef31143c9d fix ``fake quotes'' in text
to remove the fake quotes replace them with propper
predefined macros \*(lq and \*(rq. this will allow
nroff to choose the propper characters when using ps etc.

Signed-off-by: Walter Harms <wharms@bfs.de>
2019-07-29 18:50:19 +02:00
Walter Harms
705027ea9b get rid of ``fake quotes''
these fake quotes are inside a comment and can be replaced with
some double quotes

Signed-off-by: Walter Harms <wharms@bfs.de>
2019-07-29 18:27:12 +02:00
Walter Harms
fe46eb2871 remove all private macro defines
after converting everything to st. man page macros there is
no need to maintain X11 private nroff macros, so remove them.

Signed-off-by: Walter Harms <wharms@bfs.de>
2019-07-29 17:57:02 +02:00
Walter Harms
b7f09ae19c Replace home-grown .Ds .De macro with man page .EX/.EE macro
Same pages use the man page .EX/.EE macro. Replace all occurences
of .De/.Ds with the std. macros to make the code better to maintain.

Signed-off-by: Walter Harms <wharms@bfs.de>
2019-07-29 17:47:35 +02:00
Walter Harms
951e772bc8 fix TBL format
Signed-off-by: Walter Harms <wharms@bfs.de>
2019-07-03 18:23:51 +02:00
Walter Harms
4eb167f5ac replace home grown .ZN with std, .B and .BR
Replace the home grown macro .ZN with std. macros
from man macro paket. So we can get rid of the
definition an get a clean header.

Signed-off-by: Walter Harms <wharms@bfs.de>
2019-07-03 18:18:09 +02:00
Walter Harms
08e6b36292 remove in-text macros
remove in-text macros an fix a few typos on the way.
hopefuly that will make maintenance more easy.

Signed-off-by: Walter Harms <wharms@bfs.de>
2019-06-22 18:33:48 +02:00
Walter Harms
cb0e894fe9 note that we can handle kbd==NULL
Signed-off-by: Walter Harms <wharms@bfs.de>
2019-06-21 18:01:16 +02:00
Ran Benita
33b9148a83 Compose.man: fix escaped hexadecimal char description
The man page says:
    Strings may be direct text encoded in the locale for which the
    compose file is to be used, or an escaped octal or hexadecimal
    character code.   Octal codes are specified as "\123" and
    hexadecimal codes as "\0x123a".

But the grammar in the parser and the implementation say:
    ESCAPED_CHAR  ::= ('\\' | '\"' | OCTAL | HEX )
    HEX           ::= '\' (x|X) HEX_CHAR [HEX_CHAR]]
    HEX_CHAR      ::= (0|1|2|3|4|5|6|7|8|9|A|B|C|D|E|F|a|b|c|d|e|f)

So "\0x123a" -> "\x3a".

Signed-off-by: Ran Benita <ran234@gmail.com>
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2019-06-09 10:42:07 -07:00
Alan Coopersmith
603c3ab25a Add missing close paren to XrmGetStringDatabase synopsis in man page
Fixes: commit 0642e99ac0

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2019-03-09 21:05:13 -08:00
Alan Coopersmith
c72d17ada9 XkbAllocGeomOverlayKey man page should be named XkbAllocGeomOverlayKeys
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2019-02-23 11:43:35 -08:00
Alan Coopersmith
05002b8aef Fix man page typo: XkbAllBellNotifyMask -> XkbAllBellEventsMask
Reported-by: Daniel Hahler <git@thequod.de>
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2019-02-17 15:14:14 -08:00
Samuel Thibault
b676e62377 XkbOpenDisplay.3: fix typo
XkbOpenDisplay returns a pointer to Display, not a Display.

Signed-off-by: Samuel Thibault <samuel.thibault@ens-lyon.org>
2018-06-13 15:46:58 +02:00
Alan Coopersmith
7d2010fec2 Improve table formatting in XkbChangeControls & XkbKeyNumGroups man pages
Includes fix for Solaris Bug 24564279: "XkbKeyNumGroups.3x11 man page
contains some malformed text" caused by extra whitespace after .TE macros

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2017-04-07 00:13:03 -07:00
Alan Coopersmith
b856d5d929 Clarify state parameter to XkbSetNamedDeviceIndicator
Checking a Bool to see if it's NULL does not work well in C.
Also reported in https://bugs.freedesktop.org/show_bug.cgi?id=251

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Adam Jackson <ajax@redhat.com>
2017-03-24 15:19:27 -07:00
Alan Coopersmith
c6dadd4ceb Make Xkb{Get,Set}NamedIndicator spec & manpages match code
The XKB Library spec and the man pages for XkbGetNamedIndicator &
XkbSetNamedIndicator included a device_spec argument neither function
takes, and do not include the XkbGetNamedDeviceIndicator &
XkbSetNamedDeviceIndicator variants that do take it (along with two
other arguments).

This updates them to match the interfaces the code has provided for
decades.

This has been reported multiple times, so this fixes:
https://bugs.freedesktop.org/show_bug.cgi?id=251
https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=729812
Sun Bug 4528016 XkbSetNamedIndicator & XkbGetNamedIndicator man pages are wrong
  (filed: alan.coopersmith@sun.com 2001-11-15 - now aka Oracle bug 15087506)
X.Org Group Defect Id #9418

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
Reviewed-by: Adam Jackson <ajax@redhat.com>
2017-03-24 15:19:18 -07:00
walter harms
78851f6a03 XFree will accept NULL as argument
since Xfree is a define for free():
  Xlibint.h:#define Xfree(ptr) free((ptr))

Xfree will accept NULL and do nothing.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
2016-08-26 11:04:10 +02:00
Joonas Javanainen
c8e19b393d Fix XErrorEvent struct field order in man page
In the man page the field "resourceid" was in a different place than
in the actual struct layout in Xlib.h

Signed-off-by: Joonas Javanainen <joonas.javanainen@gmail.com>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2015-02-06 12:58:38 +10:00
Ran Benita
ddf3b09bb2 compose: fix the description of modifiers in compose sequences
The Compose format has a feature which allows specifying certain
modifiers must (or must not) be present with a given keysym in the
sequence.

The grammar in imLcPrs.c and the Compose man page both do not match what
the code actually does (see the handling of the variables
`modifier_mask` and `modifier` in parseline() in imLcPrs.c, which are
eventually matched as `ev->state & modifier_mask == modifier`).

Also explicitly list the accepted modifier names, since they are
not standard (e.g. "Ctrl" instead of "Control").

Signed-off-by: Ran Benita <ran234@gmail.com>
Signed-off-by: James Cloos <cloos@jhcloos.com>
2015-02-05 17:36:01 -05:00
Ran Benita
129f13f385 xkb: fix misleading comment about consumed modifiers
In the spec and the man page the `mods_rtrn` argument is described as
"backfilled with unconsumed modifiers" but actually it is backfilled
with the *consumed* modifiers. This is also mentioned a few lines below
in each case.

Signed-off-by: Ran Benita <ran234@gmail.com>
Signed-off-by: James Cloos <cloos@jhcloos.com>
2015-02-05 17:35:57 -05:00
Ingo Schwarze
446f5f7f41 Fix pasto in XkbGetKeyBehaviors(3) manual
Reviewed-by: Thomas Klausner <wiz@NetBSD.org>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2014-12-10 10:01:42 +10:00
Alan Coopersmith
0f9e734ea9 Add missing .TE tags to end tables in Xkb man pages
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-05-20 21:30:57 -07:00
Alan Coopersmith
280274e529 XCreateGC.man: simplify table to work with Solaris tbl
Having every table cell be a text diversion (T{...T}) was too much for
Solaris tbl to handle, and thus "man XCreateGC" would print the error
/usr/man/man3x11/XCreateGC.3x11: line 402: Too many text block diversions
tbl quits
and not display the table of mask bits or any text in the man page after
that table.   Since the #define column doesn't need special handling,
making it not use text diversions brings the table under the tbl limit.

Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
2014-05-20 21:30:57 -07:00
Peter Hutterer
d6bd988bc0 man: fix man page for XkbGetMap
Returned structure must be freed with XkbFreeKeyboard().

Reported-by: Morten Bøgeskov <mb@dbc.dk>
Signed-off-by: Peter Hutterer <peter.hutterer@who-t.net>
2014-03-03 12:41:08 +10:00
Eric S. Raymond
0a48235d63 Remove call to undefined macro. 2013-06-06 16:43:56 -04:00