From: tokyo4j Date: Tue, 26 Nov 2024 00:44:27 +0000 (+0900) Subject: menu: don't include menu.border.width for menu title height X-Git-Url: https://git.mdlowis.com/?a=commitdiff_plain;h=6b7157f04617b258cc0a13cb8a4b89be5b73b73b;p=proto%2Flabwc.git menu: don't include menu.border.width for menu title height It was a cruft from my experiment of adding borders around titles. It even caused an integer overflow because theme->menu_border_width can be INT_MIN when menu_header_height is calculated. --- diff --git a/src/theme.c b/src/theme.c index 0637a8df..439a3184 100644 --- a/src/theme.c +++ b/src/theme.c @@ -1457,8 +1457,7 @@ post_processing(struct theme *theme) + 2 * theme->menu_items_padding_y; theme->menu_header_height = font_height(&rc.font_menuheader) - + 2 * theme->menu_items_padding_y - + 2 * theme->menu_border_width; + + 2 * theme->menu_items_padding_y; theme->osd_window_switcher_item_height = font_height(&rc.font_osd) + 2 * theme->osd_window_switcher_item_padding_y