-
Bug
-
Resolution: Fixed
-
P2: Important
-
5.14.2
-
None
-
i3-wm
-
-
574692e5a (dev), eb31663d0 (6.7), 3011891fb (6.6), 37df54978 (tqtc/lts-6.5)
By default, a slider on Linux/X11 with the default QFusionStyle looks like the following:
Adding ticks, it will look like this:
We can already observe two things:
- the top of the cursor is truncated
- its form doesn't change for a pointed cursor on the tick like on MacOS for example
Also, there is a weird issue related to focus, which can be observed with the attached video. In that video, I'm just moving the cursor around (never clicking), and we can see the ticks randomly changing colors for unknown reasons. It looks kind of related to focus, but it's inconsistent and unpredictable.
Note on the video: it's encoded on yuv444p to preserve colors, so the video might not be playable with some players (mpv or vlc will be fine).
Here is a 20-line sample to reproduce the issue:
import sys from PySide2 import QtCore, QtWidgets class _Window(QtWidgets.QWidget): def __init__(self): super().__init__() slider = QtWidgets.QSlider(QtCore.Qt.Horizontal) slider.setTickPosition(QtWidgets.QSlider.TicksBelow) slider.setValue(50) layout = QtWidgets.QVBoxLayout(self) layout.addWidget(slider) if __name__ == '__main__': app = QtWidgets.QApplication(sys.argv) w = _Window() w.show() sys.exit(app.exec_())
Side note: reproducing the UI with qt-creator leads to the same glitch, but the smallest height resize available seems to stitch it to a viable height.
Fourth and last related issue reproducible with this slider is the different behavior while clicking on the seekbar: this seems related to the SH_Slider_AbsoluteSetButtons style, but having it inconsistent between platforms is a bummer. On MacOS typically, the slider will jump right to where it's clicked, while on Linux it somehow jumps in the direction of the cursor.