mirror of
https://github.com/rad4day/Waybar.git
synced 2023-12-21 10:22:59 +01:00
Add IDs to sway workspace buttons for CSS styling
In case you want to style a specific workspace add IDs to the workspace buttons. Styling is done by matching button#sway-workspace-${name}.
This commit is contained in:
@ -248,6 +248,7 @@ Gtk::Button &Workspaces::addButton(const Json::Value &node) {
|
||||
auto pair = buttons_.emplace(node["name"].asString(), node["name"].asString());
|
||||
auto &&button = pair.first->second;
|
||||
box_.pack_start(button, false, false, 0);
|
||||
button.set_name("sway-workspace-" + node["name"].asString());
|
||||
button.set_relief(Gtk::RELIEF_NONE);
|
||||
if (!config_["disable-click"].asBool()) {
|
||||
button.signal_pressed().connect([this, node] {
|
||||
|
Reference in New Issue
Block a user