I have spent the last 3 weeks on a complete rewrite of the Krita system that is responsible for canvas zooming, rotation, mirroring and panning. This new version of the system should allow us to fix some FPS issues (later, in Qt6 version) and make the port to QML easier.
Since this rewrite changes a lot of stuff (and by “a lot” I mean “reaaallly a lot”), I would need your help with testing if the canvas still works correctly with your workflow. I had to also touch implementation of quite a few of shortcuts, so I could accidentally change their behavior. Please check the ones you use normally, do they still work as expected?
The formal list of the things that could be affected:
Canvas panning, zooming, rotation and mirroring should work as before
Scrollbars around the canvas should work as usual
Rulers should have consistent state, whatever pan/zoom/rotate/mirror settings are
Rulers should track pointers when requested
Infinity manager should work as expected (when you drag the canvas to one side, a special button should appear to automatically extend the canvas)
Zoom widgets at the bottom-right corner should behave correctly. If you set “Fit Page”, then the box should show “Fit Page” even when you resize the Krita window (there was a bug with that before this patch)
Use print size button should work as expected in all the zoom modes (the “monitor” button at the very bottom-right corner of the window)
The shortcuts like Ctrl+= and Ctrl± should behave correctly and switch between the predefined zooms in the zoom widget
The canvas actions like Ctrl+Space+Drag should work as expected
Touch gestures for pan and zoom should work as before
Migrating Krita from one screen to another should adjust the zoom correctly (especially in “use print size” mode)
Migrating between screens with different HiDPI scaling factors should work correctly
Resizing Krita window should keep zoom modes intact and zoom to page if needed
Switching canvas only mode should keep zoom modes intact and zoom to page if needed
I have checked this points locally on my systems, but, perhaps, I missed something? Could you please help me and check the packages? If you confirm there are no regressions, I will merge the patch into Krita 5.3
Tested with my local Krita 6 build on macOS. I didn’t test anything with multi-screen setup. Otherwise, everything seems mostly fine as far as I can tell.
Issue, may or may not be related to this patch:
Mirror with Fit Page jumps by around 1px. Without this patch, sometimes the canvas stays in place, sometimes it jumps by 1px or more. So I’m not sure if it’s a regression. It might also be expected if the canvas viewport width is odd…
Qt6 issues (not related to this patch):
Resizing dockers in Fit Page mode causes the canvas to flicker in and out of existence, switching to Canvas-Only causes the canvas to jump briefly. It seems to be an issue with some recent Qt6 patches, happens on Krita-6-prealpha-10ea89b nightly from June 12, but not on 862e152 from May 15).
Cmd-/Cmd+ zoom twice, because Cmd-/Cmd+ are mapped in Keyboard Shortcuts and -/= are also mapped in Canvas Input. Happens on the Krita-6-prealpha-862e152 nightly, might be a general Qt6 issue (on Qt5, it zooms once).
Other notes:
The Zoom widget keeps “Fit Page” unlike before. But a side effect of the bug was that you could see what the Fit Page zoom level actually was. Can we do something like “Fit Page (140%)”?
Ruler position updates seem choppy, but apparently it’s normal.
OK - Canvas panning, zooming, rotation and mirroring should work as before
OK - Scrollbars around the canvas should work as usual
OK - Rulers should have consistent state, whatever pan/zoom/rotate/mirror settings are
OK - Rulers should track pointers when requested
OK but UNDO does not update view emediately, need to e.g move the canvas to trigger the update | Infinity manager should work as expected (when you drag the canvas to one side, a special button should appear to automatically extend the canvas)
OK - Zoom widgets at the bottom-right corner should behave correctly. If you set “Fit Page”, then the box should show “Fit Page” even when you resize the Krita window (there was a bug with that before this patch)
OK - Use print size button should work as expected in all the zoom modes (the “monitor” button at the very bottom-right corner of the window)
OK but tested with custom shortcuts (e.g. ctrl+num++ = rotate) | The shortcuts like Ctrl+= and Ctrl± should behave correctly and switch between the predefined zooms in the zoom widget
NOT TESTET due to custom shortcuts | The canvas actions like Ctrl+Space+Drag should work as expected
NOT TESTET | Touch gestures for pan and zoom should work as before
NOT TESTET | Migrating Krita from one screen to another should adjust the zoom correctly (especially in “use print size” mode)
NOT TESTET | Migrating between screens with different HiDPI scaling factors should work correctly
OK but what means "zoom to page if needed? It just keeps the chosen zoom level. | Resizing Krita window should keep zoom modes intact and zoom to page if needed
OK but what means "zoom to page if needed? It just keeps the chosen zoom level. | Switching canvas only mode should keep zoom modes intact and zoom to page if needed
ON my brief testing canvas canvas-related activities like panning, zooming, rotation and mirrors works as expected on windows. More test with Linux will be conducted on Sunday
The Zoom widget keeps “Fit Page” unlike before. But a side effect of the bug was that you could see what the Fit Page zoom level actually was. Can we do something like “Fit Page (140%)”?
Which is, the “correct” behavior of the widget makes it a little bit less user-friendly
Thanks for detailed descriptions of the issues. I have checked them:
Mirror with Fit Page jumps by around 1px.
I’ve fixed in master after the merge
Resizing dockers in Fit Page mode causes the canvas to flicker in and out of existence,
Might be related to the Qt patches, but I cannot see that on the Linux or Windows builds. Some video might be helpful.
Cmd-/Cmd+ zoom twice, because Cmd-/Cmd+ are mapped in Keyboard Shortcuts and -/= are also mapped in Canvas Input. Happens on the Krita-6-prealpha-862e152 nightly, might be a general Qt6 issue (on Qt5, it zooms once).
Cannot reproduce on Linux, must be some MacOS-specific issue
The Zoom widget keeps “Fit Page” unlike before. But a side effect of the bug was that you could see what the Fit Page zoom level actually was. Can we do something like “Fit Page (140%)”?
Changed in the proposed way
Ruler position updates seem choppy, but apparently it’s normal.
That is a “fix” in master that made them choppy to not affect the painting