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
+2 -2
View File
@@ -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);
}