mirror of
https://github.com/rad4day/Waybar.git
synced 2025-07-13 22:52:30 +02:00
hyprland/workspaces: allow using the original window class/title
This turns the values of window rewrite rules in hyprland/workspaces from static strings to format strings with the values {class} and {title} available.
This commit is contained in:
@ -891,7 +891,9 @@ std::string Workspaces::getRewrite(std::string window_class, std::string window_
|
||||
} else {
|
||||
windowReprKey = fmt::format("class<{}>", window_class);
|
||||
}
|
||||
return m_windowRewriteRules.get(windowReprKey);
|
||||
auto const rewriteRule = m_windowRewriteRules.get(windowReprKey);
|
||||
return fmt::format(fmt::runtime(rewriteRule), fmt::arg("class", window_class),
|
||||
fmt::arg("title", window_title));
|
||||
}
|
||||
|
||||
WindowCreationPayload::WindowCreationPayload(std::string workspace_name,
|
||||
|
Reference in New Issue
Block a user