From: Peter Åstrand Date: Mon, 29 Aug 2011 13:14:51 +0000 (+0000) Subject: Avoid translation strings with leading and/or trailing whitespace. Our X-Git-Tag: v1.1.90~147 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=b7c5524223d1f93bedc7256cb3782cae9a911b2e;p=tigervnc.git Avoid translation strings with leading and/or trailing whitespace. Our experience is that translators very often fails to notice them and forgets to include the whitespace in the translated string. git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@4661 3789f03b-4d11-0410-bbf8-ca57d06f2519 --- diff --git a/vncviewer/vncviewer.cxx b/vncviewer/vncviewer.cxx index 6fea1992..1efe1d7d 100644 --- a/vncviewer/vncviewer.cxx +++ b/vncviewer/vncviewer.cxx @@ -140,13 +140,21 @@ static void init_fltk() fl_close = _("Close"); #ifdef __APPLE__ - Fl_Mac_App_Menu::about = _("About "); + /* Needs trailing space */ + static char fltk_about[16]; + snprintf(fltk_about, sizeof(fltk_about), "%s ", _("About")); + Fl_Mac_App_Menu::about = fltk_about; + static char fltk_hide[16]; + snprintf(fltk_hide, sizeof(fltk_hide), "%s ", _("Hide")); + Fl_Mac_App_Menu::hide = fltk_hide; + static char fltk_quit[16]; + snprintf(fltk_quit, sizeof(fltk_quit), "%s ", _("Quit")); + Fl_Mac_App_Menu::quit = fltk_quit; + Fl_Mac_App_Menu::print = ""; // Don't want the print item Fl_Mac_App_Menu::services = _("Services"); - Fl_Mac_App_Menu::hide = _("Hide "); Fl_Mac_App_Menu::hide_others = _("Hide Others"); Fl_Mac_App_Menu::show = _("Show All"); - Fl_Mac_App_Menu::quit = _("Quit "); fl_mac_set_about(about_callback, NULL); #endif