1

I have written a documentation using Sphinx, and as the software is written in Qt, I have tried the qthelp Sphinx output engine. The Sphinx installation is brand new and nothing was customized, and I tried with the simple Sphinx project from the documentation "First Steps with Sphinx".

The resulting html displays nicely in firefox, with the default Sphinx skin.

Then I compile this to .qhc using qcollectiongenerator.exe (under windows) and load it with Qt Assistant.

The document contents are there, but the rendering is ugly. For instance, the whole document has a dark blue background, whereas firefox only applies this color to the title bars.

Is the Qt HTML renderer fully incompliant? Is there a way to tell Sphinx to generate Qt friendly HTML styling?

Thanks!

Rubén
  • 34,714
  • 9
  • 70
  • 166
galinette
  • 8,896
  • 2
  • 36
  • 87
  • _"Is the Qt HTML renderer fully compliant?"_ Almost certainly not. I'm not aware of a _browser_ which is fully compliant, never mind a software component like Qt's. – enhzflep Sep 01 '15 at 15:34
  • Qt Assistant uses the built-in webkit to display the help pages. It applies certain default styling that is up to you to override by providing your own style sheets. – Kuba hasn't forgotten Monica Sep 01 '15 at 16:58
  • But the compiled html does contains its stylesheets. You can't have them automatically embedded in the qch? – galinette Sep 01 '15 at 20:01

1 Answers1

1

I'm having quite the same problems like you and I'm very unsatisfied with the produced output.

After some investigations I found out, that our Qt-5.5 Assistant works properly, whereas the Qt-5.10.0 Assistant was broken.

Opening the About-Dialog revealed the important difference between these two versions.

Qt 5.5 with Qt WebKit

Qt 5.10.0 with QTextBrowser

The Qt 5.10.0 Assistant was compiled with QTextBrowser in order to display the contents of the help file. It seems, that QTextBrowser lacks the ability to display CSS content, which destroys the layout of the help file.

Aleph0
  • 5,816
  • 4
  • 29
  • 80