ComboBox seems to be very broken on Linux, anyone else have the same issue?
-
I'm finding ComboBox to be very glitchy on Linux using Qt 6.6.3 (also tested 6.6.2 and 6.7.0). I've uploaded a video showing the issue here (although it didn't capture my mouse pointer):
Essentially, I click the ComboBox to get the pop-up and that works fine, but if I click to select an item, it very rarely actually selects it. The first item stays selected. In the video clip it didn't work at all, but in other tests I find that it occasionally selects the item, but usually not.
On Windows the same code is working fine. Could somebody on Linux let me know if they see the same issue? Source code is here:
https://github.com/chrismocock-wavestore/ComboBoxTest
I'm running Fedora 39 with the default Gnome desktop and XOrg. Might try Wayland to see if it makes a difference.
-
Wayland works fine - seems to be an issue on XOrg only. Would still be useful to know if anyone else has the same issue.
-
I've discovered more about this and thought I'd share in case others stumble across it.
After switching to Wayland because of the ComboBox problem, I then hit a problem within Wayland where the TextInput component would not work (you couldn't get focus and type into it).
After trying to make a simple test QML app to demonstrate the problem, it worked fine.
Both problems (ComboBox on XOrg and TextInput on Wayland) appear to be related to QQuickView. I was doing something like this:
auto* quick_view = new QQuickView; quick_view->setSource(QUrl(QStringLiteral("qrc:/ComboBoxTest/MainWindow.qml"))); QWidget *container = QWidget::createWindowContainer(quick_view); layout->addWidget(container);
Instead of that, I'm now using a QQuickWidget, i.e. something like:
auto* quick_widget = new QQuickWidget; quick_widget->setSource(QUrl(QStringLiteral("qrc:/ComboBoxTest/MainWindow.qml"))); quick_widget->show(); layout->addWidget(quick_widget);
Now all is working well on both Wayland and XOrg.
-