From c6f6ebe96694d9765762062158971b78f11686cf Mon Sep 17 00:00:00 2001 From: kyak Date: Sun, 10 Dec 2023 15:08:58 +0300 Subject: [PATCH] Address comments --- src/theme.c | 6 ++++++ src/workspaces.c | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/theme.c b/src/theme.c index 1c9429bd..0df6f107 100644 --- a/src/theme.c +++ b/src/theme.c @@ -905,6 +905,12 @@ post_processing(struct theme *theme) memcpy(theme->osd_border_color, theme->osd_label_text_color, sizeof(theme->osd_border_color)); } + if (theme->osd_workspace_switcher_boxes_width == 0) { + theme->osd_workspace_switcher_boxes_height = 0; + } + if (theme->osd_workspace_switcher_boxes_height == 0) { + theme->osd_workspace_switcher_boxes_width = 0; + } } void diff --git a/src/workspaces.c b/src/workspaces.c index b6820c4f..2ca5f9f1 100644 --- a/src/workspaces.c +++ b/src/workspaces.c @@ -69,7 +69,7 @@ _osd_update(struct server *server) size_t workspace_count = wl_list_length(&server->workspaces); uint16_t marker_width = workspace_count * (rect_width + padding) - padding; uint16_t width = margin * 2 + (marker_width < 200 ? 200 : marker_width); - uint16_t height = margin * 3 + rect_height + font_height(&rc.font_osd); + uint16_t height = margin * (hide_boxes ? 2 : 3) + rect_height + font_height(&rc.font_osd); cairo_t *cairo; cairo_surface_t *surface;