QWebView出于某种奇怪的原因不想加载JPG图像。我该如何解决?
答案 0 :(得分:1)
尝试此选项
/*QWebView * view*/
view->page()->settings()->setAttribute(QWebSettings::LocalContentCanAccessRemoteUrls,true);
view->page()->settings()->setAttribute(QWebSettings::LocalContentCanAccessFileUrls,true);
view->page()->settings()->setAttribute(QWebSettings::LocalStorageEnabled,true);
view->page()->settings()->setAttribute(QWebSettings::AutoLoadImages,true);
这可能会有所帮助