Bug 493456 - Toolbar bug: The "Zoom" action does not reflect the currently active document
Summary: Toolbar bug: The "Zoom" action does not reflect the currently active document
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: Usability (show other bugs)
Version: nightly build (please specify the git hash!)
Platform: Microsoft Windows Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: Krita Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2024-09-21 21:36 UTC by AppTest
Modified: 2024-11-07 18:25 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description AppTest 2024-09-21 21:36:38 UTC
SUMMARY
The "Zoom" action on the toolbar only works for one open document because it refuses to reflect the zoom percentage of whatever document is active, if more than one document is open.

STEPS TO REPRODUCE
1. Settings, Configure Toolbars, add the "Zoom" action to your toolbar
2. Open two documents, and zoom in/out on each of them so they each have different zoom percentages.

OBSERVED RESULT
Switch between the open documents, and you will see that the Zoom on the toolbar does not change to reflect the currently active document. It can only control the zoom of one and only one document.

EXPECTED RESULT
Contrast the above with the zoom scrollbar on the Status Bar, which always changes to reflect the currently active document. The zoom shortcut on the toolbar needs to behave exactly like the one on the Status Bar.

SOFTWARE/OS VERSIONS
Windows 11
Krita 5.3.0-prealpha (git 9deea14 / 9deea14c )
Comment 1 Dmitry Kazakov 2024-11-07 18:24:46 UTC
Git commit 7b609410a5d7273249f9e0a6e949f3d4628c7e5f by Dmitry Kazakov.
Committed on 07/11/2024 at 18:24.
Pushed by dkazakov into branch 'master'.

Disable possibility of adding "Zoom Action" widget to the toolbars

Our current design of XMLGui and of the zoom action doesn't support having multiple
per-document actions. We have only one zoom action, which is added to the status bar.
And this action is switched manually on the document switch. We cannot just add this
action to the toolbar. It needs a lot of fixes in how KXMLGui synchronizes with
KActionCollection.

Personally, I hope this KXMLGui thing will somehow go away with the QML rewrite...

M  +0    -2    libs/widgets/KoZoomController.cpp

https://invent.kde.org/graphics/krita/-/commit/7b609410a5d7273249f9e0a6e949f3d4628c7e5f
Comment 2 Dmitry Kazakov 2024-11-07 18:25:56 UTC
Hi, AppTest!

I just disable the possibility of adding the Zoom Action to the toolbars. It is really hard to make our current design to support two zoom actions in one app, I'm afraid :(