Open alexcastano opened 7 years ago
Yeah that's a pretty cool idea! I probably won't get to this any time soon, but if anyone wants to send a PR that would be awesome! :D
Oh cool! I don't know if this existed last year, but it seems really easy now! You just need to add the C-
prefix to do a ctrl modifier, and S-
prefix to do a shift modifier.
So to do what you asked:
bind-key -T copy-mode C-WheelUpPane send-keys -X -N 30 scroll-up
bind-key -T copy-mode-vi C-WheelUpPane send-keys -X -N 30 scroll-up
bind-key -T copy-mode C-WheelDownPane send-keys -X -N 30 scroll-down
bind-key -T copy-mode-vi C-WheelDownPane send-keys -X -N 30 scroll-down
# This is the ugly one built programmatically from the script. Just have to copy/paste it unfortunately:
bind-key -T root C-WheelUpPane if-shell -F -t = "#{mouse_any_flag}" "send-keys -M" " if -Ft= '#{alternate_on}' \"send-keys -t= up ; \" \" if -Ft= '#{pane_in_mode}' 'send-keys -M ; ' 'copy-mode -e ; send-keys -M ; ' \" "
Cool idea! :)
Mhh couldn't a distinct factor for each modifier key be used in get_repeated_scroll_cmd()
, i.e. CTRL to speed up, SHIFT to slow down...?
Yeah totally. Do we think that's a thing people would want to use?
We could add it to the plugin if so. Should we just add a boolean option to enable/disable the speed-modifiers? Or add an option to specify the mapping for fast/slow scroll?
I'm interested in others' input here on what would be useful.
I think a cool feature could be if the Control key (or other modifier key) is pressed, the number of lines scrolled are different. For example, if control is pressed 30 lines are scrolled. This can be done with a multiplier (x10) or just another scroll speed variable.
Thank you for your time :)