You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: doc/xob.md
+24-22Lines changed: 24 additions & 22 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -31,6 +31,30 @@ xob - A lightweight overlay volume/backlight/progress/anything bar for the X Win
31
31
**-q**
32
32
: Specifies whether to suppress all normal output. By default: not suppressed
33
33
34
+
# USAGE
35
+
36
+
## GENERAL CASE
37
+
38
+
Use a program that listens to events (such as a change in audio volume levels) and issues new values on the standard output automatically. Launch `the_listener_program | xob`. Ready to use input programs for audio volume and screen backlight are available on the xob project homepage: https://github.com/florentc/xob
39
+
40
+
## FALLBACK METHOD
41
+
42
+
In case no input program fits your needs, you may trigger changes manually. Append new values in a named pipe (a pipe that persists as a special file on the filesystem) and have xob consume them as they arrive.
43
+
44
+
Create a named pipe, e.g. */tmp/xobpipe*, on your filesystem.
45
+
46
+
mkfifo /tmp/xobpipe
47
+
48
+
Have xob consume new values as they arrive on the pipe.
49
+
50
+
tail -f /tmp/xobpipe | xob
51
+
52
+
Write values to the pipe when you deem it relevant. In the classic audio volume bar example, that would be after the user has pressed a button and you changed the volume (usually set up as a keybinding in your window manager or desktop environment).
53
+
54
+
command_that_outputs_a_value >> /tmp/xobpipe
55
+
56
+
To try it manually, issue a test value such as `echo 43 >> /tmp/xobpipe`.
57
+
34
58
# CONFIGURATION FILE
35
59
36
60
The configuration file only specifies styles (appearances) for the bar. The maximum value and timeout are set by **-m** and **-t**. When starting, xob looks for the configuration file in the following order:
@@ -205,28 +229,6 @@ This example configuration file provides two styles "volume" and "backlight". In
205
229
};
206
230
};
207
231
208
-
# GENERAL USE CASE
209
-
210
-
Use a program that listens to events (such as a change in audio volume levels) and issues new values on the standard output automatically. Launch `the_listener_program | xob`. Ready to use input programs for audio volume and screen backlight are available on the xob project homepage: https://github.com/florentc/xob
211
-
212
-
## FALLBACK METHOD
213
-
214
-
In case no input program fits your needs, you may trigger changes manually. Append new values in a named pipe (a pipe that persists as a special file on the filesystem) and have xob consume them as they arrive.
215
-
216
-
Create a named pipe, e.g. */tmp/xobpipe*, on your filesystem.
217
-
218
-
mkfifo /tmp/xobpipe
219
-
220
-
Have xob consume new values as they arrive on the pipe.
221
-
222
-
tail -f /tmp/xobpipe | xob
223
-
224
-
Write values to the pipe when you deem it relevant. In the classic audio volume bar example, that would be after the user has pressed a button and you changed the volume (usually set up as a keybinding in your window manager or desktop environment).
225
-
226
-
command_that_outputs_a_value >> /tmp/xobpipe
227
-
228
-
To try it manually, issue a test value such as `echo 43 >> /tmp/xobpipe`.
229
-
230
232
# FAQ
231
233
232
234
> "How should I display different sources of information (e.g. volume and brightness)?"
0 commit comments