i like to display image from server without downloading it , sure i can use qwebkit. but i like to be able to display the image in some kind of开发者_如何学JAVA list . what option do i have ?
I know that QTextEdit
supports img
tags, and I use them in lists. However, I don't know if it actually supports full URLs for those images, I just use images from the resource file. You could however give it a try.
Use setHTML()
to set the HTML source code, setText()
assumes plain-text.
You -have to- download the image manually and load it into a QPixmap to show it. You can use libcurl to download the image, it's pretty solid and works on virtually any platform. And really easy to use.
精彩评论