Change the language of "QML Map Element"
-
wrote on 28 Oct 2011, 02:24 last edited by
I'm a Chinese.
I found that if I use an official offline OVI Map on my Nokia device.
The language of the map is Chinese.
But the Language is allways in English while I develop a soft base on QtQuick QML Map Element.@
Map {
id: map
opacity: 1
anchors.fill: parent
size.width: parent.width
size.height: parent.height
zoomLevel: 10center: Coordinate {latitude: 39.90735; longitude: 116.39125} connectivityMode: Map.OnlineMode mapType: Map.StreetMap plugin: Plugin {name: "nokia"} }
@
Is there any way to change the map language?
BTW, Is there any other value of the Plugin name? -
wrote on 28 Oct 2011, 06:51 last edited by
njduck Nin Hao;)
I had the similar issue with Russian - so Russian turns on when your device's locale is set to Russian. Could you try please your code ensuring your device is set to China locale?
-
wrote on 28 Oct 2011, 09:05 last edited by
[quote author="cmer4" date="1319784676"]njduck Nin Hao;) I had the similar issue with Russian - so Russian turns on when your device's locale is set to Russian. Could you try please your code ensuring your device is set to China locale?[/quote]
3ks cmer4.
I'm not familiar with Nokia device.
Could u please tell me how to set the locale?
I have one Nokia C6-01 and one Nokia 5800w XpressMusic. -
wrote on 3 Nov 2011, 03:25 last edited by
i have set it ,but it always english.
@
#include <QtGui/QApplication>
#include "mainwindow.h"
#include <QLocale>
#include <QSplashScreen>int main(int argc, char *argv[])
{
QApplication a(argc, argv);
QSplashScreen *splash = new QSplashScreen;
splash->setPixmap(QPixmap(":/splash.png"));
splash->show();
splash->showMessage("Loaded modules");
// QLocale lo(QLocale::China, QLocale::Chinese);
QLocale::setDefault(QLocale(QLocale::Chinese, QLocale::China));
// QLocale::setDefault(&lo);
qDebug() << "china";
qDebug() << QLocale::system().language();
MainWindow w;
#if defined(Q_OS_SYMBIAN) || defined(Q_OS_WINCE_WM) || defined(Q_WS_MAEMO_5) || defined(Q_WS_MAEMO_6)
// w.setControlsVisible(false);
w.showMaximized();
#else
w.show();
qDebug() << "splash";
splash->showMessage("Established connections");
splash->finish(&w);
#endif
return a.exec();
}
@[EDIT: code formatting, please wrap in @-tags, Volker]
1/4