Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions man/waybar.5.scd.in
Original file line number Diff line number Diff line change
Expand Up @@ -374,6 +374,8 @@ A group may hide all but one element, showing them only on mouse hover. In order
Defines the direction of the transition animation. If true, the hidden elements will slide from left to right. If false, they will slide from right to left.
When the bar is vertical, it reads as top-to-bottom.

Group drawers are also given the `.expanded` CSS class when they are expanded.

```
"group/power": {
"orientation": "inherit",
Expand Down
2 changes: 2 additions & 0 deletions src/group.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -95,11 +95,13 @@ Group::Group(const std::string& name, const std::string& id, const Json::Value&
void Group::show_group() {
box.set_state_flags(Gtk::StateFlags::STATE_FLAG_PRELIGHT);
revealer.set_reveal_child(true);
box.get_style_context()->add_class("expanded");
}

void Group::hide_group() {
box.unset_state_flags(Gtk::StateFlags::STATE_FLAG_PRELIGHT);
revealer.set_reveal_child(false);
box.get_style_context()->remove_class("expanded");
}

bool Group::handleMouseEnter(GdkEventCrossing* const& e) {
Expand Down