1/* SPDX-License-Identifier: GPL-2.0 */ 2/* 3 * CSS tweaks for the Alabaster theme 4 */ 5 6/* Shrink the headers a bit */ 7div.body h1 { font-size: 180%; } 8div.body h2 { font-size: 150%; } 9div.body h3 { font-size: 130%; } 10div.body h4 { font-size: 110%; } 11 12/* toctree captions are styled like h2 */ 13div.toctree-wrapper p.caption[role=heading] { font-size: 150%; } 14 15/* Tighten up the layout slightly */ 16div.body { padding: 0 15px 0 10px; } 17div.sphinxsidebarwrapper { padding: 1em 0.4em; } 18div.sphinxsidebar { font-size: inherit; 19 max-height: 100%; 20 overflow-y: auto; } 21/* Tweak document margins and don't force width */ 22div.document { 23 margin: 20px 10px 0 10px; 24 width: auto; 25} 26 27/* Size the logo appropriately */ 28img.logo { 29 width: 104px; 30 margin-bottom: 20px; 31} 32 33/* The default is to use -1em, wich makes it override text */ 34li { text-indent: 0em; } 35 36/* 37 * Parameters for the display of function prototypes and such included 38 * from C source files. 39 */ 40dl.function, dl.struct, dl.enum { margin-top: 2em; background-color: #ecf0f3; } 41/* indent lines 2+ of multi-line function prototypes */ 42dl.function dt { margin-left: 10em; text-indent: -10em; } 43dt.sig-object { font-size: larger; } 44div.kernelindent { margin-left: 2em; margin-right: 4em; } 45 46/* 47 * Tweaks for our local TOC 48 */ 49div.kerneltoc li.toctree-l1 { font-size: smaller; 50 text-indent: -1em; 51 margin-left: 1em; } 52div.kerneltoc li.current > a {font-weight: bold; } 53div.kerneltoc li.toctree-l2,li.toctree-l3 { font-size: small; 54 text-indent: -1em; 55 margin-left: 1em; 56 list-style-type: none; 57 } 58div.kerneltoc li.current ul { margin-left: 0; } 59div.kerneltoc { background-color: #eeeeee; } 60div.kerneltoc li.current ul { background-color: white; } 61 62/* 63 * The CSS magic to toggle the contents on small screens. 64 */ 65label.kernel-toc-title { display: none; } 66label.kernel-toc-title:after { 67 content: "[Hide]"; 68} 69input[type=checkbox]:checked ~ label.kernel-toc-title:after { 70 content: "[Show]"; 71} 72/* Hide the toggle on large screens */ 73input.kernel-toc-toggle { display: none; } 74 75/* 76 * Show and implement the toggle on small screens. 77 * The 875px width seems to be wired into alabaster. 78 */ 79@media screen and (max-width: 875px) { 80 label.kernel-toc-title { display: inline; 81 font-weight: bold; 82 font-size: larger; } 83 input[type=checkbox]:checked ~ div.kerneltoc { 84 display: none; 85 } 86 h3.kernel-toc-contents { display: inline; } 87 div.kerneltoc a { color: black; } 88} 89 90/* Language selection menu */ 91 92div.admonition { 93 /* 94 * Make sure we don't overlap notes and warnings at the top of the 95 * document. 96 */ 97 clear: both; 98} 99 100div.language-selection { 101 background: #eeeeee; 102 border: 1px solid #cccccc; 103 margin-bottom: 1em; 104 padding: .5em; 105 106 position: relative; 107 float: right; 108} 109 110div.language-selection a { 111 display: block; 112 padding: 0.5em; 113 color: #333333; 114 text-decoration: none; 115} 116 117div.language-selection ul { 118 display: none; 119 position: absolute; 120 121 /* Align with the parent div */ 122 top: 100%; 123 right: 0; 124 margin: 0; 125 126 list-style: none; 127 128 background: #fafafa; 129 border: 1px solid #cccccc; 130 131 /* Never break menu item lines */ 132 white-space: nowrap; 133} 134 135div.language-selection:hover ul { 136 display: block; 137} 138 139div.language-selection ul li:hover { 140 background: #dddddd; 141} 142 143/* Make xrefs more universally visible */ 144a.reference, a.reference:hover { 145 border-bottom: none; 146 text-decoration: underline; 147 text-underline-offset: 0.3em; 148} 149 150/* Slightly different style for sidebar links */ 151div.sphinxsidebar a { border-bottom: none; } 152div.sphinxsidebar a:hover { 153 border-bottom: none; 154 text-decoration: underline; 155 text-underline-offset: 0.3em; 156} 157 158a.manpage { 159 font-style: normal; 160 font-weight: bold; 161 font-family: "Courier New", Courier, monospace; 162} 163