rnote icon indicating copy to clipboard operation
rnote copied to clipboard

Pan and zoom on a drawing tablet

Open mbund opened this issue 2 years ago • 2 comments

Is your feature request related to a problem? Please describe. When drawing with a detached tablet and stylus (no touchscreen), zooming and panning is incredibly difficult. Currently only panning while pressing middle mouse button mapped from a button on the pen will work. Zooming does not work at all as far as I can tell, or at least requires a weird hack with mapping the scroll wheel + ctrl to the stylus.

Describe the solution you'd like For pen input, pressing ctrl then starting to drag with the pen should pan the way middle mouse button does. Then, ctrl + shift and starting to drag with the pen should smoothly zoom in/out on the starting position of the cursor. This is similar to how Krita handles drawing tablets, with ctrl + space and drag for smooth zoom, for example.

mbund avatar May 24 '22 04:05 mbund

I would recommend checking how Krita does it since it has imo the best default behaviour from all the drawing apps I used.

I own 2 wacom styluses and they both have two buttons on the side where the index would rest. One of them opens a circular menu to select a brush and the other is used for dragging, zooming and rotating. There are also extra buttons on some tablets but I personally think they are less of a priority. Implementing a behaviour similar to Krita would greatly improve the UX.

snakedye avatar Jun 02 '22 16:06 snakedye

I think that if possible, having the ability to rotate the canvas using the touchscreen might be a good idea, now that 2in1 laptops get more popular.

My dell stylus is recognized as a stylus, but a laptop does not necessarily have hardware index buttons, and when folded 360°, keyboard combinations might not work (keyboard unreachable and disabled)

comcloudway avatar Aug 29 '22 18:08 comcloudway

I added alt + pointer drag for panning, and alt+shift + pointer drag for zooming (like ctrl + space in krita).

The reason why I didn't use ctrl is because it is already used in other ways like constraining shape dimensions.

flxzt avatar Dec 18 '22 13:12 flxzt

Regarding rotating the canvas, that would be a separate feature request

flxzt avatar Dec 18 '22 13:12 flxzt