From 0046eed96903c745142208c40aa5f10d0b5931cb Mon Sep 17 00:00:00 2001 From: Ryan Dwyer Date: Sat, 7 Jul 2018 15:49:51 +1000 Subject: Fix titles when container titles contain UTF-8 characters The title and marks textures would have their height set from the config's computed max font height, but the textures were not regenerated when the config's max font height changed which made a gap appear. Rather than making it regenerate the title textures every time the config font height was changed, I've changed it to just make the textures the height of the title itself and fill any gap when rendering. Also, the title_width and marks_width variables have been renamed to make it more obvious that they are in output-buffer-local coordinates. Fixes #1936. --- sway/tree/view.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sway/tree/view.c') diff --git a/sway/tree/view.c b/sway/tree/view.c index e46cb327..3ef79fa8 100644 --- a/sway/tree/view.c +++ b/sway/tree/view.c @@ -923,7 +923,7 @@ static void update_marks_texture(struct sway_view *view, double scale = output->sway_output->wlr_output->scale; int width = 0; - int height = config->font_height * scale; + int height = view->swayc->title_height * scale; cairo_t *c = cairo_create(NULL); get_text_size(c, config->font, &width, NULL, scale, false, "%s", buffer); -- cgit v1.2.3