Bug 474667 - Workspace inconsistent before and after activating Canvas Only mode
Summary: Workspace inconsistent before and after activating Canvas Only mode
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: Dockers (other bugs)
Version First Reported In: 5.2.0-rc1
Platform: Neon Linux
: NOR minor
Target Milestone: ---
Assignee: Dmitry Kazakov
URL:
Keywords: regression
Depends on:
Blocks:
 
Reported: 2023-09-18 21:12 UTC by askkegra
Modified: 2023-09-22 10:12 UTC (History)
1 user (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description askkegra 2023-09-18 21:12:33 UTC
This is a bit of a 2-in-1 bug report.
If you have it set in the configuration so that you don't hide dockers when in Canvas Only mode you can run into some issues when entering and exiting the mode. 

First, any changes made to the layout of the workspace while in Canvas Only mode will be undone once you go out of Canvas Only mode. While exact sizes naturally can't be preserved when the window size changes I would expect placement of dockers to be respected as well as the proportions of the dockers.

Second, repeatedly entering and exiting Canvas Only mode will cause dockers to resize slightly each time. It's not entirely universal but here's one way to replicate the bug:

1. Configure Krita so that dockers are still visible in Canvas Only mode.
2. Change the workspace to VFX_Paint and pay attention to the amount of empty space at the bottom of the LUT Management docker in the right hand column.
3. Enter and exit Canvas Only mode 20 times.
4. The dockers on the right side will have resized to fill up that empty space.

I've noticed that the Overview docker and Advanced Color Selector especially interact poorly this way when placed in the same column.
Comment 1 Dmitry Kazakov 2023-09-22 10:12:52 UTC
Git commit 81df5d6f23a276bb01be7f757ca394b945ed0b9d by Dmitry Kazakov.
Committed on 22/09/2023 at 12:12.
Pushed by dkazakov into branch 'master'.

[FEATURE] Save dockers state separately in canvas-only mode

Now there are two different saved states for normal and canvas-only
mode. The saved canvas-only state is reset in the following cases:

1) The user loads any workspace resource (in this case state becomes
   invalid)

2) The user changes any canvas-only option in the preferences dialog,
   e.g. whether to show the menu or now (since it is also saved in the
   state)

M  +2    -0    libs/ui/KisMainWindow.cpp
M  +57   -21   libs/ui/KisViewManager.cpp
M  +2    -0    libs/ui/KisViewManager.h

https://invent.kde.org/graphics/krita/-/commit/81df5d6f23a276bb01be7f757ca394b945ed0b9d