Skip to content
This repository has been archived by the owner. It is now read-only.

How to deal with QML-based Qt6 #10

Open
tio-trom opened this issue Sep 29, 2023 · 3 comments
Open

How to deal with QML-based Qt6 #10

tio-trom opened this issue Sep 29, 2023 · 3 comments

Comments

@tio-trom
Copy link

From my tests one needs to add the export QT_QUICK_CONTROLS_STYLE=gtk2 variable in order to theme the QML-based QT apps. Works for QT5 but for QT6 it will make the apps fail to launch the GUI with errors like:

[Warning] (Thu Sep 28 04:14:09 2023): QQmlApplicationEngine failed to load component
[Warning] (Thu Sep 28 04:14:09 2023): qrc:/gpt4all/main.qml: module "gtk2" is not installed
[Warning] (Thu Sep 28 04:14:09 2023): QIODevice::read (QNetworkReplyHttpImpl): device not open
[Warning] (Thu Sep 28 04:14:09 2023): ERROR: Couldn't parse:  "" "illegal value"

What's the solution?

Thanks

@trialuser02
Copy link
Owner

Unfortunately, QStyle is not supported by QML. Try to use QQC2-Desktop-Style from KDE: https://api.kde.org/frameworks/qqc2-desktop-style/html/index.html

export QT_QUICK_CONTROLS_STYLE=org.kde.desktop

@tio-trom
Copy link
Author

That didn't seem to make any difference.... I added export QT_QUICK_CONTROLS_STYLE=org.kde.desktop but it does not change anything. So basically qt6gtk2 cannot theme the QML-based Qt6 nor is there an easy way to do it?

@trialuser02
Copy link
Owner

Unfortunately, I do not know about other solution.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants