From 2935e24cf506ea2ab18952b3d525db0ef4d83762 Mon Sep 17 00:00:00 2001 From: Mikkel Oscar Lyderik Date: Sun, 20 Mar 2016 12:29:47 +0100 Subject: Implement 'smart_gaps' feature from i3-gaps --- sway/container.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sway/container.c') diff --git a/sway/container.c b/sway/container.c index e4c20bc9..9330a3de 100644 --- a/sway/container.c +++ b/sway/container.c @@ -675,7 +675,7 @@ int swayc_gap(swayc_t *container) { return container->gaps >= 0 ? container->gaps : config->gaps_inner; } else if (container->type == C_WORKSPACE) { int base = container->gaps >= 0 ? container->gaps : config->gaps_outer; - if (config->edge_gaps) { + if (config->edge_gaps && !(config->smart_gaps && container->children->length == 1)) { // the inner gap is created via a margin around each window which // is half the gap size, so the workspace also needs half a gap // size to make the outermost gap the same size (excluding the -- cgit v1.2.3