From 3948145d66892d7055f47ace9ed6474344b5c119 Mon Sep 17 00:00:00 2001 From: Daniel Eklöf Date: Sun, 10 Jan 2021 15:40:33 +0100 Subject: render: don’t center content while we’re being resized MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Doing so causes the content to jump around while interactively resizing the window. --- render.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'render.c') diff --git a/render.c b/render.c index e45140e5..8ad5ee0c 100644 --- a/render.c +++ b/render.c @@ -2671,7 +2671,7 @@ maybe_resize(struct terminal *term, int width, int height, bool force) const int total_x_pad = term->width - grid_width; const int total_y_pad = term->height - grid_height; - if (term->conf->center) { + if (term->conf->center && !term->window->is_resizing) { term->margins.left = total_x_pad / 2; term->margins.top = total_y_pad / 2; } else { -- cgit v1.3