<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[QHelpEngine does not display images]]></title><description><![CDATA[<p dir="auto">Hello all,</p>
<p dir="auto">I'm using a QHelpEngine to display my help files (html files) in my custom QTextBrowser. I have generated my help.qch and help.qhc files correctly (I presume) since I verified it using the assistant: assistant -collectionFile help.qhc and indeed my html page was displayed as expected including the .gif image that was present in the html page.</p>
<p dir="auto">Now I'm trying to display the same content in my application and again I can display the html file but now my image is lost and is replaced with the image_broken_icon.</p>
<p dir="auto">**In short, my implementation of qhelpengine with qtextbrowser does not display the images that are present in the html files that I'm loading in the qtextbrowser. **<br />
Any insights would be greatly appreciated!</p>
<p dir="auto">This is the part of the code where I load the html file:</p>
<pre><code>void HelpBrowser::setSource(const QUrl &amp;url) {
   if (helpEngine != 0) {
	QByteArray helpData = helpEngine-&gt;fileData(url);
	// show the documentation to the user
	if (!helpData.isEmpty()) {
		setHtml(QLatin1String(helpData));
	}

	int anchorPos = url.toString().indexOf(QChar('#'));
	if (anchorPos &gt;= 0){
		QString anchor = url.toString().mid(anchorPos+1);
		scrollToAnchor(anchor);
	}
  }
}
</code></pre>
<p dir="auto">Thank you for your help,<br />
Laura</p>
]]></description><link>https://forum.qt.io/topic/60866/qhelpengine-does-not-display-images</link><generator>RSS for Node</generator><lastBuildDate>Thu, 10 Sep 2026 03:59:52 GMT</lastBuildDate><atom:link href="https://forum.qt.io/topic/60866.rss" rel="self" type="application/rss+xml"/><pubDate>Fri, 20 Nov 2015 16:34:17 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to QHelpEngine does not display images on Wed, 16 Dec 2015 10:24:14 GMT]]></title><description><![CDATA[<p dir="auto">I encountered the same issue, but since QtAssistant displays images without telling it where to find them, how does it manage to find them? It has to be somewhere in the qch file, right?</p>
]]></description><link>https://forum.qt.io/post/302968</link><guid isPermaLink="true">https://forum.qt.io/post/302968</guid><dc:creator><![CDATA[[[global:former-user]]]]></dc:creator><pubDate>Wed, 16 Dec 2015 10:24:14 GMT</pubDate></item><item><title><![CDATA[Reply to QHelpEngine does not display images on Mon, 23 Nov 2015 14:53:55 GMT]]></title><description><![CDATA[<p dir="auto">Hello again,</p>
<p dir="auto">Thanks for the suggestion! I used process monitor (windows) and tried to see where my application is trying to load the image files from. Apparently, I had misunderstood that my image file is also part of the help.qch file. That's not the case. I could load my html files correctly when I placed my images folder in the directory of the executable.</p>
<p dir="auto">Best,<br />
Laura</p>
]]></description><link>https://forum.qt.io/post/299359</link><guid isPermaLink="true">https://forum.qt.io/post/299359</guid><dc:creator><![CDATA[[[global:former-user]]]]></dc:creator><pubDate>Mon, 23 Nov 2015 14:53:55 GMT</pubDate></item><item><title><![CDATA[Reply to QHelpEngine does not display images on Fri, 20 Nov 2015 19:12:07 GMT]]></title><description><![CDATA[<p dir="auto">Hi<br />
its most likely something with path. where images are and where QTextBrowser<br />
looks for them.</p>
<p dir="auto"><a href="http://www.walletfox.com/course/qhelpengineexample.php" target="_blank" rel="noopener noreferrer nofollow ugc">http://www.walletfox.com/course/qhelpengineexample.php</a></p>
]]></description><link>https://forum.qt.io/post/299002</link><guid isPermaLink="true">https://forum.qt.io/post/299002</guid><dc:creator><![CDATA[mrjj]]></dc:creator><pubDate>Fri, 20 Nov 2015 19:12:07 GMT</pubDate></item></channel></rss>