[QImageItem/QPixmapItem] Don't lose precision during calculation
ClosedPublic

Authored by broulik on Dec 2 2019, 3:02 PM.

Details

Summary

Operate on QRectF/QSizeF and only round back to integer at the end.

Test Plan

I've always been under the impression that the previews in icons kcm were misaligned or cut off slightly.
Before


After

  • Notification thumbnail strip (qpixmapitem) still works
  • QR code in klipper (qimageitem) still works

Diff Detail

Repository
R296 KDeclarative
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
broulik created this revision.Dec 2 2019, 3:02 PM
Restricted Application added a project: Frameworks. · View Herald TranscriptDec 2 2019, 3:02 PM
Restricted Application added a subscriber: kde-frameworks-devel. · View Herald Transcript
broulik requested review of this revision.Dec 2 2019, 3:02 PM
davidedmundson accepted this revision.Dec 10 2019, 9:40 PM
This revision is now accepted and ready to land.Dec 10 2019, 9:40 PM
This revision was automatically updated to reflect the committed changes.