Closed sfhbarnett closed 2 years ago
thanks!
A fix is to change ev.pos() to ev.position() on line 149 in _generic_range_slider.py. I'd do this and make a pull request but this breaks backwards compatibility with PyQt5 and I don't know how to maintain that (or if there's a way).
that would be great thanks!
you can make a small compatibility function ... something like:
def _event_position(event):
return event.pos() if hasattr(event, 'pos') else event.position()
Great thanks! I learned something new today
close?
Describe the bug Dragging the bar (as opposed to the handles at the end) causes a crash with PyQt6 (and not PyQt5) with the following message:
Seemingly this is the result of a change in the Qt API https://stackoverflow.com/questions/67496362/qmouseevent-object-has-no-attribute-pos
A fix is to change ev.pos() to ev.position() on line 149 in _generic_range_slider.py. I'd do this and make a pull request but this breaks backwards compatibility with PyQt5 and I don't know how to maintain that (or if there's a way).
To Reproduce Run the labeled.py example script with PyQt6 and click and drag the bar of a slider
Expected behavior Slider bar drags
Screenshots Screenshots and GIFS are much appreciated when reporting visual bugs.
Desktop (please complete the following information):