diff options
author | Topi Reinio <topi.reinio@qt.io> | 2021-10-13 22:39:34 +0200 |
---|---|---|
committer | Qt Cherry-pick Bot <cherrypick_bot@qt-project.org> | 2021-11-03 14:47:28 +0000 |
commit | 646d8f86fdb0b6efcf51cde3282aad5015b14b28 (patch) | |
tree | 68c96302c2e00995108683af072d0944022b6001 /doc | |
parent | 76b028a6fe2842d0e33df4ee98cb6effb22847be (diff) |
Doc: Add styling for note/warning/important admonitions
The offline CSS already had some related rules, but at some point
QDoc lost the ability to produce the required markup. It has now
been reintroduced.
Task-number: QTBUG-97448
Change-Id: I5165cd01f3653dfb35854ca6b8040e8daa434347
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
(cherry picked from commit f6bb68c54810cc877ede4d5d3dcb155cc5ea2b4e)
Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'doc')
-rw-r--r-- | doc/global/template/style/offline.css | 35 | ||||
-rw-r--r-- | doc/global/template/style/online.css | 19 |
2 files changed, 26 insertions, 28 deletions
diff --git a/doc/global/template/style/offline.css b/doc/global/template/style/offline.css index acfae7eb10..4075845549 100644 --- a/doc/global/template/style/offline.css +++ b/doc/global/template/style/offline.css @@ -114,39 +114,18 @@ a[href*="https://"]::before { NOTE styles ------------------------------- */ - -.notetitle, .tiptitle, .fastpathtitle { - font-weight: bold -} - -.attentiontitle, .cautiontitle, .dangertitle, .importanttitle, .remembertitle, .restrictiontitle { - font-weight: bold +.admonition { + padding: 5px 0 5px 40px; + border: #ccc 1px solid; } -.note, .tip, .fastpath { - background: #F2F2F2 url(../images/ico_note.png); - background-repeat: no-repeat; - background-position: top left; - padding: 5px; - padding-left: 40px; - padding-bottom: 10px; - border: #999 1px dotted; - color: #666666; - margin: 5px; +.admonition.note, .admonition.important { + background: #f2f2f2 3px 6px no-repeat url(../images/ico_note.png); } -.attention, .caution, .danger, .important, .remember, .restriction { - background: #F2F2F2 url(../images/ico_note_attention.png); - background-repeat: no-repeat; - background-position: top left; - padding: 5px; - padding-left: 40px; - padding-bottom: 10px; - border: #999 1px dotted; - color: #666666; - margin: 5px; +.admonition.warning { + background: #f2f2f2 3px 6px no-repeat url(../images/ico_note_attention.png); } - /* ------------------------------- Top navigation diff --git a/doc/global/template/style/online.css b/doc/global/template/style/online.css index 7ad121d51f..23d387430e 100644 --- a/doc/global/template/style/online.css +++ b/doc/global/template/style/online.css @@ -987,6 +987,25 @@ pre, .LegaleseLeft { color:#fff; white-space: pre-wrap } +div.admonition { + margin:1.5em 0 1.5em; + padding:12px; +} +div.admonition.note { + background-color:#c5d3f4; + border-left:5px solid #7a9ae5; +} +div.admonition.warning { + background-color:#ffe4e4; + border-left:5px solid #ff8383; +} +div.admonition.important { + background-color:#fef9f3; + border-left:5px solid #f6cb97; +} +.mainContent .admonition p { + margin:0; +} pre .str,code .str { color:#aaaaaa } |