String in titlebar becomes rubbisch after translation (font problem?)
we have a GUI in QT4.5.0 with internationalisation:
@ MainWnd->setWindowTitle(QApplication::translate("MainWnd", "testtest", 0, QApplication::UnicodeUTF8));@
For English, the title "testtest" shows nicely.
But when switching to Hebrew, we get rubbisch (on our English Windows PC) although the rest of the GUI (Arial font) translates fine (see img).
On a Hebrew Windows PC, the title shows nicely too.
Q1: are we missing a (Hebrew) font on our English Windows machine?
Q2: how to find out which is the default font for the title bar?
Q3: is there a way to tell QT or Windows to set Arial font for the title bar?
Many thx, br,
-You can call "font()":http://developer.qt.nokia.com/doc/qt-4.8/qapplication.html#font and should be able to find out the default font used. With "setFont ":http://developer.qt.nokia.com/doc/qt-4.8/qapplication.html#setFont you may change the font.-
[Edit] Did not work!
koahnig: I doubt that this will effect the font used by the window decoration.
Tobias: indeed, it doesn't seem to work:
QFont f = MainWnd->font(); // font is "MS Shell Dlg"
f.setFamily( "Arial" );
f = MainWnd->font(); // font is now "Arial" but still rubbisch in the title bar
Guess this is not something Qt can fix?
[EDIT: code formatting, please wrap in @-tags, Volker]
The window titlebar uses the font that is set in windows settings.
If this font does not support hebrew (like most english windows do not by default) you see rubbish.