How to create .ts file for QML in Visual Studio with Qt PlugIn
-
I developed my project in Visual Studio with Qt Plugin, the user interface is implemented with QML, all QML files are added into .qrc file and loaded with resource system.
for example: MyUI.qrc
<!DOCTYPE RCC><RCC version="1.0">
<qresource>
<file>home.qml</file>
<file>import.qml</file>
</qresource>
</RCC>then in main.cpp, I tried to load the .qrc file with below code:
Q_INIT_RESOURCE(MyUI);Everything works well, but when I tried to create .ts file with menu item "Qt->Create new Translation File", the text marked with "qstr" can not be extracted from QML file.
What is the possible solution for this issue? -
Hi
I knwo this thread is very old but just for help other having same issue here a possible workaround:
http://falsinsoft.blogspot.com/2016/10/qt-on-visual-studio-and-qml-translation.html