diff options
Diffstat (limited to 'sway/layout.c')
-rw-r--r-- | sway/layout.c | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/sway/layout.c b/sway/layout.c index a6a241f4..02c92026 100644 --- a/sway/layout.c +++ b/sway/layout.c | |||
@@ -135,12 +135,12 @@ void arrange_windows(swayc_t *container, int width, int height) { | |||
135 | { | 135 | { |
136 | struct wlc_geometry geometry = { | 136 | struct wlc_geometry geometry = { |
137 | .origin = { | 137 | .origin = { |
138 | .x = container->x, | 138 | .x = container->x + container->gaps / 2, |
139 | .y = container->y | 139 | .y = container->y + container->gaps / 2 |
140 | }, | 140 | }, |
141 | .size = { | 141 | .size = { |
142 | .w = width, | 142 | .w = width - container->gaps, |
143 | .h = height | 143 | .h = height - container->gaps |
144 | } | 144 | } |
145 | }; | 145 | }; |
146 | if (wlc_view_get_state(container->handle) & WLC_BIT_FULLSCREEN) { | 146 | if (wlc_view_get_state(container->handle) & WLC_BIT_FULLSCREEN) { |
@@ -148,10 +148,10 @@ void arrange_windows(swayc_t *container, int width, int height) { | |||
148 | while (parent->type != C_OUTPUT) { | 148 | while (parent->type != C_OUTPUT) { |
149 | parent = parent->parent; | 149 | parent = parent->parent; |
150 | } | 150 | } |
151 | geometry.origin.x = 0; | 151 | geometry.origin.x = container->gaps / 2; |
152 | geometry.origin.y = 0; | 152 | geometry.origin.y = container->gaps / 2; |
153 | geometry.size.w = parent->width; | 153 | geometry.size.w = parent->width - container->gaps; |
154 | geometry.size.h = parent->height; | 154 | geometry.size.h = parent->height - container->gaps; |
155 | wlc_view_set_geometry(container->handle, 0, &geometry); | 155 | wlc_view_set_geometry(container->handle, 0, &geometry); |
156 | wlc_view_bring_to_front(container->handle); | 156 | wlc_view_bring_to_front(container->handle); |
157 | } else { | 157 | } else { |