documentation: updated man page

Using scdoc to make editing a bit more comfortable.
This commit is contained in:
Maarten van Gompel 2024-11-25 12:57:09 +01:00
parent 97efb1de74
commit c742b58f51
4 changed files with 117 additions and 77 deletions

View File

@ -21,9 +21,12 @@ HDRS = $(WAYLAND_HEADERS:.xml=-client-protocol.h)
WAYLAND_SRC = $(HDRS:.h=.c)
SOURCES = $(WVKBD_SOURCES) $(WAYLAND_SRC)
SCDOC=scdoc
DOCS = wvkbd.1
OBJECTS = $(SOURCES:.c=.o)
all: ${BIN}
all: ${BIN} ${DOCS}
config.h:
cp config.def.h config.h
@ -45,6 +48,9 @@ clean:
format:
clang-format -i $(WVKBD_SOURCES) $(WVKBD_HEADERS)
%: %.scd
$(SCDOC) < $< > $@
install: all
mkdir -p ${DESTDIR}${PREFIX}/bin
cp -f ${NAME}-${LAYOUT} ${DESTDIR}${PREFIX}/bin

View File

@ -42,6 +42,8 @@ You'll need the following developer packages
- wayland-client
- xkbcommon
You also need [scdoc](https://git.sr.ht/~sircmpwn/scdoc/) to generate the documentation.
Make any customizations you would like in `config.def.h` and run `make`
The default set of layouts is called `mobintl` *(mobile international)*, which groups various layouts aimed at mobile devices

76
wvkbd.1
View File

@ -1,76 +0,0 @@
.TH "wvkbd" "1" "2022-03-12"
.P
.SH NAME
.P
wvkbd - on-screen keyboard for wlroots
.P
.SH SYNOPSIS
.P
wvkbd-mobintl [OPTION]...
.P
.SH DESCRIPTION
.P
wvkbd is an on-screen keyboard for wlroots that sucks less.
.P
.SH OPTIONS
.P
\fB-D\fR
.RS 4
enable debug
.P
.RE
\fB-o\fR
.RS 4
print pressed keys to standard output
.P
.RE
\fB-O\fR
.RS 4
print intersected keys to standard output
.P
.RE
\fB-l\fR
.RS 4
comma separated list of layers
.P
.RE
\fB--landscape-layers\fR
.RS 4
comma separated list of layers used in landscape mode
.P
.RE
\fB-H\fR \fIPX\fR
.RS 4
height in pixels
.P
.RE
\fB-L\fR \fIPX\fR
.RS 4
landscape height in pixels
.P
.RE
\fB--fn\fR \fIFONT\fR
.RS 4
set font (e.g: DejaVu Sans 20)
.P
.RE
\fB--hidden\fR
.RS 4
start hidden (send SIGUSR2 to show, SIGUSR1 to hide, SIGRTMIN to toggle)
.P
.RE
\fB-v\fR, \fB--version\fR
.RS 4
print version
.P
.RE
\fB-h\fR, \fB--help\fR
.RS 4
show help
.P
.RE
.SH AUTHORS
.P
Created by John Sullivan <jsullivan@csumb.edu>, maintained by the Sxmo project in
collaboration with other open source contributors. For more information about wvkbd development, see
<https://git.sr.ht/~proycon/wvkbd> or <https://github.com/jjsullivan5196/wvkbd>.

108
wvkbd.1.scd Normal file
View File

@ -0,0 +1,108 @@
wvkbd(1)
# NAME
wvkbd - on-screen virtual keyboard for wayland compositors using wlroots
# SYNOPSIS
wvkbd-mobintl [OPTIONS]...
*NOTE*: Your binary may have a different suffix depending on which layout you compiled.
# DESCRIPTION
This project aims to deliver a minimal but practically usable implementation of
a wlroots on-screen keyboard in legible C. This will _only_ be a keyboard, not
a feedback buzzer, led blinker, or anything that requires more than what's
needed to input text quickly. The end product should be a static codebase that
can be patched to add new features.
## OPTIONS
*-D*
enable debug mode.
*-o*
print pressed keys to standard output.
*-O*
print intersected keys to standard output.
*-l* _layers_
comma separated list of layers in vertical/portrait mode.
*--landscape-layers* _layers_
comma separated list of layers used in horizontal/landscape mode.
*--list-layers*
prints a list of all available layers.
*-H* _pixels_
Height of the keyboard in pixels, for vertical/portrait mode.
*-L* _pixels_
Height of the keyboard in pixels, for horizontal/landscape mode
*--fn* _font_
set font and size (e.g. DejaVu Sans 20)
*--hidden*
Start hidden (send SIGUSR2 to show).
*--alpha* _int_
Set alpha value (i.e. transparency) for all colors [0-255]
*--bg* _rrggbb|aa_
Set color of background
*--fg* _rrggbb|aa_
Set color of keys
*--fg-sp* _rrggbb|aa_
Set color of special keys
*--press* _rrggbb|aa_
Set color of pressed keys
*--press-sp* _rrggbb|aa_
Set color of pressed special keys
*--swipe* _rrggbb|aa_
Set color of swiped keys
*--swipe-sp* _rrggbb|aa_
Set color of swiped special keys
*--text* _rrggbb|aa_
Set color text on keys
*--text-sp* _rrggbb|aa_
Set color text on special keys
*--version*
Print version information
*-h*, *--help*
Print usage help
# SIGNALS
You can send signals to wvkbd to hide/show it (e.g. using _kill_(1) with _-s_):
*SIGUSR1*
Hide the keyboard.
*SIGUSR2*
Show the keyboard
*SIGRTMIN*
Toggle visibility
# AUTHORS
Created by John Sullivan <jsullivan@csumb.edu>, maintained by the Sxmo project
<https://sxmo.org> in collaboration with other open source contributors. For
more information about wvkbd development, see <https://git.sr.ht/~proycon/wvkbd>
or <https://github.com/jjsullivan5196/wvkbd>.