Skip to content

hyprbars: add fallback button loading from file#665

Open
victorsosaMx wants to merge 1 commit into
hyprwm:mainfrom
victorsosaMx:main
Open

hyprbars: add fallback button loading from file#665
victorsosaMx wants to merge 1 commit into
hyprwm:mainfrom
victorsosaMx:main

Conversation

@victorsosaMx

Copy link
Copy Markdown

addConfigKeyword() está deprecated y su handler no siempre es invocado por el parser de Hyprlang (probado en Hyprland 0.55 con config legacy).

Este cambio agrega un fallback: los botones se leen desde ~/.config/hypr/hyprbars-buttons.conf en cada config.reloaded, asegurando que siempre estén disponibles aunque el handler del parser falle.

addConfigKeyword() is deprecated and its handler may not be invoked
by the Hyprlang parser on some versions (e.g. Hyprland 0.55 legacy
config). As a workaround, also load button definitions from
~/.config/hypr/hyprbars-buttons.conf on every config reload.
@victorsosaMx

victorsosaMx commented May 14, 2026

Copy link
Copy Markdown
Author

addConfigKeyword() is deprecated and its handler is not
always invoked by the Hyprlang parser (tested on Hyprland
0.55 with legacy config).

This change adds a fallback: buttons are loaded from
~/.config/hypr/hyprbars-buttons.conf on every
config.reloaded event, ensuring they're always available
even when the parser handler fails.

File format (one button per line):

  rgba(ff5555ff), 15, X, hyprctl dispatch killactive,  rgba(ffffffff)
  rgba(f1fa8cff), 15, +, hyprctl dispatch movetoworkspace  special, rgba(ffffffff)
  rgba(50fa7bff), 15, -, hyprctl dispatch fullscreen 1,  rgba(ffffffff)
imagen

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant