Bundle Creator and resource thumbnail fixes
This started as an attempt to fix a regression with resource thumbnails in 5.3.x, which was caused by the Bundle Creator rewrite. But I ended up fixing several other bugs in the same area, some of which are also regressions, and some aren't.
"Improve rendering of pattern thumbnails":
Comparison screenshots using a combination of Krita default (mostly 512px and grey), GIMP default (mostly 64px and colored), and KA patterns.
2x display scale, 5.2.5 vs this MR:
Before, it's blurry and small patterns are too zoomed in. After, it's crisp and both large and small patterns are readable.
1x display scale, 5.2.5 vs this MR (accidentally has some different patterns from the 2x screenshots):
Before, large patterns are too zoomed out, that some of them are just grey blobs. After, both small and large patterns are readable.
How much the large patterns should be zoomed and what's considered a large pattern is somewhat debatable though.
Test Plan
- In the Bundle Creator, check that SeExpr scripts are listed. (Regression)
- Switch application language to non-English, restart, and check that resources are shown in the Bundle Creator. (Regression)
- In the Resource Manager, check the icon and the tooltip thumbnails aren't squished (example: RGBA bundle's brushtips). (Regression for icons, not for tooltips)
- In the Pattern Docker, check that the pattern preview is rendered at the same scale as on canvas at 100% zoom in display mode, and the preview is displayed correctly on startup and when resizing the window. (Not a regression)
- Anywhere with pattern thumbnails, check that they are prettier than 5.2.x. They should be non-blurry and zoomed enough to distinguish details, regardless of display scaling. (Not a regression)
- Check that the Bundle Creator saves bundle icons correctly. (Regression) (Note: when editing an existing bundle, the bundle manager will not show the new icon even after restarting.)
- Check that Krita doesn't crash when trying to edit a recently-made bundle with SeExpr scripts. (The assert that's been changed to a safe assert needs investigation.)
Formalities Checklist
-
I confirmed this builds. -
I confirmed Krita ran and the relevant functions work. -
I tested the relevant unit tests and can confirm they are not broken. (If not possible, don't hesitate to ask for help!) -
I made sure my commits build individually and have good descriptions as per KDE guidelines. -
I made sure my code conforms to the standards set in the HACKING file. -
I can confirm the code is licensed and attributed appropriately, and that unattributed code is mine, as per KDE Licensing Policy. -
Does the patch add a user-visible feature? If yes, is there a documentation MR ready for it at Krita Documentation Repository?
Reminder: the reviewer is responsible for merging the patch, this is to ensure at the least two people can build the patch. In case a patch breaks the build, both the author and the reviewer should be contacted to fix the build. If this is not possible, the commits shall be reverted, and a notification with the reasoning and any relevant logs shall be sent to the mailing list, kimageshop@kde.org.



