Skip to content

447805 Fix sizing of preview images

Amy spark requested to merge lsegovia/krita:work/amyspark/447805-previews into master

There are inconsistencies in the resizing when the image is either too small or the height is bigger than the width.

This results on either cut off thumbnails on KRA files which are less than 512x512, or squished thumbnails on rectangular TIFF files.

BUG: 447805

Test Plan

Build Krita. Run it with native file dialogs disabled. Check that all miniatures are correctly rendered, and that files less than the preview size preserve their size.

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.
Edited by Amy spark

Merge request reports