Commit Graph

341 Commits

Author SHA1 Message Date
Aleksei Bavshin 93e340a081
feat(clock): support chrono Time Zone extensions.
Use chrono Calendars and Time Zones (P0355R7, P1466R3) when available
instead of the `date` library.
Verified with a patched build of a recent GCC 13 snapshot.
2023-01-21 02:18:44 -08:00
Aleksei Bavshin 43d52c59d9
test: fix build with Catch2 v2.x
Use smaller includes for Catch2 v3.
2023-01-20 22:49:59 -08:00
Alex f0bead34d4 chore: 0.9.17 2023-01-11 11:39:30 +01:00
Alex 86850f5c7a
Merge pull request #1520 from robertgzr/mpris-module 2023-01-06 22:35:24 +01:00
Robert Günzler 0bc5314e08
Add mpris module
Uses libplayerctl to use the MPRIS dbus protocol to query, listen and
control media players.

Signed-off-by: Robert Günzler <r@gnzler.io>
2023-01-06 20:55:31 +01:00
Enes Hecan 4d59de42af Implement hyprland submap module 2022-12-21 01:45:57 +01:00
Alex 80b2b29a77
Merge pull request #1397 from JakeStanger/feat/image-module
Resolves https://github.com/Alexays/Waybar/issues/1191
2022-11-24 20:40:56 +01:00
Alex 9eb6c4e296 chore: v0.9.16 2022-11-24 20:34:12 +01:00
Simon Plakolb 235861fd3d button: Remove AButton class 2022-11-24 13:08:16 +01:00
Sasha Moak c2f98d07ef feat: wireplumber support
Adds basic support for showing volume via wireplumber. Allows specifying
the node-id or falling back to the default Audio/Sink node id if node-id
is not set. If tooltip on hover is enabled, will show `{node_name}` by
default otherwise `tooltip-format`.

Format replacements:

`{volume}` - Volume in percentage
`{node_name}` - The node's nickname (`node.nick` property)
2022-11-16 23:23:07 -08:00
Alex eb705533b5 feat: jsoncpp wrap 2022-11-03 14:08:22 +01:00
Jan Palus 73495df377
build: require jsoncpp >= 1.9.2
with #1719 Waybar started using Json::Value.as() available since jsoncpp
1.9.2.
2022-11-03 10:59:03 +01:00
Alex fd417c0805 chore: 0.9.15 2022-11-03 09:43:05 +01:00
Alex f330e51472 fix: typo 2022-10-20 10:57:27 +02:00
Alex 411c6f4b4b chore: update catch 2022-10-20 10:56:47 +02:00
Alex e8e8ccb6cf
Merge pull request #1661 from asas1asas200/zeng-feat-improve_keyboard 2022-10-20 10:50:35 +02:00
herlev 54e04b5a30 Refactor rewriteTitle 2022-10-19 13:25:08 +02:00
Loïc Bartoletti 830c5cd5d0 FreeBSD: Add support to battery
This commit aims to propose a FreeBSD to gain battery support using sysctl on hw.acpi.battery.*
2022-10-18 19:30:04 +02:00
Alex 209225e381
Merge pull request #1701 from Dordovel/master 2022-10-18 09:01:00 +02:00
Alex 7746328daa
Merge pull request #1667 from asas1asas200/zeng-feat-sway_scratchpad 2022-10-18 09:00:31 +02:00
Dordovel 4ed13df092
Merge branch 'Alexays:master' into master 2022-10-17 19:00:21 +03:00
Alex bfa3adcfd6
Merge pull request #1120 from pinselimo/use_gtk_button_v2 2022-10-17 09:09:12 +02:00
Mika Braunschweig f86dff60e6
utils: add sanitize_str to encode '&' etc.
gtk requires some chars (<>&"') to be encoded for them to render
properly. `sanitize_str` sanitizes raw strings that have such chars and
returns a properly encoded string
2022-10-17 00:31:19 +02:00
Simon Plakolb b8322c4b4b button: Add AButton class
The AButton class is designed as full a substitute to ALabel. The
GtkButton attribute 'button_' is initialized with a label. This
label can the be referenced by the subsequent inheritors of AButton
instead of the GtkLabel attribute 'label_' of ALabel.
For convenience a GtkLabel* 'label_' attribute is added to AButton.

If the button cannot be clicked it is disabled, effectively acting
like its label predecessor.

GtkButton seems to catch one-click mouse events regardless of the
flags set on it. Therefore, 'signal_pressed' is connected to a
function creating a fake GdkEventButton* and calling 'handleToggle'
(for details on this possible bug in GTK see:
https://stackoverflow.com/questions/45334911 )

In accordance with other GtkButtons (i.e. the sway/workspace ones)
set_relief(Gtk::RELIEF_NONE) is called on the 'button_' instance.
2022-10-12 10:25:29 +02:00
Dordovel 9758833027 added user module 2022-09-30 14:33:23 +03:00
Alex 29bdff5314
Merge pull request #1657 from vaxerski/hyprlandLanguage
Added a basic hyprland/language module
2022-09-05 09:12:17 +02:00
Alex 4deb6d812d
Merge pull request #1653 from kennypm/dsp
add JACK module
2022-09-02 08:12:57 +02:00
asas1asas200 bc201fd0eb doc(sway/scratchpad): add man page 2022-08-31 16:27:25 +08:00
asas1asas200 e3342467fc feat(sway/scratchpad): add basic counter 2022-08-31 16:27:25 +08:00
asas1asas200 58a399b9af chore(ci, meson): add inotify dependency for BSD 2022-08-24 02:22:40 +08:00
asas1asas200 061f4550f4 feat(keyboard): improve keyboard response time
Use libinput event for keyboard state updates.
The state will update when CAPS_LOCK, NUM_LOCK or SCROLL_LOCK has been
released,
`interval` will have no effect after this change.
2022-08-22 22:49:59 +08:00
vaxerski 16d5619f3b added a basic hyprland/language module 2022-08-18 18:00:27 +02:00
Vaxry 8dc78e4e40
Revert "init man documentation" 2022-08-18 14:54:20 +02:00
Vaxry e662b8c624
Merge pull request #2 from NotAShelf/master
init man documentation
2022-08-18 14:53:15 +02:00
vaxerski 123ed36739 remove workspaces module as its buggy and unnecessary 2022-08-17 21:58:33 +02:00
kennypm 8b5f42d934 remove unnecessary libprocps dependency 2022-07-19 19:27:39 -04:00
kennypm b65c976bc1 fix build type 2022-07-19 01:41:32 -04:00
kennypm 318a6e0969 fix segfault when stopping JACK2 server 2022-07-19 01:38:56 -04:00
Kenny Phelps-McKeown 8fc8bb40bf Initial commit for Waybar JACK monitoring module
-DSP load
  -xruns
  -connected/disconnected state
  -only tested with Pipewire so far but should work with JACK2 as well

 On branch dsp
 Changes to be committed:
	modified:   include/factory.hpp
	new file:   include/modules/jack.hpp
	modified:   meson.build
	modified:   meson_options.txt
	modified:   src/factory.cpp
	new file:   src/modules/jack.cpp
2022-07-19 01:38:35 -04:00
vaxerski c1f92d2a3c added workspaces 2022-07-01 15:16:54 +02:00
vaxerski 72f478c195 added backend and hyprland/window 2022-07-01 12:46:28 +02:00
Viktar Lukashonak 36aa22189b
Last weekday applies Unix fmt 2022-06-24 16:44:06 +03:00
tiosgz f3a049c6df river/mode: new module
This module shows river's current mapping mode (e.g. normal, locked).
2022-06-01 15:35:08 +00:00
Erik Reider 3c182c9ca9 Added gamemode man file to meson 2022-05-23 14:13:30 +02:00
Alex aa5f55bbe3 chore: v0.9.13 2022-05-23 13:54:24 +02:00
Alex a5299af3c2
Merge pull request #1562 from trevnels/river-window
River Window Module
2022-05-23 13:43:28 +02:00
trevnels 165c5a861d manpage fixes 2022-05-19 16:41:05 -04:00
trevnels d84c0f13e6 forgot to commit meson build 2022-05-19 16:33:50 -04:00
Erik Reider 3411236697 Initial implementation 2022-05-13 21:30:45 +02:00
Daan Goossens 638b4e6573 feat: extend bluetooth module 2022-05-02 18:11:21 +02:00
vaxerski e094480684 Very basic hypr window title module 2022-04-02 21:08:43 +02:00
Erik Reider 9dc09d2702 Added upower man page into man_files meson variable 2022-03-25 14:53:46 +01:00
Erik Reider 7fac2afb85 Added custom tooltip with device icon, device name and battery status 2022-03-19 17:09:55 +01:00
Erik Reider 14a2a7027f Moved upower into its own directory 2022-03-19 11:34:34 +01:00
Erik Reider 6eb187a23e Moved upower.*pp out of the upower directories 2022-03-15 23:00:09 +01:00
Erik Reider d47073ef13 Reload all devices after wake from suspend 2022-03-15 22:49:40 +01:00
Erik Reider 4ee81c8dea Added all callbacks 2022-03-15 17:54:06 +01:00
Alex 3c1ba0a240 chore: v0.9.12 2022-03-10 09:53:25 +01:00
Alex 115c6e36e6 chore: v0.9.11 2022-03-10 09:50:04 +01:00
Alex 383d999fec chore: v0.9.10 2022-03-06 14:54:48 +01:00
Felix Weilbach bcadf64031 Show application icon when using sway window module
Signed-off-by: Felix Weilbach <felix.weilbach@t-online.de>
2022-01-24 17:37:51 +01:00
Jake Stanger a650c7d90c feat: image module
Module which renders an image onto the bar.
2022-01-16 23:55:13 +00:00
Alex 1540797cd9 chore: v0.9.9 2022-01-10 09:58:29 +01:00
Aleksei Bavshin 1489a539f8
chore: bump supported fmt ver to 7.0.0
Certain features we use were added only in 7.0 and the code no longer
compiles with any earlier versions.
2022-01-07 22:33:52 -08:00
Yura Shatunov 5a4f7a70ef
fix indent 2022-01-04 14:53:59 +07:00
Alexis Cellier 795246263f man: Add waybar-inhibitor man page 2021-12-14 08:30:28 +01:00
Alexis Cellier eae65099d0 Add logind feature, with its 'inhibitor' module
The logind feature adds a new inhibitor module which allows to acquire
the inhibitor locks that logind presents.

Signed-off-by: Alexis Cellier <kernelserror@gmail.com>
2021-12-12 17:52:26 +01:00
Alex 05f7727dae
Merge branch 'master' into swaybar-ipc 2021-12-01 11:48:03 +01:00
Alex b6e24bd527
Merge pull request #1305 from njoyard/feat/groups
Add module group feature
2021-11-29 15:19:48 +01:00
dmitry 3c2fa1625d Finish 2021-11-28 01:12:35 +03:00
Nicolas Joyard 0c18e57937 add group feature 2021-11-25 12:01:17 +01:00
dmitry 15761ef802 Merge branch 'master' of https://github.com/Alexays/Waybar into workspace-manager-implementation 2021-11-16 21:44:50 +03:00
Aleksei Bavshin 6eba62f060
test: add build configs for catch2 2021-09-15 21:34:55 +07:00
Aleksei Bavshin b377520a38
refactor(client): extract config handling into a new class 2021-09-14 13:15:54 +07:00
Alex e5787a2617 chore: 0.9.8 2021-08-16 15:47:34 +02:00
Alex 445ad22580
Merge branch 'master' into keyboard_state 2021-07-23 15:59:08 +02:00
Grant Moyer 99138ffdcd Add man page for keyboard_state module 2021-07-20 21:09:00 -04:00
Grant Moyer 6dfa31fb17 Basic keyboard state module 2021-07-20 21:09:00 -04:00
dmitry 8310700bbb Improve sway/language 2021-07-13 04:33:12 +03:00
Alex cdce3e03ea
Update meson.build 2021-04-30 14:25:48 +02:00
Alex 5300461c79 chore: v0.9.7 2021-04-15 21:17:54 +02:00
Alex 729a4fe37e chore: v0.9.6 2021-04-15 16:09:45 +02:00
Artur Sinila f4ad5d36ec meson.build: add missing waybar-sway-language manpage 2021-03-23 16:51:08 +03:00
nullobsi d2a1f41750
Use g_unichar_iswide to properly align calendar on CJK locales 2021-01-31 11:53:53 -08:00
Alex ede1146ddc
Merge pull request #903 from spk/simpleclock
Add simpleclock as fallback when hhdate is not available
2021-01-18 12:00:48 +01:00
Alex 4b29aef048
chore: v0.9.5 2020-12-23 21:33:40 +01:00
Thomas Hebb ad40511358 Update spdlog subproject to 1.8.1
Among other changes, this adds spdlog::should_log(), which lets us
easily determine whether a log message will be printed so that we can
avoid extra computation when unnecessary.

New wrap file taken from https://wrapdb.mesonbuild.com/spdlog and
modified to download from GitHub as per commit 99dde1aff8 ("Download
patch files from Github instead of wrapdb").
2020-11-30 17:11:33 -08:00
Thomas Hebb e8dbdee238 Make spdlog use the same version of fmt we use
spdlog bundles a version of fmt. However, we also depend on and use fmt
directly. If we don't tell spdlog not to use its bundled version, we end
up with two versions of fmt in our include path, since both libraries
are header-only, meaning any slight API mismatches will cause build
failures and undesired behavior.

We seem to have gotten lucky so far, but I ran into all sorts of issues
when I tried to update to a newer version of spdlog. This change
prevents them.
2020-11-30 17:04:19 -08:00
Aleksei Bavshin 85e00b2aab
fix: build fails with meson < 0.53.0
meson.build:12:0: ERROR: Module "fs" does not exist

Fixes #909
2020-11-26 15:40:24 -08:00
Laurent Arnoud 96d965fe04
Add simpleclock as fallback when hhdate is not available
ref https://github.com/Alexays/Waybar/issues/668
2020-10-29 19:40:28 +01:00
nikto_b f13f49ccb5
Merge branch 'master' into sway-language-module 2020-10-20 12:22:22 +03:00
Aleksei Bavshin 23e5181cac
feat(swaybar-ipc): add swaybar IPC client 2020-10-19 19:34:48 -07:00
Joseph Benden 8f961ac397
mpd: revamped to event-driven, single-threaded
Fix MPD connection issues by converting/rewriting module into a
state-machine driven system. It is fully single-threaded and uses
events for transitioning between states. It supports all features
and functionality of the previous MPD module.

Signed-off-by: Joseph Benden <joe@benden.us>
2020-10-18 10:37:57 -07:00
Alex 54beabb9dc
Revert "mpd: revamped to event-driven, single-threaded" 2020-10-18 10:45:31 +02:00
nikto_b cc3acf8102
feature: created sway language submodule; added styles & config part for a sway language submodule 2020-10-10 19:09:18 +03:00
Joseph Benden 21fdcf41c3
mpd: revamped to event-driven, single-threaded
Fix MPD connection issues by converting/rewriting module into a
state-machine driven system. It is fully single-threaded and uses
events for transitioning between states. It supports all features
and functionality of the previous MPD module.

Signed-off-by: Joseph Benden <joe@benden.us>
2020-10-08 16:43:22 -07:00
Érico Rolim e4427cb017 sndio: Add module.
- can control sndio: change volume, toggle mute
- appearance is somewhat dynamic: takes muted status into account
- uses polling inside sleeper thread to update values
- uses sioctl_* functions, requires sndio>=1.7.0.
2020-10-04 02:54:57 -03:00
Minijackson 73681a30e5
man: add the prefixed path were config is loaded 2020-09-29 22:31:28 +02:00
Alex 6db795401a chore: v0.9.4 2020-09-21 12:18:42 +02:00
wjoe fdfb60c633 meson feature: make rfkill optional 2020-08-14 20:56:45 +02:00
dmitry 42b6c089f3 Add docs and adjust sorting 2020-08-08 00:09:35 +03:00
Alex 01c682c41e chore: v0.9.3 2020-08-05 23:27:06 +02:00
dmitry edd4d8ee11 Finish implement wlr 2020-08-05 23:10:08 +03:00
dmitry 2b11b7ef8c Base wlr impl (Manager, Group) 2020-08-05 02:17:38 +03:00
Jonas Toth 17967da676 Fix 'date' dependency in meson
The 'date' library dependency was incompletly imported with meson.
Only the target 'date::date' seemed to be caught by meson, but
'date::date-tz' not, which lead to build errors in gentoos sandbox
environment.

See this question, too:
https://stackoverflow.com/questions/62951569/meson-doesnt-link-library

Adding the modules in meson imports them all and the library builds
nice.
Note, that this did not happen with a standard checkout and local build
on my system, but only when creating an ebuild for the package.
2020-07-28 20:04:28 +02:00
Alex 8f684f703e
Merge pull request #753 from spk/reproductible-builds
Remove date macro on version for reproducible builds
2020-06-24 18:22:36 +02:00
Laurent Arnoud 5e044e5bba
Remove date macro on version for reproducible builds
cf https://reproducible-builds.org/
2020-06-24 15:09:11 +02:00
Laurent Arnoud 732ce7a27c
chore: always include sway module 2020-06-24 14:55:41 +02:00
Isaac Freund 343a8bef22
river/tags: add module 2020-06-12 15:19:46 +02:00
Till Smejkal adaf843048
foreign-toplevel-manager based taskbar module (#692)
Co-authored-by: Alex <alexisr245@gmail.com>
2020-05-30 12:07:38 +02:00
Alex 49ae944d65 fix: check git root 2020-05-24 19:14:46 +02:00
Jan Beich 1885ecc958 bluetooth: limit to Linux due to missing /dev/rfkill
../src/modules/bluetooth.cpp:3:10: fatal error: 'linux/rfkill.h' file not found
 #include <linux/rfkill.h>
          ^~~~~~~~~~~~~~~~
2020-05-19 10:44:31 +00:00
Jan Beich 4e567d0483 cpu: port parseCpuinfo to BSDs 2020-05-19 10:43:42 +00:00
Jan Beich c4f7cdeec4 memory: port parseMeminfo to BSDs 2020-05-19 10:42:21 +00:00
Jan Beich 496e782544 battery: limit to Linux due to /sys/class/power_supply
../include/modules/battery.hpp:9:10: fatal error: 'sys/inotify.h' file not found
 #include <sys/inotify.h>
          ^~~~~~~~~~~~~~~
2020-05-19 10:37:27 +00:00
Jan Beich cfd7577e1b backlight: require libepoll on non-Linux
../src/modules/backlight.cpp:9:10: fatal error: 'sys/epoll.h' file not found
 #include <sys/epoll.h>
          ^~~~~~~~~~~~~
2020-05-19 10:37:27 +00:00
Jan Beich c94ef092ff build: drop -Dout in favor of --prefix
$ meson --prefix=/tmp/foo _build
$ ninja install -C _build
[49/50] Installing files.
Installing waybar to /tmp/foo/bin
Traceback (most recent call last):
  File "/usr/lib/python3.6/site-packages/mesonbuild/mesonmain.py", line 127, in run
    return options.run_func(options)
  File "/usr/lib/python3.6/site-packages/mesonbuild/minstall.py", line 514, in run
    installer.do_install(datafilename)
  File "/usr/lib/python3.6/site-packages/mesonbuild/minstall.py", line 346, in do_install
    self.install_data(d)
  File "/usr/lib/python3.6/site-packages/mesonbuild/minstall.py", line 375, in install_data
    d.dirmaker.makedirs(outdir, exist_ok=True)
  File "/usr/lib/python3.6/site-packages/mesonbuild/minstall.py", line 55, in makedirs
    os.makedirs(path, exist_ok=exist_ok)
  File "/usr/lib/python3.6/os.py", line 210, in makedirs
    makedirs(head, mode, exist_ok)
  File "/usr/lib/python3.6/os.py", line 220, in makedirs
    mkdir(name, mode)
PermissionError: [Errno 13] Permission denied: '/etc/xdg'
FAILED: meson-install
2020-05-19 10:37:27 +00:00
Jan Beich 74db69dcb7 build: drop libinput as it was never used 2020-05-19 10:37:27 +00:00
Jan Beich fe2dd1e843 build: handle systems where libc++ is default
ld: error: unable to find library -lstdc++fs
ld: error: unable to find library -lc++abi
2020-05-19 10:37:27 +00:00
Diego GF ea4dec96e6 Build bluetooth module man page 2020-04-28 17:40:44 +02:00
Marc Radau 2d02ae5e97
Merge branch 'master' into master 2020-04-16 14:43:10 +02:00
Alex b9338c72c9 chore: 0.9.2 2020-04-11 12:24:49 +02:00
Marc Radau 8a5c3af949
Merge pull request #8 from Alexays/master
Merge Alexays:master into marcplustwo:master
2020-04-05 16:13:56 +02:00
Alex d5bd3be8de chore: use native git 2020-04-05 16:12:25 +02:00
Marc Radau 9abe1e2790
Merge branch 'master' into master 2020-02-23 23:00:09 +01:00
Danilo Spinella 16c68ee132 fix(meson): Support libc++ >=9.0.0
From LLVM libc++ documentation:
"Prior to LLVM 9.0, libc++ provides the implementation of the
filesystem library in a separate static library."

Now the filesystem library (not the experimental one) is shipped
inside the libc++.so library.

Check if '-lc++fs' link flag is needed and supported before adding
it.
2020-02-11 14:42:24 +01:00
Alex aae105c998 chore: 0.9.1 2020-02-10 23:47:23 +00:00
Skirmantas Kligys d1f427618f Cache calendar per clock instance, weekdays properly handle locales. 2020-02-05 11:07:47 -08:00
Skirmantas Kligys cd2db19267 Detect presence, call nl_langinfo() to get first day of week. 2020-02-03 17:18:34 -08:00
Skirmantas Kligys ea9591baea Switch from utfcpp to Glib::ustring for UTF-8 string mangling. 2020-02-02 15:59:24 -08:00
Skirmantas Kligys 8e05aab4d9 Current month calendar in clock tooltip. 2020-01-31 10:36:40 -08:00
Marc Radau f9618d30f3
Merge pull request #7 from Alexays/master
Merge latest changes from upstream
2020-01-23 17:30:33 +01:00
Michael Cordover 6e30b7af3c Remove duplicate dependency, use current locale 2020-01-23 08:27:00 -05:00
Michael Cordover 3130a57622 Add timezone support to clock module (closes #223) 2020-01-23 08:26:49 -05:00
Marc f0dbd8b78d properly structure rfkill util 2020-01-21 17:48:45 +01:00
Marc 2c4369a653 add basis for bluetooth module implementation 2020-01-21 15:46:08 +01:00
Alex 35d806b801 chore: 0.9.0 2019-12-28 12:35:09 +01:00
Aleksei Bavshin 0e87b3938a
deps: meson dependencies for gtk-layer-shell feature 2019-12-27 16:42:13 -08:00
Aleksei Bavshin d1637d34cf
refactor: fetch outputs from Gtk::Display instead of wl_registry.
gtk-layer-shell wants Gdk::Monitor instead of wl_output;
change code to deal with Gdk objects and slightly simplify it.
Requires gtkmm 3.22.0+ (first release with Gdk::Monitor support).
2019-12-27 16:42:12 -08:00
Guillaume Maudoux f4d2ca2736 custom formatter for numbers in 'pow' units format 2019-09-25 12:53:06 +02:00
Guillaume Maudoux 247589efbb Add some documentation for disks 2019-09-25 09:11:03 +02:00
Guillaume Maudoux 1d39ef5c8e Add a disk module 2019-09-25 08:47:33 +02:00
Дамјан Георгиевски 4b24c19fa7 add prefix to the configuration data 2019-09-10 14:12:52 +02:00
Дамјан Георгиевски ce50249c04 service file: allow for waybar installed in different prefix 2019-09-10 13:56:34 +02:00
Alex 5bb6fa384d
Revert "service file: allow for waybar installed in different prefix" 2019-09-10 12:06:06 +02:00
Дамјан Георгиевски f152ad9fa9 service file: allow for waybar installed in different prefix 2019-09-08 14:04:34 +02:00
Дамјан Георгиевски a0a3c01e79 install a systemd user unit
add a systemd --user unit/service file, so that one can run waybar as a
--user systemd service. when the service is enabled, Waybar will start
when the wayland-session.target is started.

this feature is automatically enabled if systemd is found, but can be disabled
with -Dsystemd=disabled
2019-09-07 22:16:03 +02:00
Jan Beich 0b008154d9 Add man-pages option like swaywm/sway@ba16f16e4d 2019-08-29 10:25:13 +00:00
Alex fe88a3fa81 chore: 0.8.0 2019-08-29 11:56:57 +02:00
Michael Aquilina ba5592c86a
Add waybar-states(5) 2019-08-26 22:49:04 +01:00