Hi!
I have an image 640x480 (for example) and one code:
QSimpleRichText
*aaa
= new QSimpleRichText
("<img src=\"/path/to/my/image_640x480.jpg\">", font
(),
QString::null,
0);
QSimpleRichText *aaa = new QSimpleRichText("<img src=\"/path/to/my/image_640x480.jpg\">", font(), QString::null, 0);
To copy to clipboard, switch view to plain text mode
and the second one:
QSimpleRichText
*bbb
= new QSimpleRichText
("<img src=\"/path/to/my/image_640x480.jpg\">", font
(),
QString::null,
0, QMimeSourceFactory
::defaultFactory());
QSimpleRichText *bbb = new QSimpleRichText("<img src=\"/path/to/my/image_640x480.jpg\">", font(), QString::null, 0, QMimeSourceFactory::defaultFactory());
To copy to clipboard, switch view to plain text mode
...and results (varible: value):
aaa->widthUsed(): 648
aaa->width(): 644
aaa->height(): 486
bbb->widthUsed(): 656
bbb->width(): 652
bbb->height(): 486
Who could tell me:
1. Why none of these values is equal to image's sizes?
2. Why values of "aaa" are different then "bbb's"?
3. What can i do to give QSimpleRichText proper values (i mean equal to image's sizes)?
Bookmarks