summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--apps/gui/line.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/apps/gui/line.c b/apps/gui/line.c
index 449d01a896..55100f715c 100644
--- a/apps/gui/line.c
+++ b/apps/gui/line.c
@@ -190,14 +190,14 @@ static void print_line(struct screen *display,
icon_h = get_icon_height(display->screen_type);
icon_w = get_icon_width(display->screen_type);
tempbuf_idx = 0;
- /* vertically center string on the line
- * x/2 - y/2 rounds up compared to (x-y)/2 if one of x and y is odd */
- y += height/2 - display->getcharheight()/2;
/* For the icon use a differnet calculation which to round down instead.
* This tends to align better with the font's baseline for small heights.
* A proper aligorithm would take the baseline into account but this has
* worked sufficiently well for us (fix this if needed) */
icon_y = y + (height - icon_h)/2;
+ /* vertically center string on the line
+ * x/2 - y/2 rounds up compared to (x-y)/2 if one of x and y is odd */
+ y += height/2 - display->getcharheight()/2;
/* parse format string */
while (xpos < max_width)