Fix for translation of UTF strings

In italian language the accented u was not displayed correctly in equalizer panel
This commit is contained in:
ffsup2
2011-06-07 22:22:36 +02:00
parent fbb9cff8ee
commit e4a550dbd3
2 changed files with 20 additions and 14 deletions

View File

@@ -54,13 +54,16 @@ DirPyrEqualizer::DirPyrEqualizer () : Gtk::VBox(), FoldableToolPanel(this) {
for(int i = 0; i < 4; i++) for(int i = 0; i < 4; i++)
{ {
std::stringstream ss; Glib::ustring ss;
ss << i; switch( i ){
if(i == 0) case 0:
ss << " (" << M("TP_DIRPYREQUALIZER_LUMAFINEST") << ")"; ss =Glib::ustring::compose( "%1 (%2)",i, M("TP_DIRPYREQUALIZER_LUMAFINEST"));break;
if(i == 3) case 3:
ss << " (" << M("TP_DIRPYREQUALIZER_LUMACOARSEST") << ")"; ss =Glib::ustring::compose( "%1 (%2)",i, M("TP_DIRPYREQUALIZER_LUMACOARSEST"));break;
multiplier[i] = Gtk::manage ( new Adjuster (ss.str(), 0, 4, 0.01, 1.0) ); default:
ss =Glib::ustring::compose( "%1",i);
}
multiplier[i] = Gtk::manage ( new Adjuster (ss, 0, 4, 0.01, 1.0) );
multiplier[i]->setAdjusterListener(this); multiplier[i]->setAdjusterListener(this);
pack_start(*multiplier[i]); pack_start(*multiplier[i]);
} }

View File

@@ -54,14 +54,17 @@ Equalizer::Equalizer () : Gtk::VBox(), FoldableToolPanel(this) {
for(int i = 0; i < 8; i++) for(int i = 0; i < 8; i++)
{ {
std::stringstream ss; Glib::ustring ss;
ss << i; switch( i ){
if(i == 0) case 0:
ss << " (" << M("TP_EQUALIZER_FINEST") << ")"; ss =Glib::ustring::compose( "%1 (%2)",i, M("TP_EQUALIZER_FINEST"));break;
if(i == 7) case 7:
ss << " (" << M("TP_EQUALIZER_LARGEST") << ")"; ss =Glib::ustring::compose( "%1 (%2)",i, M("TP_EQUALIZER_LARGEST"));break;
default:
ss =Glib::ustring::compose( "%1",i);
}
correction[i] = Gtk::manage ( new Adjuster (ss.str(), -100, 100, 1, 0) ); correction[i] = Gtk::manage ( new Adjuster (ss, -100, 100, 1, 0) );
correction[i]->setAdjusterListener(this); correction[i]->setAdjusterListener(this);
pack_start(*correction[i]); pack_start(*correction[i]);
} }