Bug 476141 - Brush slider is not displaying the actual brush size only on mypaint brushes
Summary: Brush slider is not displaying the actual brush size only on mypaint brushes
Status: RESOLVED FIXED
Alias: None
Product: krita
Classification: Applications
Component: * Unknown (show other bugs)
Version: 5.2.0
Platform: macOS (DMG) macOS
: NOR normal
Target Milestone: ---
Assignee: Krita Bugs
URL:
Keywords: regression
: 475930 476593 477921 (view as bug list)
Depends on:
Blocks:
 
Reported: 2023-10-27 08:35 UTC by johnschiefer25
Modified: 2023-12-02 16:27 UTC (History)
4 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments
the size is 0.01 pixels while the brush is clearly much bigger than that (just an example, i don't actually set my brush this big) (810.95 KB, image/png)
2023-10-31 05:15 UTC, johnschiefer25
Details

Note You need to log in before you can comment on or make changes to this bug.
Description johnschiefer25 2023-10-27 08:35:54 UTC
SUMMARY
The brush slider for the ink pen does not display the actual brush size of the pen, whenever i adjust the size (by sliding the slider or using the arrows on the side), the slider doesn't display the current size of the brush, but instead previous brush size. Weirdly, this also only happens on the ink pen brush, and not on any of the other brushes, this may be because I pressed the reload original preset button, since after I did that the slider started glitching, but I tested this on other brushes and it did not produce the same result, so I am not completely sure.

STEPS TO REPRODUCE
1. Press the "Reload Original Preset" button (*maybe?)
2. Change size of the brush
3. Draw something

OBSERVED RESULT
When I select ink pen and drastically change the size so that it's very big, I am able to slide it, but the moment i release the left click it goes back to displaying the original size it was at, if you draw you can see that the brush is much bigger than the actual size, which is something that should appear small.

EXPECTED RESULT
Should display the correct size of brush, and not reset back to original value once size is changed.


SOFTWARE/OS VERSIONS
macOS: Sonoma 14.0

ADDITIONAL INFORMATION
I have also reset all setting, but did not resolve the issue
Comment 1 Freya Lupen 2023-10-27 18:34:28 UTC
I can confirm such an issue with the "d) Ink pen (mypaint)" default brush, and other MyPaint brushes (regardless of whether they've been reloaded). The Radius Logarithmic and the Size don't seem to be synced correctly. It seems to work on 5.1.5, so this is a regression.

It may be related to an issue where some MyPaint brushes are marked as 'modified' just by selecting them, and reloading them changes the Size and the Logarithmic Radius curve.
Comment 2 johnschiefer25 2023-10-28 22:50:28 UTC
> It may be related to an issue where some MyPaint brushes are marked as
> 'modified' just by selecting them, and reloading them changes the Size and
> the Logarithmic Radius curve.

Can you send me a link to the bug report for this?
Comment 3 johnschiefer25 2023-10-30 00:53:28 UTC
It also seems that the error is somehow related to the software itself. I deleted the resource folder containing all of the information for the brushes so that krita could reinstall them and maybe could fix the ink pen issue, so I reopen krita, let it reinstall the resource folder but then when I use the ink pen it still has the same problem. I've also deleted and reinstalled the app itself but it also didn't fix the problem.

Note: So I also deleted the ink pen brush itself (and of course, couldn't find a way to get it back other than deleting & reinstalling the resource folder). While I was trying to get the ink pen back, I tried deleting and reinstalling the app several times, what's interesting is that the app wasn't back in its default settings, but was as it was when I deleted it. It had the same theme selected, the same ui configurations, and the ink pen brush was still deleted. I have no idea why this is because i'm not a tech genius or anything and also don't know the process behind installing the app (krita) from the krita website, so if someone could explain why this is, that'd be greatly appreciated).
Comment 4 johnschiefer25 2023-10-31 05:15:41 UTC
Created attachment 162756 [details]
the size is 0.01 pixels while the brush is clearly much bigger than that (just an example, i don't actually set my brush this big)
Comment 5 Dmitry Kazakov 2023-11-05 09:16:26 UTC
*** Bug 475930 has been marked as a duplicate of this bug. ***
Comment 6 Dmitry Kazakov 2023-11-06 14:27:04 UTC
*** Bug 476593 has been marked as a duplicate of this bug. ***
Comment 7 Dmitry Kazakov 2023-11-07 12:40:11 UTC
Git commit 8d317c39ee24a379ad88f121477748dc90bb9c4d by Dmitry Kazakov.
Committed on 07/11/2023 at 13:31.
Pushed by dkazakov into branch 'master'.

Extract the cache in KisMyPaintOpSettings to properly handle size updates

Brush size cache was not properly reset on preset change. Now it is a
part of a cache structure, so it is quite hard to forget about that.

A  +52   -0    libs/global/KisValueCache.h     [License: GPL(v2.0+)]
M  +1    -0    libs/global/tests/CMakeLists.txt
A  +43   -0    libs/global/tests/KisValueCacheTest.cpp     [License: GPL(v2.0+)]
A  +20   -0    libs/global/tests/KisValueCacheTest.h     [License: GPL(v2.0+)]
M  +54   -47   plugins/paintops/mypaint/MyPaintPaintOpSettings.cpp

https://invent.kde.org/graphics/krita/-/commit/8d317c39ee24a379ad88f121477748dc90bb9c4d
Comment 8 Dmitry Kazakov 2023-11-07 12:47:02 UTC
Git commit 3353155fc39fc35c0632fb81eca7c92a4abe9c3e by Dmitry Kazakov.
Committed on 07/11/2023 at 13:43.
Pushed by dkazakov into branch 'krita/5.2'.

Extract the cache in KisMyPaintOpSettings to properly handle size updates

Brush size cache was not properly reset on preset change. Now it is a
part of a cache structure, so it is quite hard to forget about that.

A  +52   -0    libs/global/KisValueCache.h     [License: GPL(v2.0+)]
M  +1    -0    libs/global/tests/CMakeLists.txt
A  +43   -0    libs/global/tests/KisValueCacheTest.cpp     [License: GPL(v2.0+)]
A  +20   -0    libs/global/tests/KisValueCacheTest.h     [License: GPL(v2.0+)]
M  +54   -47   plugins/paintops/mypaint/MyPaintPaintOpSettings.cpp

https://invent.kde.org/graphics/krita/-/commit/3353155fc39fc35c0632fb81eca7c92a4abe9c3e
Comment 9 Freya Lupen 2023-12-02 16:27:48 UTC
*** Bug 477921 has been marked as a duplicate of this bug. ***