mirror of
https://github.com/rad4day/Waybar.git
synced 2023-12-21 10:22:59 +01:00
commit
db95644d26
@ -82,6 +82,12 @@ Also a minimal example configuration can be found on the at the bottom of this m
|
|||||||
default: *true* ++
|
default: *true* ++
|
||||||
Option to request an exclusive zone from the compositor. Disable this to allow drawing application windows underneath or on top of the bar.
|
Option to request an exclusive zone from the compositor. Disable this to allow drawing application windows underneath or on top of the bar.
|
||||||
|
|
||||||
|
*fixed-center* ++
|
||||||
|
typeof: bool ++
|
||||||
|
default: *true*
|
||||||
|
Prefer fixed center position for the `modules-center` block. The center block will stay in the middle of the bar whenever possible. It can still be pushed around if other blocks need more space.
|
||||||
|
When false, the center block is centered in the space between the left and right block.
|
||||||
|
|
||||||
*passthrough* ++
|
*passthrough* ++
|
||||||
typeof: bool ++
|
typeof: bool ++
|
||||||
default: *false* ++
|
default: *false* ++
|
||||||
|
@ -767,7 +767,11 @@ void waybar::Bar::getModules(const Factory& factory, const std::string& pos, Gtk
|
|||||||
auto waybar::Bar::setupWidgets() -> void {
|
auto waybar::Bar::setupWidgets() -> void {
|
||||||
window.add(box_);
|
window.add(box_);
|
||||||
box_.pack_start(left_, false, false);
|
box_.pack_start(left_, false, false);
|
||||||
|
if (config["fixed-center"].isBool() ? config["fixed-center"].asBool() : true) {
|
||||||
box_.set_center_widget(center_);
|
box_.set_center_widget(center_);
|
||||||
|
} else {
|
||||||
|
box_.pack_start(center_, true, false);
|
||||||
|
}
|
||||||
box_.pack_end(right_, false, false);
|
box_.pack_end(right_, false, false);
|
||||||
|
|
||||||
// Convert to button code for every module that is used.
|
// Convert to button code for every module that is used.
|
||||||
|
Loading…
Reference in New Issue
Block a user