Commit | Line | Data |
---|---|---|
2056b920 JC |
1 | /* SPDX-License-Identifier: GPL-2.0 */ |
2 | /* | |
3 | * CSS tweaks for the Alabaster theme | |
4 | */ | |
5 | ||
6 | /* Shrink the headers a bit */ | |
7 | div.body h1 { font-size: 180%; } | |
8 | div.body h2 { font-size: 150%; } | |
9 | div.body h3 { font-size: 130%; } | |
10 | ||
eed94315 VN |
11 | /* toctree captions are styled like h2 */ |
12 | div.toctree-wrapper p.caption[role=heading] { font-size: 150%; } | |
13 | ||
2056b920 JC |
14 | /* Tighten up the layout slightly */ |
15 | div.body { padding: 0 15px 0 10px; } | |
2056b920 | 16 | div.sphinxsidebarwrapper { padding: 1em 0.4em; } |
c404f5d4 JC |
17 | div.sphinxsidebar { font-size: inherit; |
18 | max-height: 100%; | |
19 | overflow-y: auto; } | |
eaf710ce JC |
20 | /* Tweak document margins and don't force width */ |
21 | div.document { | |
22 | margin: 20px 10px 0 10px; | |
23 | width: auto; | |
24 | } | |
25 | ||
d49af114 VN |
26 | /* Size the logo appropriately */ |
27 | img.logo { | |
28 | width: 104px; | |
29 | margin-bottom: 20px; | |
30 | } | |
31 | ||
eaf710ce JC |
32 | /* |
33 | * Parameters for the display of function prototypes and such included | |
34 | * from C source files. | |
35 | */ | |
36 | dl.function, dl.struct, dl.enum { margin-top: 2em; background-color: #ecf0f3; } | |
37 | /* indent lines 2+ of multi-line function prototypes */ | |
38 | dl.function dt { margin-left: 10em; text-indent: -10em; } | |
39 | dt.sig-object { font-size: larger; } | |
40 | div.kernelindent { margin-left: 2em; margin-right: 4em; } | |
c404f5d4 JC |
41 | |
42 | /* | |
43 | * Tweaks for our local TOC | |
44 | */ | |
45 | div.kerneltoc li.toctree-l1 { font-size: smaller; | |
46 | text-indent: -1em; | |
47 | margin-left: 1em; } | |
48 | div.kerneltoc li.current > a {font-weight: bold; } | |
49 | div.kerneltoc li.toctree-l2,li.toctree-l3 { font-size: small; | |
50 | text-indent: -1em; | |
51 | margin-left: 1em; | |
52 | list-style-type: none; | |
53 | } | |
54 | div.kerneltoc li.current ul { margin-left: 0; } | |
55 | div.kerneltoc { background-color: #eeeeee; } | |
56 | div.kerneltoc li.current ul { background-color: white; } | |
57 | ||
58 | /* | |
59 | * The CSS magic to toggle the contents on small screens. | |
60 | */ | |
61 | label.kernel-toc-title { display: none; } | |
62 | label.kernel-toc-title:after { | |
63 | content: "[Hide]"; | |
64 | } | |
65 | input[type=checkbox]:checked ~ label.kernel-toc-title:after { | |
66 | content: "[Show]"; | |
67 | } | |
68 | /* Hide the toggle on large screens */ | |
69 | input.kernel-toc-toggle { display: none; } | |
70 | ||
71 | /* | |
72 | * Show and implement the toggle on small screens. | |
73 | * The 875px width seems to be wired into alabaster. | |
74 | */ | |
75 | @media screen and (max-width: 875px) { | |
76 | label.kernel-toc-title { display: inline; | |
77 | font-weight: bold; | |
78 | font-size: larger; } | |
79 | input[type=checkbox]:checked ~ div.kerneltoc { | |
80 | display: none; | |
81 | } | |
82 | h3.kernel-toc-contents { display: inline; } | |
83 | div.kerneltoc a { color: black; } | |
84 | } |