diff options
author | Topi Reinio <topi.reinio@qt.io> | 2020-03-23 11:08:23 +0100 |
---|---|---|
committer | Topi Reinio <topi.reinio@qt.io> | 2020-03-26 15:28:31 +0100 |
commit | 0b5a1100ff5ab4fb696e0efc9bc5e8f266cf40ae (patch) | |
tree | 662ec88f9aa586c66d915c608d5a247f15aaee0a /doc | |
parent | 07558ae12d9b86bae9c5ee2b04414e6e34ec61b3 (diff) |
Doc: Adjust offline style for the litehtml rendering engine
Qt Creator now has the option to use the litehtml backend as a
replacement for the QTextBrowser-based help viewer.
Fix a few issues that the offline style has with the litehtml renderer:
- Fall back to using an unordered list for the navigation bar.
- Remove the background image for #buildversion and adjust font size.
- Adjust the generated padding around code snippets.
Keep the script that switches the offline-simple.css style to the
full offline style (offline.css) for JavaScript-enabled browsers.
The litehtml backend in Qt Creator will handle this switch internally.
With these changes, the generated offline documentation looks
acceptable when rendered with QTextBrowser, litehtml, or desktop
web browsers.
Fixes: QTBUG-82567
Change-Id: I86b179b1985b7ef54feddab30cb227b28021efe5
Reviewed-by: Leena Miettinen <riitta-leena.miettinen@qt.io>
Diffstat (limited to 'doc')
-rw-r--r-- | doc/global/qt-html-templates-offline-simple.qdocconf | 22 | ||||
-rw-r--r-- | doc/global/template/style/offline.css | 5 |
2 files changed, 7 insertions, 20 deletions
diff --git a/doc/global/qt-html-templates-offline-simple.qdocconf b/doc/global/qt-html-templates-offline-simple.qdocconf index c3c2d3cca0..02a3228519 100644 --- a/doc/global/qt-html-templates-offline-simple.qdocconf +++ b/doc/global/qt-html-templates-offline-simple.qdocconf @@ -19,27 +19,11 @@ HTML.headerstyles = \ " }, 0);\n" \ " </script>\n" -HTML.postheader = \ - "<body>\n" \ - "<div class=\"header\" id=\"qtdocheader\">\n"\ - " <div class=\"main\">\n" \ - " <div class=\"main-rounded\">\n" \ - " <div class=\"navigationbar\">\n" \ - " <table><tr>\n" - -HTML.postpostheader = \ - " </tr></table>\n"\ - " </div>\n" \ - " </div>\n" \ - "<div class=\"content\">\n" \ - "<div class=\"line\">\n" \ - "<div class=\"content mainContent\">\n" - HTML.navigationseparator = \ "<span class=\"naviSeparator\"> ◦ </span>\n" # Add some padding around code snippets, as we cannot # currectly style them for QTextBrowser using only CSS. -codeindent = 2 -codeprefix = "\n\n" -codesuffix = "\n\n" +codeindent = 1 +codeprefix = "\n" +codesuffix = "\n" diff --git a/doc/global/template/style/offline.css b/doc/global/template/style/offline.css index 13c942707a..f99369a096 100644 --- a/doc/global/template/style/offline.css +++ b/doc/global/template/style/offline.css @@ -297,11 +297,14 @@ table.buildversion { #buildversion { font-style: italic; - font-size: small; float: right; margin-right: 5px; } +#buildversion a { + background: none; +} + /* /* table of content |