From 17f979d86687b7da936fff8d3abce7a637263476 Mon Sep 17 00:00:00 2001 From: Charles Dang Date: Mon, 14 Dec 2020 06:21:20 +1100 Subject: [PATCH] GUI2: removed pixel offset from GUI__TEXT_VERTICALLY_CENTRED Fixes the text of menu_buttons being 1 pixel too high. Seems this is a relic from 2016 and me tweaking the formula to try and get things more centered in buttons... But in that case, adjustments shuld probably be directly made to buttons, not here. --- data/gui/macros/_initial.cfg | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/data/gui/macros/_initial.cfg b/data/gui/macros/_initial.cfg index abf900c87006..cde48d8a2a8f 100644 --- a/data/gui/macros/_initial.cfg +++ b/data/gui/macros/_initial.cfg @@ -21,16 +21,14 @@ # If the text is too wide it returns the left side. # Rounding happens to the left side. #define GUI__TEXT_HORIZONTALLY_CENTRED - "(max((width - text_width) / 2, 0))" -#enddef +"(max((width - text_width) / 2, 0))" #enddef # Centers the text vertically. # # If the text is too high it returns the top side. # Rounding happens to the bottom side. #define GUI__TEXT_VERTICALLY_CENTRED - "(max((height - text_height - 2) / 2, 0))" -#enddef +"(max((height - text_height) / 2, 0))" #enddef #define GUI__CENTERED_TEXT FONT_SIZE FONT_STYLE FONT_COLOR [text]