You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If a translation file corresponds to a Qml document, show a preview
of the qml document that contains the translations.
Knwon limitations:
- arguments in texts: "Hello %1"
linguist can only see the runtime version of the string
and fails to match it with an existing message in TS file.
- items in comboboxes:
This needs a bit of more implementation (possibly next iterations),
since combobox stores items in the "model" property,
rather than "text". Also if implemented, it will not be
available to .qml files, but only provides
support for .ui.qml files. Since normal Qml files are opened
in a frozen state (no interactions with the form, hence
comboboxes cannot expand), to prevent executing operations
of the Qml document whose logic is unknown to linguist.
- Qml item "ApplicationWindow" not supported:
It needs a whole QQmlApplicationEngine. A normal QQuickWidget
cannot contain it.
- Missing Qml plugins:
if some required Qml plugins are missing, the document cannot
be displayed. This patch contains some changes in the cmake file
to add the Qml plugins in QtDeclarative as dependencies, so most
used plugins are supported.
If due to the limitations above (or other limitations), a document
cannot be viewed reasonably, the user has always the choice to fall
back to the source code by toggling views->Preview Qml (then it
will be same as before).
Additionally, if there are some
errors in showing the Qml document (e.g., due to missing Qml
plugins), the editor automatically falls back to the source code.
Fixes: QTBUG-71161
Change-Id: I3dc4ac741b8be31ef96fd5bd9f5a13e1251a8ce1
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
0 commit comments