aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Ankarstr\xf6m <john@ankarstrom.se>2021-06-06 15:02:06 +0200
committerJohn Ankarstr\xf6m <john@ankarstrom.se>2021-06-06 15:05:29 +0200
commit05cc184d7f0abea3a99e387791306854387f90ab (patch)
treee22e2fc6eaf6f59a9700a6c996f26b2d266f39aa
parent36071b3edae34e3448b62a4991be0f11b4764426 (diff)
downloadxbattext-05cc184d7f0abea3a99e387791306854387f90ab.tar.gz
Add manual
-rw-r--r--Makefile1
-rw-r--r--xbattext.155
2 files changed, 56 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 6d4e965..2ae839e 100644
--- a/Makefile
+++ b/Makefile
@@ -6,6 +6,7 @@ xbattext: xbattext.c
install: xbattext
install xbattext /usr/local/bin
+ install -m 644 xbattext.1 /usr/local/man/man1
upload: xbattext.c
scp xbattext.c root@ankarstrom.se:/var/www/img/htdocs/xbattext.c
diff --git a/xbattext.1 b/xbattext.1
new file mode 100644
index 0000000..7460053
--- /dev/null
+++ b/xbattext.1
@@ -0,0 +1,55 @@
+.Dd $Mdocdate$
+.Dt xbattext 1
+.Os
+.Sh NAME
+.Nm xbattext
+.Nd display battery percentage
+.Sh SYNOPSIS
+.Nm
+.Op Ar ...
+.Sh DESCRIPTION
+.Pp
+.Nm
+is a simple X11 program that displays the current battery level on NetBSD.
+It can be configured on the command line
+with the regular X options, such as
+.Fl title
+and
+.Fl bg .
+The foreground color and font are configured by the resources
+described in
+.Sx CONFIGURATION .
+.Sh CONFIGURATION
+.Pp
+The font and color of the battery display is controlled
+by the following resources,
+defined in
+.Pa ~/.Xdefaults
+or
+.Pa ~/.Xresources :
+.Bl -tag -offset indent
+.It xbattext*fontList
+normal font
+.It xbattext*foreground
+normal text color
+.It xbattext*alertFontList
+font when battery is low
+.It xbattext*alertForeground
+text color when battery is low
+.It xbattext*chargeFontList
+font when charging
+.It xbattext*chargeForeground
+text color when charging
+.El
+.Pp
+The battery is considered to be low
+when it is below 25 percent.
+.Sh AUTHORS
+.Pp
+.An John Ankarström Aq Mt "john (at) ankarstrom.se"
+.Sh BUGS
+.Pp
+.Nm
+cannot distinguish between a missing foreground color resource
+and one defined as the color
+.Li black .