Address comments

This commit is contained in:
kyak 2023-12-10 15:08:58 +03:00
parent 38cfea7e09
commit c6f6ebe966
2 changed files with 7 additions and 1 deletions

View file

@ -905,6 +905,12 @@ post_processing(struct theme *theme)
memcpy(theme->osd_border_color, theme->osd_label_text_color, memcpy(theme->osd_border_color, theme->osd_label_text_color,
sizeof(theme->osd_border_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 void

View file

@ -69,7 +69,7 @@ _osd_update(struct server *server)
size_t workspace_count = wl_list_length(&server->workspaces); size_t workspace_count = wl_list_length(&server->workspaces);
uint16_t marker_width = workspace_count * (rect_width + padding) - padding; uint16_t marker_width = workspace_count * (rect_width + padding) - padding;
uint16_t width = margin * 2 + (marker_width < 200 ? 200 : marker_width); 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_t *cairo;
cairo_surface_t *surface; cairo_surface_t *surface;