Commit Graph
5065 Commits
Author SHA1 Message Date
Alexis Rouillard 439261f0e3 Merge pull request #5112 from jaschiu/patch-2
fix(niri/workspaces): segfault when setting workspace button markup
2026-07-03 20:52:09 +02:00
Alexis Rouillard 2e0c34af5e Merge branch 'master' into fix/mpd-markup-truncation 2026-07-03 20:45:15 +02:00
Alexis Rouillard 8bedd8443d Merge branch 'master' into fix/sway-language-flag-disappears 2026-07-03 20:45:13 +02:00
Alexis Rouillard dfe2d80496 Merge branch 'master' into fix/tray-hide-when-empty 2026-07-03 20:45:10 +02:00
Alexis Rouillard 279aa67206 Merge branch 'master' into fix/hyprland-workspaces-scroll 2026-07-03 20:45:08 +02:00
Alexis Rouillard 5fce3926e0 Merge branch 'master' into master 2026-07-03 20:45:06 +02:00
Alexis Rouillard 9b016d8158 Merge branch 'master' into fix/hyprland-workspaces-taskbar-hover 2026-07-03 20:45:03 +02:00
Alexis Rouillard fa79b931e9 Merge branch 'master' into sayrus-gh/sway-workspaces-quotes 2026-07-03 20:45:01 +02:00
Alexis Rouillard 555dcb1776 Merge branch 'master' into master 2026-07-03 20:44:58 +02:00
Alexis Rouillard 0445607fb6 Merge branch 'master' into mpd-duration 2026-07-03 20:44:45 +02:00
Alexis Rouillard 0116808f4b Merge pull request #5079
Fix (memory): Fix tooltip showing incorrect unit and add proper unit initialization
2026-07-03 20:43:20 +02:00
Alexis Rouillard e20864991c Merge pull request #5043
fix(hyprland/workspaces): fix IPC call when using move-to-monitor
2026-07-03 20:43:17 +02:00
Alexis Rouillard 3d64071bab Merge pull request #5108 from SaveTheRbtz/codex-json-parser-buffer
perf(json): parse directly from string buffers
2026-07-03 19:56:40 +02:00
Alexis Rouillard 260a68cf58 Merge pull request #5100 from SaveTheRbtz/codex-mpd-playing-update
perf(mpd): avoid duplicate playing-state updates
2026-07-03 19:55:23 +02:00
Alexis Rouillard c166d98b0d Merge pull request #5010 from Neltharion01/master
Fix connection loop in pulseaudio
2026-07-03 19:54:51 +02:00
Alexis Rouillard 2ece13775e Merge pull request #5058 from typedrifter/fix-cursor-crash
fix(amodule): prevent crash when cursor timeout fires after destruction
2026-07-03 19:54:25 +02:00
Alexis Rouillard 91b0b30aac Merge pull request #5101 from SaveTheRbtz/codex-mpd-song-warning
fix(mpd): avoid false no-song warning when stopped
2026-07-03 19:52:58 +02:00
Alexis Rouillard 9dd927e8da Merge pull request #5076 from muratyalcin-ce/master
Fix (wayfire/backend): Fixed unhandled exception (out_of_range) after…
2026-07-03 19:52:25 +02:00
Alexis Rouillard 6df22ab348 Merge pull request #5154 from JuustKiwi/feature/dpms-suspend
feat(modules): pause background threads when display is asleep
2026-07-03 19:49:56 +02:00
Alexis Rouillard 48e9dd3b64 Merge pull request #5123 from martuscellifaria/master
fix(delayWorker): stop loop for static modules with no exec command
2026-07-03 19:45:40 +02:00
Alexis Rouillard 44ec750b76 Merge pull request #5121 from InetAddress/fix-battery-hotplug-crash-1
fix(battery): prevent crash when removing a hot-plugged device
2026-07-03 19:44:01 +02:00
Ibrahim Issa 4d1a561cdc feat(modules): pause background threads when display is asleep
Currently, modules polling hardware nodes continuously wake up kernel drivers even when the monitor is asleep (e.g., DPMS off), flooding dmesg.

- Adds 'disable-on-sleep' config flag
- Hooks GTK window map/unmap signals to track DPMS state
- Propagates suspend/resume calls to AModule worker threads
2026-07-03 18:44:03 +02:00
Grin 601e84d159 feat(ALabel): allow custom percentage thresholds in format-icons
Previously, format-icons with N icons would divide the 0-100 range
into N equal parts. This made it impossible to define custom ranges
like 0%, 1-69%, 70-100%.

This adds support for an alternative object syntax in format-icons:

"format-icons": [
    { "icon": "▁", "max": 0},
    { "icon": "▅", "max": 69 },
    { "icon": "▇", "max": 100 }
]

The array is iterated in order and the first icon whose max value
is >= the current percentage is returned. If no threshold matches,
the last icon is used as fallback. The existing string array syntax
remains fully supported and unchanged.

Applies to both getIcon overloads, affecting all modules that use
format-icons (battery, pulseaudio, network, backlight, etc.).

Closes #5150
2026-07-01 17:23:51 -03:00
Muhammed Sahin 22ce588783 Fallback formatting when format-paused is missing uses ALabel
With the minimal change the paused state, if format-paused state is not
set, will show the Alabel if the Alabel was active.
2026-06-27 17:18:52 +02:00
Éric NICOLAS 42f2832d21 docs(man): document light and dark stylesheets 2026-06-20 17:42:23 +02:00
Runxi Yu e37fcee35d fix(sni): ignore name/pixmap updates for custom icons 2026-06-19 05:51:00 +00:00
Johannes Haase 47b2ff09b7 feat(cursor): use cursor-shape-v1 cursor names instead of Gdk::CursorType 2026-06-16 23:27:27 +02:00
Robert M. Thomson 942411d7a1 Force layer-shell commit after configure
Assisted-by: pi:gpt-5.5
2026-06-15 10:36:29 +02:00
iamcheyan 14e59daae4 feat(wlr/taskbar): expose active toplevel state on the bar window
Add opt-in bar-css-states option to wlr/taskbar module.

When enabled, the module tracks the active workspace and updates CSS
classes on window#waybar to reflect the current window state:
- toplevel-active: when a window is focused
- toplevel-maximized: when any non-minimized window on active workspace is maximized
- toplevel-minimized: when the active window is minimized
- toplevel-fullscreen: when any non-minimized window on active workspace is fullscreen

This feature requires compositor support for ext-workspace-v1 protocol
to correctly track workspace membership. Without it, classes fall back
to the active application state only.

Also includes active-only option implementation.

Changes:
- Add ext-workspace-v1 protocol support for workspace tracking
- Implement WorkspaceState tracking in Taskbar class
- Add workspace management lifecycle (create/remove/done)
- Add bar CSS class update logic with aggregation
- Add visible() getter to Task class
- Implement active-only task visibility control
- Update man page with documentation and CSS examples

Signed-off-by: iamcheyan <iamcheyan@users.noreply.github.com>
2026-06-13 11:34:29 +09:00
martuscellifaria 0bc664a99e Readded the whitespace from the original code 2026-06-12 09:52:03 +02:00
martuscellifaria eb3669decc Rearranging code in a non-redundant way. 2026-06-12 09:48:44 +02:00
martuscellifaria 4ef828f712 Fixing CPU usage spike on Waybar 2026-06-12 09:14:04 +02:00
InetAddress 61178f7b0e Change error handling to warning
Fixes a bug where removing a hot-plugged device mid-loop causes a filesystem error that turns into a fatal runtime error that crashes waybar entirely, changed to warning instead of runtime error.
2026-06-12 04:38:10 +00:00
Jason Chiu 2d9fee144e Update privacy.cpp 2026-06-09 06:51:14 +00:00
Jason Chiu 2506196274 Update privacy.hpp 2026-06-09 06:49:41 +00:00
Jason Chiu fb829c8a8e ## fix(niri/workspaces): crash (segfault) when setting workspace button markup
### Problem
Waybar segfaults on startup when `niri/workspaces` is the only configured
module (default options). Right after the first `WorkspacesChanged` event:
 
    Thread 1 "waybar" received signal SIGSEGV
    #0 gtk_label_set_markup ()
    #1 waybar::modules::niri::Workspaces::doUpdate () at src/modules/niri/workspaces.cpp:106
 
### Root cause
[doUpdate()](cci:1://file:///home/lj/Downloads/Waybar/src/modules/niri/window.cpp:27:0-90:1) set the label markup via:
 
    static_cast<Gtk::Label*>(button.get_children()[0])->set_markup(name);
 
The button's child *is* a valid `GtkLabel`, but gtkmm's `get_children()`
returns it wrapped as a generic `Gtk::Widget` (confirmed: `dynamic_cast`
to `Gtk::Label*` yields `nullptr`). The unchecked `static_cast` then
performs an invalid downcast, producing a corrupt pointer whose `gobj()`
is garbage (`0x1`), so `gtk_label_set_markup()` dereferences it and crashes.
 
This is reliably triggered when no other module has instantiated a
`Gtk::Label` yet (so the `Gtk::Label` wrapper isn't registered), which is
exactly the case for a `niri/workspaces`-only bar. The same idiom exists in
`sway/workspaces` and `wayfire/workspaces`; it's masked there because typical
configs include other label-using modules.

### Testing
- Reproduced the crash on 0.15.0 / current `master` with a minimal
  `"modules-left": ["niri/workspaces"]` config under niri.
- After the fix: no crash; three workspace buttons render with correct
  names/labels (`niri-workspace-1/2/3`).
2026-06-09 06:20:05 +00:00
Zuodong Yu f7b9d8c123 modules/niri: add {total} format token to workspaces 2026-06-07 17:35:37 +08:00
Alexey Ivanov bef7df8f08 fix(mpd): avoid false no-song warning when stopped 2026-06-05 08:40:49 -07:00
Alexey Ivanov 0cccf0d8b5 perf(mpd): avoid duplicate playing-state updates 2026-06-04 15:23:54 -07:00
Alexey Ivanov 2190871a68 perf(label): skip redundant markup updates 2026-06-04 15:18:43 -07:00
Alexey Ivanov 5cce616d3d perf(json): parse directly from string buffers 2026-06-04 15:03:40 -07:00
oqlatulesba3 3315631012 fix(sni): retry Host proxy creation on transient errors
When Host::proxyReady fails to create the SnWatcher proxy (e.g. because
the Watcher has not finished exporting /StatusNotifierWatcher yet), the
cancellable is left set, causing nameAppeared to early-return on every
subsequent event (see the // TODO marker). The Host is then stuck
without a watcher, and the tray module reports
'No such object path /StatusNotifierWatcher' until the bar is fully
restarted.

Clear the cancellable on non-CANCELLED errors and schedule a single
delayed retry of nameAppeared. The guard `watcher_ != nullptr` skips
the retry if a parallel call already succeeded.

Closes #3468
2026-06-02 10:51:05 +03:00
Matthew Orlando 0af3ca1a4e custom_modules: Fix mediaplayer.py handling untitled track
* Fix crash calling method on None
* Show artist if title is None
2026-05-31 10:01:25 -07:00
DreamMaoMao 3eeffbe389 feat: add mango modules: workspace,language,keymode,window,layout 2026-05-29 12:56:40 +08:00
muratyalcin-ce 5ea824c24c Use unit in config for memory module tooltip 2026-05-28 23:56:52 +03:00
muratyalcin-ce 31a161eb06 Fix (wayfire/backend): Fixed unhandled exception (out_of_range) after no valid outputs in unordered_map 2026-05-27 23:39:39 +03:00
Ansari 2ff2861e88 Merge remote-tracking branch 'upstream/master' 2026-05-27 12:13:51 +05:30
Artur Ciesielski 97acbf30d0 Update man pages for persistent-workspaces in sway/workspaces 2026-05-26 20:38:14 +02:00
Artur Ciesielski 415da7aef4 sway/workspaces: refer to outputs by their monitor identifier (make and model) 2026-05-26 19:39:03 +02:00
jacobs ec2651370e (Fix) (sway workspace module) persistent workspaces always removed 2026-05-26 11:09:45 +01:00