From 898f696409b94a6c1e14663ead67fda7acaf64d4 Mon Sep 17 00:00:00 2001 From: root Date: Thu, 1 Jan 1970 09:55:58 +0900 Subject: fixed formatting of menu control mode string, and overwriting of next page arrow --- menus.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'menus.c') diff --git a/menus.c b/menus.c index cabeabe..c910210 100644 --- a/menus.c +++ b/menus.c @@ -272,7 +272,7 @@ void Show_Main_Menu(void) raw_str = g_string_append (raw_str, "GPIB+"); } if (globals.Remote.terminal_connections > 0) { - g_string_append_printf (raw_str, "%dTER", globals.Remote.terminal_connections); + g_string_append_printf (raw_str, "%dTER+", globals.Remote.terminal_connections); } if (globals.Remote.vxi_connections > 0) { g_string_append_printf (raw_str, "%dVXI", globals.Remote.vxi_connections); @@ -285,19 +285,19 @@ void Show_Main_Menu(void) g_free (step1); // shorten as required - gchar *step3 = conditional_regex_replace (strlen(step2) > LCD_col_width, step2, "LOCAL", "LO"); + gchar *step3 = conditional_regex_replace (strlen(step2) > (LCD_col_width-1), step2, "LOCAL", "LO"); g_free (step2); // shorten as required - gchar *step4 = conditional_regex_replace (strlen(step3) > LCD_col_width, step3, "TER", "T"); + gchar *step4 = conditional_regex_replace (strlen(step3) > (LCD_col_width-1), step3, "TER", "T"); g_free (step3); // shorten as required - gchar *step5 = conditional_regex_replace (strlen(step4) > LCD_col_width, step4, "GPIB", "GP"); + gchar *step5 = conditional_regex_replace (strlen(step4) > (LCD_col_width-1), step4, "GPIB", "GP"); g_free (step4); // shorten as required - gchar *step6 = conditional_regex_replace (strlen(step5) > LCD_col_width, step5, "VXI", "V"); + gchar *step6 = conditional_regex_replace (strlen(step5) > (LCD_col_width-1), step5, "VXI", "V"); g_free (step5); // finish @@ -943,7 +943,7 @@ void Show_Main_Menu(void) LCD_col=((LCD_entry % LCD_max_entries_per_page) / LCD_rows) * LCD_col_width + 1; if (Menu_Is_Item_Visible(LCD_entry)) { - LCD_write_padded_spaces(LCD_row,LCD_col,ctrl_str,LCD_col_width); + LCD_write_padded_spaces(LCD_row,LCD_col,ctrl_str,LCD_col_width-1); } g_free (ctrl_str); @@ -956,7 +956,7 @@ void Show_Main_Menu(void) LCD_col=((LCD_entry % LCD_max_entries_per_page) / LCD_rows) * LCD_col_width + 1; if (Menu_Is_Item_Visible(LCD_entry)) { - LCD_write_padded_spaces(LCD_row,LCD_col,"Memory menu",LCD_col_width); + LCD_write_padded_spaces(LCD_row,LCD_col,"Memory menu",LCD_col_width-1); } @@ -968,7 +968,7 @@ void Show_Main_Menu(void) LCD_col=((LCD_entry % LCD_max_entries_per_page) / LCD_rows) * LCD_col_width + 1; if (Menu_Is_Item_Visible(LCD_entry)) { - LCD_write_padded_spaces(LCD_row,LCD_col,"Setup menu",LCD_col_width); + LCD_write_padded_spaces(LCD_row,LCD_col,"Setup menu",LCD_col_width-1); } @@ -996,7 +996,7 @@ void Show_Main_Menu(void) for (i=(Main_Menu_max_entry%LCD_max_entries_per_page)+ 1; i<12; ++i) { LCD_row=i % LCD_rows; LCD_col=(i / LCD_rows) * LCD_col_width + 1; - LCD_write_padded_spaces(LCD_row,LCD_col,"",LCD_col_width); + LCD_write_padded_spaces(LCD_row,LCD_col,"",LCD_col_width-1); } g_string_free (menu_string, TRUE); -- cgit