diff options
Diffstat (limited to 'riscos/menus.c')
-rw-r--r-- | riscos/menus.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/riscos/menus.c b/riscos/menus.c index 44ad4a6db..8b6163f39 100644 --- a/riscos/menus.c +++ b/riscos/menus.c @@ -2249,6 +2249,7 @@ void gui_create_form_select_menu(struct browser_window *bw, struct form_control *control) { unsigned int i = 0, j; + char *text_convert; struct form_option *option; wimp_pointer pointer; os_error *error; @@ -2303,6 +2304,12 @@ void gui_create_form_select_menu(struct browser_window *bw, /* \todo can cnv_str_local_enc() fail? */ gui_form_select_menu->entries[i].data.indirected_text.text = cnv_str_local_enc(option->text); + /* convert spaces to hard spaces to stop things like 'Go Home' being treated + as if 'Home' is a keyboard shortcut and right aligned in the menu. */ + text_convert = gui_form_select_menu->entries[i].data.indirected_text.text - 1; + while (*++text_convert != '\0') + if (*text_convert == 0x20) + *text_convert = 0xa0; gui_form_select_menu->entries[i].data.indirected_text. validation = "\0"; gui_form_select_menu->entries[i].data.indirected_text.size = |