Skip to content

[RichTextComposerImages] Rescale QImage accordingly

Igor Poboiko requested to merge poboiko/kpimtextedit:scale-image into master

The width and height are currently used to set properties of QTextImageFormat, which then are used to set "width" and "height" html properties for img tag, so that rescaling will be done by whoever reads generated html. The image itself is not affected. By also rescaling the image itself, we can save some space and reduce the size of the document (e.g.: I tried to add a HD photo of original size 4000x2000, whose base64 was ~12mb; I resized it to 500x250, and the size reduced to 300kb)

Merge request reports