Bug 472730

Summary: [5.2] Last preset isn't remembered when closing document
Product: [Applications] krita Reporter: tomtomtomreportingin
Component: Resource ManagementAssignee: tomtomtomreportingin
Status: RESOLVED FIXED    
Severity: normal Keywords: regression
Priority: NOR    
Version First Reported In: unspecified   
Target Milestone: ---   
Platform: Appimage   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:

Description tomtomtomreportingin 2023-07-28 07:24:25 UTC
SUMMARY
Regressive behavior introduced with https://invent.kde.org/graphics/krita/-/merge_requests/1870. The last preset for the current stylus isn't remembered when closing a document, likely because KisViewManager neglects to write to the relevant config value on document close. The last preset is remembered properly when closing Krita entirely.

STEPS TO REPRODUCE
1. Create a new document.
2. Select a new preset.
3. Close the document and create a new document.

OBSERVED RESULT
The preset from step 1 is used.

EXPECTED RESULT
The preset from step 2 should be used.

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Debian sid
KDE Plasma Version: 5.27.5
KDE Frameworks Version: 5.107.0
Qt Version: 5.15.7 (appimage)
Comment 1 Dmitry Kazakov 2023-07-28 08:02:46 UTC
Git commit babfaf5b1b74559f77907231a54ac99359c94fc4 by Dmitry Kazakov.
Committed on 28/07/2023 at 10:02.
Pushed by dkazakov into branch 'master'.

Revert "Ensure pen brush (opposed to eraser brush) is selected on new document"

This reverts commit 6d7a8da6f7b7c35f5fd0fda49c7682b0cd67ac07.

The patch causes a regression linked below.

M  +2    -7    libs/ui/KisViewManager.cpp
M  +0    -27   libs/ui/KisViewManager.h

https://invent.kde.org/graphics/krita/-/commit/babfaf5b1b74559f77907231a54ac99359c94fc4
Comment 2 Dmitry Kazakov 2023-07-28 08:05:02 UTC
Git commit 22b77302af9b7894fcb056d58a960b27b510076a by Dmitry Kazakov.
Committed on 28/07/2023 at 10:04.
Pushed by dkazakov into branch 'krita/5.2'.

Revert "Ensure pen brush (opposed to eraser brush) is selected on new document"

This reverts commit 6d7a8da6f7b7c35f5fd0fda49c7682b0cd67ac07.

The patch causes a regression linked below.

M  +2    -7    libs/ui/KisViewManager.cpp
M  +0    -27   libs/ui/KisViewManager.h

https://invent.kde.org/graphics/krita/-/commit/22b77302af9b7894fcb056d58a960b27b510076a