Commit Graph

81 Commits

Author SHA1 Message Date
Visal Vijay
196589cf32 Update ALabel.cpp 2026-03-17 01:17:08 +05:30
Visal Vijay
acf6f117ea Update ALabel.cpp 2026-03-17 01:13:14 +05:30
Visal Vijay
3cfb622660 Fix menu-actions GTK callback pointer handling 2026-03-16 23:45:28 +05:30
Austin Horstman
f48fce57dc fix(menu): keep popup menus alive after builder teardown
The popup menu was retrieved from GtkBuilder and stored in menu_, but the builder was unref'd immediately after construction. That left the later popup path operating on a builder-owned GtkMenu whose lifetime was no longer guaranteed, which matches the GTK_IS_WIDGET and GTK_IS_MENU assertions from the regression report.

Take an owned reference to the built menu and release it in AModule teardown so popup menus stay valid without extending the lifetime of the whole builder.

Signed-off-by: Austin Horstman <khaneliman12@gmail.com>
2026-03-06 18:39:16 -06:00
Bryce Gust
d929f1a62c Fix 4894 - float interval cast 2026-03-02 17:58:00 -06:00
Alex
ef3d55980e fix: some crashes 2026-02-24 00:49:08 +01:00
copilot-swe-agent[bot]
c4982efa95 Add output_name parameter to forkExec for WAYBAR_OUTPUT_NAME env var
Co-authored-by: Alexays <13947260+Alexays@users.noreply.github.com>
2026-02-04 09:14:45 +00:00
copilot-swe-agent[bot]
68d3e13fdd Fix menu freezing when launching applications
Co-authored-by: Alexays <13947260+Alexays@users.noreply.github.com>
2026-02-04 09:09:44 +00:00
Pierre Lairez
d8e2392410 Fixes #4521 and #4522
The problem is commit 2b552f7 which introduces a minimum interval time
of 1ms. But then, in modules/custom.cpp, the constructor tests if the
interval is nonzero to distinguish continuous workers from delay workers.
2025-10-03 11:24:18 +02:00
aidansunbury
2b81782fa9 more changes 2025-08-16 16:01:41 -07:00
aidansunbury
2b552f7fb6 compat 2025-08-16 15:34:43 -07:00
aidansunbury
6dc5a73a02 initial changes 2025-08-16 15:29:59 -07:00
markx86
08da7b5282 feat: Add support for battery related events 2025-06-22 17:45:12 +02:00
Ethan Martin
d1dac2854a Allow using wildcards in config include paths
Updates `Config::tryExpandPath()` to return a vector of expanded path
matches instead of a single path wrapped in an optional, with an empty
vector indicating no matches.

`Config::resolveConfigIncludes()` iterates over all of these matches,
while other instances of path expansion (such as finding the base config
path) retain their existing behavior and only use the first match.
2025-01-02 20:50:39 -05:00
Alex
d177969f51 chore: lint 2024-09-13 09:53:15 +02:00
Michal Suchanek
5b1826d2f6 label: Add warning for invalid rotate property 2024-09-08 13:57:37 +02:00
yangyingchao
7ec1343ad5 fix #3490: expand menu file before opening it 2024-08-01 18:06:00 +08:00
Austin Horstman
14c3235c12 src: clang-tidy 2024-07-02 10:38:58 -05:00
Benjamin Voisin
161c8c4c47 🥅 do not crash when unable to make the menu
When the menu cannot be built (file not existing, or wrongly formatted),
     the menu is not created and a warning with an explanaition is
     displayed.
2024-05-28 19:31:26 +02:00
Benjamin Voisin
21751b2faa 🎨 clang-tidy 2024-05-09 20:59:25 +02:00
Benjamin Voisin
3b87b83076 ♻️ move GMenu to ALabel class 2024-05-09 18:34:26 +02:00
Alexis Rouillard
4c46d7d245 Merge pull request #2887 from dann-merlin/master
Add justify config option for Labels
2024-03-05 09:01:44 +01:00
Aleksei Bavshin
d590d508ca feat: add module class to the root elements of the modules
Previously, the only way to select all the module labels was with the
following kind of selector:
```css
.modules-left > widget > label,
.modules-center > widget > label,
.modules-right > widget > label {
    /* ... */
}
```
(and a matching block for the `box` containers).

Now, this can be expressed as
```css
label.module, box.module {
    /* ... */
}
```
2024-02-14 22:41:13 -08:00
Merlin Sievers
89b3203bfa Add justify config option for Labels
This is especially useful for centering labels on vertical bars.
2024-02-05 14:44:59 +01:00
Tamino Bauknecht
dd1de3efbf Revert "Revert "Fix potential memory leaks""
This reverts commit 2d33c20231 and
reapplies various patches for memory leaks.
The reason for the revert was a bug for a maximum duration interval
which caused sleep_for() to cause unpredictable behavior.
2023-10-24 17:51:38 +02:00
Alexis Rouillard
2d33c20231 Revert "Fix potential memory leaks" 2023-10-22 09:44:46 +02:00
Tamino Bauknecht
89e85db790 ALabel: make use of std::chrono::max() instead of magic number 2023-10-21 11:50:38 +02:00
Alex
f2fcadbf62 refactor: lint 2022-04-06 08:37:19 +02:00
Mohammad Amin Sameti
48117a2e97 Fix divide by zero (#1303) 2021-10-29 14:12:48 +03:30
Patrick Nicolas
9c2b5efe7b Support per-device icon in pulseaudio 2021-07-15 09:20:43 +02:00
nullobsi
72cd753c02 align should use rotate property 2021-02-01 01:44:51 -08:00
nullobsi
c8d7b6fa92 rename fixed-length to min-length 2021-01-31 14:03:49 -08:00
nullobsi
8c70513a24 add common align config property to set text alignment
add fixed-length property to set the fixed width of the label
2021-01-31 13:58:41 -08:00
Johannes Christenson
f20dbbbd74 Fixing logic in getIcon 2021-01-03 19:08:06 +01:00
Pedro Côrte-Real
6f7d7e645a Prevent line breaks in ellipsized labels
If a label is being ellipsized it doesn't make sense to allow it to use
line breaks to have multiple lines.

Fixes #827
2020-08-19 23:38:59 +01:00
Daniel De Graaf
62082bdb01 clock: scroll through multiple timezones 2020-08-13 18:53:18 -04:00
Alex
6ca4e14b29 Feat icons vector (#716) 2020-05-22 21:23:04 +02:00
Alex
b40cdcb5bd refactor: call parent update 2020-04-12 18:30:21 +02:00
Alex
a6980fca7f feat: ellipsize modules 2019-06-28 14:16:09 +02:00
Alex
bd5146fdcf fix(Label): ELLIPSIZE all label modules 2019-06-28 13:49:04 +02:00
Alex
340ec7be91 refactor: AModule 2019-06-15 14:57:52 +02:00
Patrick Hilhorst
ae397c8fa2 ALabel: add smooth-scrolling-threshold 2019-06-11 17:56:10 +02:00
Alex
e999cca7a6 style: don't specify included namespaces 2019-05-22 12:15:59 +02:00
Alex
d24d85bebf refactor: move label name and id to label contructor 2019-05-22 12:06:24 +02:00
Alex
963d4f68e4 refactor: remove useless param 2019-05-16 09:39:06 +02:00
unresolvedsymbol
7e8eee0571 fix state behavior 2019-05-15 22:14:51 -05:00
Alex
92967c7c06 fix(Label): reverse only battery states 2019-05-13 11:36:34 +02:00
Alex
fcb23d3104 feat(temperature): format-icons 2019-05-13 11:31:05 +02:00
Dan
e158a3e132 feat(states): add generic 'states' to all labels 2019-05-02 22:24:29 -04:00
Alex
1a024db03c fix(idle_inhibitor): overload 2019-05-02 17:51:01 +02:00