nicer options for defaults in localization tr() functions

git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@808 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
twanvl
2008-01-01 16:06:58 +00:00
parent f0be49c2e4
commit ed060aeb04
9 changed files with 54 additions and 72 deletions
+4 -4
View File
@@ -481,8 +481,8 @@ String InsertSymbolMenu::getCode(int id, const SymbolFont& font) const {
} else if (id == 0 && type == ITEM_CODE) {
return name;
} else if (id == 0 && type == ITEM_CUSTOM) {
String caption = tr(font,_("title ") + name, capitalize_sentence(name));
String message = tr(font,_("message ") + name, capitalize_sentence(name));
String caption = tr(font,_("title"), name, capitalize_sentence);
String message = tr(font,_("message"), name, capitalize_sentence);
return wxGetTextFromUser(message, caption);
}
return wxEmptyString;
@@ -501,7 +501,7 @@ wxMenu* InsertSymbolMenu::makeMenu(int id, SymbolFont& font) const {
}
wxMenuItem* InsertSymbolMenu::makeMenuItem(wxMenu* parent, int first_id, SymbolFont& font) const {
if (type == ITEM_SUBMENU) {
wxMenuItem* item = new wxMenuItem(parent, wxID_ANY, tr(font, _("menu item ") + name, name),
wxMenuItem* item = new wxMenuItem(parent, wxID_ANY, tr(font, _("menu item"), name, capitalize),
wxEmptyString, wxITEM_NORMAL,
makeMenu(first_id, font));
item->SetBitmap(wxNullBitmap);
@@ -510,7 +510,7 @@ wxMenuItem* InsertSymbolMenu::makeMenuItem(wxMenu* parent, int first_id, SymbolF
wxMenuItem* item = new wxMenuItem(parent, wxID_SEPARATOR);
return item;
} else {
wxMenuItem* item = new wxMenuItem(parent, first_id, tr(font, _("menu item ") + name, name));
wxMenuItem* item = new wxMenuItem(parent, first_id, tr(font, _("menu item"), name, capitalize));
// Generate bitmap for use on this item
SymbolInFont* symbol = nullptr;
if (type == ITEM_CUSTOM) {