|
NAMEwaybar - battery moduleDESCRIPTIONThe battery module displays the current capacity and state (eg. charging) of your battery.CONFIGURATIONbat:typeof: string The battery to monitor, as in /sys/class/power_supply/ instead of auto detect. adapter:
full-at:
design-capacity: typeof: bool default: false Option to use the battery design capacity instead of it's current maximal capacity. interval:
states:
format:
format-time:
format-icons:
max-length:
min-length: typeof: integer The minimum length in characters the module should take up. align: typeof: float The alignment of the text, where 0 is left-aligned and 1 is right-aligned. If the module is rotated, it will follow the flow of the text. rotate:
on-click:
on-click-middle:
on-click-right:
on-update:
on-scroll-up:
on-scroll-down:
smooth-scrolling-threshold:
tooltip:
FORMAT REPLACEMENTS{capacity}: Capacity in percentage{power}: Power in watts {icon}: Icon, as defined in format-icons. {time}: Estimate of time until full or empty. Note that this is based on the power draw at the last refresh time, not an average. TIME FORMATThe battery module allows you to define how time should be formatted via format-time.The two arguments are: {H}: Hours {M}: Minutes CUSTOM FORMATSThe battery module allows one to define custom formats based on up to two factors. The best fitting format will be selected.format-<state>: With states, a custom format can be set depending on the capacity of your battery. format-<status>: With the status, a custom format can be set depending on the status in /sys/class/power_supply/<bat>/status (in lowercase). format-<status>-<state>: You can also set a custom format depending on both values. STATES•Every entry (state) consists of a
<name> (typeof: string) and a <value>
(typeof: integer).
•The state can be addressed as a CSS class in the
style.css. The name of the CSS class is the <name> of the
state. Each class gets activated when the current capacity is equal or below
the configured <value>.
•Also each state can have its own format.
Those con be configured via format-<name>. Or if you want to
differentiate a bit more even as format-<status>-<state>.
For more information see custom-formats.
EXAMPLES"battery": { "bat": "BAT2", "interval": 60, "states": { "warning": 30, "critical": 15 }, "format": "{capacity}% {icon}", "format-icons": ["", "", "", "", ""], "max-length": 25 } STYLE•#battery
•#battery.<status>
•<status> is the value of
/sys/class/power_supply/<bat>/status in lowercase.
•#battery.<state>
•<state> can be defined in the
config. For more information see states.
•#battery.<status>.<state>
•Combination of both <status> and
<state>.
Visit the GSP FreeBSD Man Page Interface. |