Skip to content

Commit c133763

Browse files
committed
Merge pull request #4775 from jorisvandenbossche/docstring-rendering
DOC: some stylistic improvements to docstring rendering in documentation
2 parents 9d552d7 + f4705f6 commit c133763

File tree

1 file changed

+52
-2
lines changed

1 file changed

+52
-2
lines changed

doc/source/themes/nature_with_gtoc/static/nature.css_t

+52-2
Original file line numberDiff line numberDiff line change
@@ -178,6 +178,10 @@ div.body h4 { font-size: 110%; background-color: #D8DEE3; }
178178
div.body h5 { font-size: 100%; background-color: #D8DEE3; }
179179
div.body h6 { font-size: 100%; background-color: #D8DEE3; }
180180

181+
p.rubric {
182+
border-bottom: 1px solid rgb(201, 201, 201);
183+
}
184+
181185
a.headerlink {
182186
color: #c60f0f;
183187
font-size: 0.8em;
@@ -231,10 +235,10 @@ p.admonition-title:after {
231235

232236
pre {
233237
padding: 10px;
234-
background-color: White;
238+
background-color: rgb(250,250,250);
235239
color: #222;
236240
line-height: 1.2em;
237-
border: 1px solid #C6C9CB;
241+
border: 1px solid rgb(201,201,201);
238242
font-size: 1.1em;
239243
margin: 1.5em 0 1.5em 0;
240244
-webkit-box-shadow: 1px 1px 1px #d8d8d8;
@@ -258,3 +262,49 @@ div.viewcode-block:target {
258262
border-top: 1px solid #ac9;
259263
border-bottom: 1px solid #ac9;
260264
}
265+
266+
267+
/**
268+
* Styling for field lists
269+
*/
270+
271+
/* grey highlighting of 'parameter' and 'returns' field */
272+
table.field-list {
273+
border-collapse: separate;
274+
border-spacing: 10px;
275+
margin-left: 1px;
276+
/* border-left: 5px solid rgb(238, 238, 238) !important; */
277+
}
278+
279+
table.field-list th.field-name {
280+
/* display: inline-block; */
281+
padding: 1px 8px 1px 5px;
282+
white-space: nowrap;
283+
background-color: rgb(238, 238, 238);
284+
}
285+
286+
/* italic font for parameter types */
287+
table.field-list td.field-body > p {
288+
font-style: italic;
289+
}
290+
291+
table.field-list td.field-body > p > strong {
292+
font-style: normal;
293+
}
294+
295+
/* reduced space around parameter description */
296+
td.field-body blockquote {
297+
border-left: none;
298+
margin: 0em 0em 0.3em;
299+
padding-left: 30px;
300+
}
301+
302+
303+
/**
304+
* See also
305+
*/
306+
307+
div.seealso dd {
308+
margin-top: 0;
309+
margin-bottom: 0;
310+
}

0 commit comments

Comments
 (0)