[RichTextComposerImages] Rescale QImage accordingly

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)
1 job for master in 4 minutes and 33 seconds (queued for 3 seconds)
Status Job ID Name Coverage
  Build
passed #48569
linux kf5-qt5 qt5.12

00:04:33

61.0%