aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sway/tree/view.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/sway/tree/view.c b/sway/tree/view.c
index 33d16e29..fcdd06f7 100644
--- a/sway/tree/view.c
+++ b/sway/tree/view.c
@@ -262,7 +262,7 @@ void view_autoconfigure(struct sway_view *view) {
262 con->pending.border_left = con->pending.border_right = true; 262 con->pending.border_left = con->pending.border_right = true;
263 double y_offset = 0; 263 double y_offset = 0;
264 264
265 if (!container_is_floating(con) && ws) { 265 if (!container_is_floating_or_child(con) && ws) {
266 if (config->hide_edge_borders == E_BOTH 266 if (config->hide_edge_borders == E_BOTH
267 || config->hide_edge_borders == E_VERTICAL) { 267 || config->hide_edge_borders == E_VERTICAL) {
268 con->pending.border_left = con->pending.x != ws->x; 268 con->pending.border_left = con->pending.x != ws->x;
@@ -281,14 +281,15 @@ void view_autoconfigure(struct sway_view *view) {
281 (config->hide_edge_borders_smart == ESMART_NO_GAPS && 281 (config->hide_edge_borders_smart == ESMART_NO_GAPS &&
282 !gaps_to_edge(view)); 282 !gaps_to_edge(view));
283 if (smart) { 283 if (smart) {
284 bool show_border = container_is_floating_or_child(con) || 284 bool show_border = !view_is_only_visible(view);
285 !view_is_only_visible(view);
286 con->pending.border_left &= show_border; 285 con->pending.border_left &= show_border;
287 con->pending.border_right &= show_border; 286 con->pending.border_right &= show_border;
288 con->pending.border_top &= show_border; 287 con->pending.border_top &= show_border;
289 con->pending.border_bottom &= show_border; 288 con->pending.border_bottom &= show_border;
290 } 289 }
290 }
291 291
292 if (!container_is_floating(con)) {
292 // In a tabbed or stacked container, the container's y is the top of the 293 // In a tabbed or stacked container, the container's y is the top of the
293 // title area. We have to offset the surface y by the height of the title, 294 // title area. We have to offset the surface y by the height of the title,
294 // bar, and disable any top border because we'll always have the title bar. 295 // bar, and disable any top border because we'll always have the title bar.