fixed calculating maximum length of string values in setup menu
authorHolger Schemel <info@artsoft.org>
Tue, 2 Oct 2018 19:10:08 +0000 (21:10 +0200)
committerHolger Schemel <info@artsoft.org>
Tue, 2 Oct 2018 19:10:08 +0000 (21:10 +0200)
src/screens.c

index 127333b..758b3f6 100644 (file)
@@ -6509,7 +6509,7 @@ static void drawSetupValue(int screen_pos, int setup_info_pos_raw)
   }
   else if (type & TYPE_STRING)
   {
-    int max_value_len = (SCR_FIELDX - 2) * 2;
+    int max_value_len = (SXSIZE - 2 * TILEX) / font_width_default;
 
     xpos = MENU_SCREEN_START_XPOS;