diff options
author | Topi Reinio <topi.reinio@qt.io> | 2021-10-13 22:39:34 +0200 |
---|---|---|
committer | Topi Reinio <topi.reinio@qt.io> | 2021-11-03 16:47:18 +0200 |
commit | f6bb68c54810cc877ede4d5d3dcb155cc5ea2b4e (patch) | |
tree | e447b480d3c294da25aa2c84e7a28c3bc04e8273 /doc/global | |
parent | fa53c624729ad5554b3698b700543fcf9c58166f (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.
Pick-to: 6.2 5.15
Task-number: QTBUG-97448
Change-Id: I5165cd01f3653dfb35854ca6b8040e8daa434347
Reviewed-by: Paul Wicking <paul.wicking@qt.io>
Diffstat (limited to 'doc/global')
-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 } |