spyder
spyder copied to clipboard
Scroll horizontally with Shift + mouse wheel
Problem Description
Would you be able to include horizontal scroll with Shift+mousewheel.
This feature is in VS Code or SAS and it helps to review either the code if the line is long or view DataFrame with lots of columns
Versions
- Spyder version: 4.2.0
- Python version: 3.8
- Qt version: 4.7.7
- PyQt version:
- Operating System name/version: Windows 10
Hey @Justinas365, thanks for reporting and sorry for the delay in coming back to you. Could you post a screenshot of what you mean by your request? Thanks!
Hello, sorry for my late reply.
So the image below contains a long line. At the bottom you can see that a horizontal scroll bar appeared. It would be really handy if I could scroll left or right when I click Shift and then spin a mouse wheel either up or down.
I think this feature would be particularly when exploring DataFrames in variable explorer. Imagine if you had 200 columns, it would be a lot more precise and faster to scroll horizontally with Shift and mouse wheel up and down instead of grabbing horizontal bar with a bouse and dragging it.
This is a feature I always use in SAS.
I understand this is not a must as there are other outstanding issues to fix so not something to worry too much.
Thank you
Currently, pressing Shift + mouse wheel up/down is already used to jump up/down code (every move of the wheel skips around 50 lines up/down in my version).
However, seeing that the mouse wheel is already used to scroll vertically up/down code, it seems more intuitive to assign Shift + mouse wheel to scroll horizontally left/right instead of still moving up/down code (even if in larger chunks), and I can't find an option to change it.
This is also how Google Colab works...having gotten used to it, I always get annoyed when I use Shift + mouse wheel in Spyder to view a long line but instead end up jumping down 50 lines.
As @Justinas365 mentioned, this is not a major issue, but it would be nice to have.
Unfortunately, Shift + mouse wheel is already used to do zoom in/out. Do you have other suggestions?
Unfortunately, Shift + mouse wheel is already used to do zoom in/out. Do you have other suggestions?
As mentioned, at least in my case, Shift + mouse wheel scrolls up/down code in larger jumps; it is Ctrl + mouse wheel that does zoom in/out.
Is it not possible to let the user change their behaviour, similar to how the key bindings can be changed in Tools > Preferences > Keyboard shortcuts?
No, it's not possible right now. We have to implement that functionality first.
Horizontal scrolling with shift + mouse wheel is the default in macOS and Linux. In this sense, the Spyder editor deviates from the unofficial norm.
For anyone who is also affected by this issue, I have noticed that there is a work-around until (maybe) this is resolved - if you move your mouse/cursor on to the horizontal scroll bar and use the mouse wheel, you will be able to scroll horizontally.
IMO still not as convenient as pressing Shift + mouse wheel (because you don't have to move your mouse and ensure it is placed directly on the horizontal scroll bar)...but it might be just enough for some.
@Justinas365, you can use alt + mousewheel
in spyder IDE, if you are stuck till now. I just saw this issue.😅😅
use Alt
+ mouse scroll
That should do the job for you.