modules/power-profiles-daemon: add man page

There was no way to display the default value of format-icons without
breaking the table :(
This commit is contained in:
Félix Baylac Jacqué 2024-03-01 15:07:58 +01:00 committed by Félix Baylac Jacqué
parent 09bb6a055d
commit bddc870340
2 changed files with 73 additions and 1 deletions

View File

@ -0,0 +1,72 @@
waybar-power-profiles-daemon(5)
# NAME
waybar - power-profiles-daemon module
# DESCRIPTION
The *power-profiles-daemon* module displays the active power-profiles-daemon profile and cycle through the available profiles on click.
# FILES
$XDG_CONFIG_HOME/waybar/config
# CONFIGURATION
[- *Option*
:- *Typeof*
:- *Default*
:= *Description*
|[ *format*
:[ string
:[ "{icon}"
:[ Message displayed on the bar. {icon} and {profile} are respectively substituted with the icon representing the active profile and its full name.
|[ *tooltip-format*
:[ string
:[ "Power profile: {profile}\\nDriver: {driver}"
:[ Messaged displayed in the module tooltip. {icon} and {profile} are respectively substituted with the icon representing the active profile and its full name.
|[ *tooltip*
:[ bool
:[ true
:[ Display the tooltip.
|[ *format-icons*
:[ object
:[ See default value in the example below.
:[ Icons used to represent the various power-profile. *Note*: the default configuration uses the font-awesome icons. You may want to override it if you don't have this font installed on your system.
# CONFIGURATION EXAMPLES
Compact display (default config):
```
"power_profiles_daemon": {
"format": "{icon}",
"tooltip-format": "Power profile: {profile}\nDriver: {driver}",
"tooltip": true,
"format-icons": {
"default": "",
"performance": "",
"balanced": "",
"power-saver": ""
}
}
```
Display the full profile name:
```
"power_profiles_daemon": {
"format": "{icon} {profile}",
"tooltip-format": "Power profile: {profile}\nDriver: {driver}",
"tooltip": true,
"format-icons": {
"default": "",
"performance": "",
"balanced": "",
"power-saver": ""
}
}
```

View File

@ -222,6 +222,7 @@ if is_linux
'man/waybar-cpu.5.scd',
'man/waybar-memory.5.scd',
'man/waybar-systemd-failed-units.5.scd',
'man/waybar-power-profiles-daemon.5.scd',
)
elif is_dragonfly or is_freebsd or is_netbsd or is_openbsd
add_project_arguments('-DHAVE_CPU_BSD', language: 'cpp')
@ -578,4 +579,3 @@ if clangtidy.found()
'-p', meson.project_build_root()
] + src_files)
endif