Skip to content

Select second handle with right click#11

Open
sayofan wants to merge 4 commits intoharshvinay752:mainfrom
sayofan:select-lower-handle
Open

Select second handle with right click#11
sayofan wants to merge 4 commits intoharshvinay752:mainfrom
sayofan:select-lower-handle

Conversation

@sayofan
Copy link

@sayofan sayofan commented Jan 8, 2026

Hi,

First of all, thanks for this widget. I plan to use it to select a range of bytes from a file.
I ran into an issue were with two sliders and cross_each_other=False, I could not select and move the right handle.
If both handles are moved to the zero/left-most position, that means that the slider handles can not be moved anymore.

I introduced functionality to select the right-most handle with right click.

If enable_right_click_movement=True is given in init, right-click movement is set on.
Only implemented it for RangeSliderH, not RangeSliderV.

This may not be the best resolution for the issue I mentioned, but required less changes than other stuff I could think about.
Also, I left some comments in the code you may want to strip.
Other possibilities would be:

  • When clicking on the track next to a handlebar, move handle in direction of the click on track;
  • if bars have equal position on mousedown, select the handle based on the first movement
  • if bars are both at 0, select second/right handle

Cheers!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant