mirror of
https://github.com/amyinspace/MagicSetEditor2.git
synced 2026-06-12 05:36:59 -04:00
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:
@@ -204,7 +204,7 @@ void CardListBase::rebuild() {
|
||||
else if (f.second->card_list_align & ALIGN_CENTER) align = wxLIST_FORMAT_CENTRE;
|
||||
else align = wxLIST_FORMAT_LEFT;
|
||||
InsertColumn((long)column_fields.size(),
|
||||
tr(*set->game, f.second->card_list_name, capitalize(f.second->card_list_name)),
|
||||
tr(*set->game, f.second->card_list_name, capitalize),
|
||||
align, cs.width);
|
||||
column_fields.push_back(f.second);
|
||||
}
|
||||
|
||||
@@ -76,7 +76,7 @@ void CardListColumnSelectDialog::initList() {
|
||||
// Init items
|
||||
Color window_color = wxSystemSettings::GetColour(wxSYS_COLOUR_WINDOW);
|
||||
FOR_EACH(c, columns) {
|
||||
list->Append(tr(*game, c.field->card_list_name, capitalize(c.field->card_list_name)));
|
||||
list->Append(tr(*game, c.field->card_list_name, capitalize));
|
||||
// check
|
||||
int i = list->GetCount() - 1;
|
||||
list->Check(i, c.settings.visible);
|
||||
@@ -89,7 +89,7 @@ void CardListColumnSelectDialog::initList() {
|
||||
|
||||
void CardListColumnSelectDialog::refreshItem(int i) {
|
||||
list->Check (i, columns[i].settings.visible);
|
||||
list->SetString(i, tr(*game, columns[i].field->card_list_name, capitalize(columns[i].field->card_list_name)) );
|
||||
list->SetString(i, tr(*game, columns[i].field->card_list_name, capitalize) );
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------------- : Events
|
||||
|
||||
@@ -44,7 +44,7 @@ void NativeLookEditor::drawViewer(RotatedDC& dc, ValueViewer& v) {
|
||||
// draw label
|
||||
dc.SetFont(*wxNORMAL_FONT);
|
||||
// TODO : tr using stylesheet or using game?
|
||||
dc.DrawText(tr(*set->game, s.fieldP->name, capitalize_sentence(s.fieldP->name)),
|
||||
dc.DrawText(tr(*set->game, s.fieldP->name, capitalize_sentence),
|
||||
RealPoint(margin_left - s.left, 1));
|
||||
// draw 3D border
|
||||
draw_control_border(this, dc.getDC(), dc.trRectStraight(s.getInternalRect().grow(1)));
|
||||
@@ -70,7 +70,7 @@ void NativeLookEditor::resizeViewers() {
|
||||
// width of the label string
|
||||
int w;
|
||||
Style& s = *v->getStyle();
|
||||
String text = tr(*set->game, s.fieldP->name, capitalize_sentence(s.fieldP->name));
|
||||
String text = tr(*set->game, s.fieldP->name, capitalize_sentence);
|
||||
dc.GetTextExtent(text,&w,nullptr);
|
||||
label_width = max(label_width, w + label_margin);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user