Annotation of mandoc/mandoc.css, Revision 1.48
1.48 ! schwarze 1: /* $Id: mandoc.css,v 1.47 2020/10/30 21:34:30 schwarze Exp $ */
1.1 schwarze 2: /*
1.3 schwarze 3: * Standard style sheet for mandoc(1) -Thtml and man.cgi(8).
1.39 schwarze 4: *
5: * Written by Ingo Schwarze <schwarze@openbsd.org>.
6: * I place this file into the public domain.
7: * Permission to use, copy, modify, and distribute it for any purpose
8: * with or without fee is hereby granted, without any conditions.
1.1 schwarze 9: */
10:
1.3 schwarze 11: /* Global defaults. */
12:
1.46 schwarze 13: html { max-width: 65em;
14: --bg: #FFFFFF;
15: --fg: #000000; }
16: body { background: var(--bg);
17: color: var(--fg);
18: font-family: Helvetica,Arial,sans-serif; }
19: h1 { font-size: 110%; }
1.13 schwarze 20: table { margin-top: 0em;
1.40 schwarze 21: margin-bottom: 0em;
22: border-collapse: collapse; }
1.41 schwarze 23: /* Some browsers set border-color in a browser style for tbody,
24: * but not for table, resulting in inconsistent border styling. */
25: tbody { border-color: inherit; }
26: tr { border-color: inherit; }
1.42 schwarze 27: td { vertical-align: top;
1.40 schwarze 28: padding-left: 0.2em;
1.41 schwarze 29: padding-right: 0.2em;
30: border-color: inherit; }
1.12 schwarze 31: ul, ol, dl { margin-top: 0em;
32: margin-bottom: 0em; }
33: li, dt { margin-top: 1em; }
1.48 ! schwarze 34: pre { font-family: inherit; }
1.18 schwarze 35:
1.36 schwarze 36: .permalink { border-bottom: thin dotted;
1.18 schwarze 37: color: inherit;
38: font: inherit;
39: text-decoration: inherit; }
1.22 schwarze 40: * { clear: both }
1.3 schwarze 41:
42: /* Search form and search results. */
43:
44: fieldset { border: thin solid silver;
45: border-radius: 1em;
46: text-align: center; }
47: input[name=expr] {
48: width: 25%; }
49:
1.11 schwarze 50: table.results { margin-top: 1em;
1.3 schwarze 51: margin-left: 2em;
52: font-size: smaller; }
53:
1.4 schwarze 54: /* Header and footer lines. */
55:
1.13 schwarze 56: table.head { width: 100%;
57: border-bottom: 1px dotted #808080;
1.4 schwarze 58: margin-bottom: 1em;
59: font-size: smaller; }
60: td.head-vol { text-align: center; }
61: td.head-rtitle {
62: text-align: right; }
63:
1.13 schwarze 64: table.foot { width: 100%;
65: border-top: 1px dotted #808080;
1.4 schwarze 66: margin-top: 1em;
67: font-size: smaller; }
1.13 schwarze 68: td.foot-os { text-align: right; }
1.4 schwarze 69:
1.5 schwarze 70: /* Sections and paragraphs. */
71:
1.36 schwarze 72: .manual-text {
1.30 schwarze 73: margin-left: 3.8em; }
1.44 schwarze 74: .Nd { }
1.45 schwarze 75: section.Sh { }
76: h1.Sh { margin-top: 1.2em;
1.35 schwarze 77: margin-bottom: 0.6em;
1.46 schwarze 78: margin-left: -3.2em; }
1.45 schwarze 79: section.Ss { }
80: h2.Ss { margin-top: 1.2em;
1.35 schwarze 81: margin-bottom: 0.6em;
1.30 schwarze 82: margin-left: -1.2em;
1.5 schwarze 83: font-size: 105%; }
1.35 schwarze 84: .Pp { margin: 0.6em 0em; }
1.32 schwarze 85: .Sx { }
86: .Xr { }
1.3 schwarze 87:
1.7 schwarze 88: /* Displays and lists. */
89:
1.32 schwarze 90: .Bd { }
1.33 schwarze 91: .Bd-indent { margin-left: 3.8em; }
1.7 schwarze 92:
1.36 schwarze 93: .Bl-bullet { list-style-type: disc;
1.8 schwarze 94: padding-left: 1em; }
1.36 schwarze 95: .Bl-bullet > li { }
96: .Bl-dash { list-style-type: none;
1.8 schwarze 97: padding-left: 0em; }
1.36 schwarze 98: .Bl-dash > li:before {
1.8 schwarze 99: content: "\2014 "; }
1.36 schwarze 100: .Bl-item { list-style-type: none;
1.8 schwarze 101: padding-left: 0em; }
1.36 schwarze 102: .Bl-item > li { }
103: .Bl-compact > li {
1.30 schwarze 104: margin-top: 0em; }
1.8 schwarze 105:
1.36 schwarze 106: .Bl-enum { padding-left: 2em; }
107: .Bl-enum > li { }
108: .Bl-compact > li {
1.30 schwarze 109: margin-top: 0em; }
1.8 schwarze 110:
1.36 schwarze 111: .Bl-diag { }
112: .Bl-diag > dt {
1.25 schwarze 113: font-style: normal;
114: font-weight: bold; }
1.36 schwarze 115: .Bl-diag > dd {
1.30 schwarze 116: margin-left: 0em; }
1.36 schwarze 117: .Bl-hang { }
118: .Bl-hang > dt { }
119: .Bl-hang > dd {
1.30 schwarze 120: margin-left: 5.5em; }
1.36 schwarze 121: .Bl-inset { }
122: .Bl-inset > dt { }
123: .Bl-inset > dd {
1.30 schwarze 124: margin-left: 0em; }
1.36 schwarze 125: .Bl-ohang { }
126: .Bl-ohang > dt { }
127: .Bl-ohang > dd {
1.30 schwarze 128: margin-left: 0em; }
1.43 schwarze 129: .Bl-tag { margin-top: 0.6em;
130: margin-left: 5.5em; }
1.36 schwarze 131: .Bl-tag > dt {
1.25 schwarze 132: float: left;
1.30 schwarze 133: margin-top: 0em;
134: margin-left: -5.5em;
1.37 schwarze 135: padding-right: 0.5em;
1.14 schwarze 136: vertical-align: top; }
1.36 schwarze 137: .Bl-tag > dd {
1.25 schwarze 138: clear: right;
1.47 schwarze 139: column-count: 1; /* Force block formatting context. */
1.22 schwarze 140: width: 100%;
1.30 schwarze 141: margin-top: 0em;
142: margin-left: 0em;
1.43 schwarze 143: margin-bottom: 0.6em;
1.47 schwarze 144: vertical-align: top; }
1.43 schwarze 145: .Bl-compact { margin-top: 0em; }
146: .Bl-compact > dd {
147: margin-bottom: 0em; }
1.36 schwarze 148: .Bl-compact > dt {
1.30 schwarze 149: margin-top: 0em; }
1.8 schwarze 150:
1.36 schwarze 151: .Bl-column { }
152: .Bl-column > tbody > tr { }
153: .Bl-column > tbody > tr > td {
1.25 schwarze 154: margin-top: 1em; }
1.36 schwarze 155: .Bl-compact > tbody > tr > td {
1.30 schwarze 156: margin-top: 0em; }
1.8 schwarze 157:
1.32 schwarze 158: .Rs { font-style: normal;
1.15 schwarze 159: font-weight: normal; }
1.32 schwarze 160: .RsA { }
161: .RsB { font-style: italic;
162: font-weight: normal; }
163: .RsC { }
164: .RsD { }
165: .RsI { font-style: italic;
166: font-weight: normal; }
167: .RsJ { font-style: italic;
168: font-weight: normal; }
169: .RsN { }
170: .RsO { }
171: .RsP { }
172: .RsQ { }
173: .RsR { }
174: .RsT { text-decoration: underline; }
175: .RsU { }
176: .RsV { }
1.9 schwarze 177:
1.32 schwarze 178: .eqn { }
1.42 schwarze 179: .tbl td { vertical-align: middle; }
1.11 schwarze 180:
1.34 schwarze 181: .HP { margin-left: 3.8em;
182: text-indent: -3.8em; }
183:
1.10 schwarze 184: /* Semantic markup for command line utilities. */
185:
186: table.Nm { }
1.24 schwarze 187: code.Nm { font-style: normal;
188: font-weight: bold;
189: font-family: inherit; }
1.32 schwarze 190: .Fl { font-style: normal;
1.24 schwarze 191: font-weight: bold;
192: font-family: inherit; }
1.32 schwarze 193: .Cm { font-style: normal;
1.24 schwarze 194: font-weight: bold;
195: font-family: inherit; }
1.32 schwarze 196: .Ar { font-style: italic;
1.16 schwarze 197: font-weight: normal; }
1.32 schwarze 198: .Op { display: inline; }
199: .Ic { font-style: normal;
1.24 schwarze 200: font-weight: bold;
201: font-family: inherit; }
1.32 schwarze 202: .Ev { font-style: normal;
1.10 schwarze 203: font-weight: normal;
204: font-family: monospace; }
1.32 schwarze 205: .Pa { font-style: italic;
1.27 schwarze 206: font-weight: normal; }
1.10 schwarze 207:
208: /* Semantic markup for function libraries. */
209:
1.32 schwarze 210: .Lb { }
1.24 schwarze 211: code.In { font-style: normal;
212: font-weight: bold;
213: font-family: inherit; }
1.10 schwarze 214: a.In { }
1.32 schwarze 215: .Fd { font-style: normal;
1.24 schwarze 216: font-weight: bold;
217: font-family: inherit; }
1.32 schwarze 218: .Ft { font-style: italic;
1.16 schwarze 219: font-weight: normal; }
1.32 schwarze 220: .Fn { font-style: normal;
1.24 schwarze 221: font-weight: bold;
222: font-family: inherit; }
1.32 schwarze 223: .Fa { font-style: italic;
1.16 schwarze 224: font-weight: normal; }
1.32 schwarze 225: .Vt { font-style: italic;
1.16 schwarze 226: font-weight: normal; }
1.32 schwarze 227: .Va { font-style: italic;
1.16 schwarze 228: font-weight: normal; }
1.32 schwarze 229: .Dv { font-style: normal;
1.10 schwarze 230: font-weight: normal;
231: font-family: monospace; }
1.32 schwarze 232: .Er { font-style: normal;
1.10 schwarze 233: font-weight: normal;
234: font-family: monospace; }
235:
236: /* Various semantic markup. */
237:
1.32 schwarze 238: .An { }
239: .Lk { }
240: .Mt { }
241: .Cd { font-style: normal;
1.24 schwarze 242: font-weight: bold;
243: font-family: inherit; }
1.32 schwarze 244: .Ad { font-style: italic;
1.28 schwarze 245: font-weight: normal; }
1.32 schwarze 246: .Ms { font-style: normal;
1.29 schwarze 247: font-weight: bold; }
1.32 schwarze 248: .St { }
249: .Ux { }
1.10 schwarze 250:
1.11 schwarze 251: /* Physical markup. */
1.7 schwarze 252:
1.26 schwarze 253: .Bf { display: inline; }
1.11 schwarze 254: .No { font-style: normal;
255: font-weight: normal; }
256: .Em { font-style: italic;
257: font-weight: normal; }
258: .Sy { font-style: normal;
259: font-weight: bold; }
1.7 schwarze 260: .Li { font-style: normal;
261: font-weight: normal;
262: font-family: monospace; }
1.44 schwarze 263:
264: /* Tooltip support. */
265:
1.45 schwarze 266: h1.Sh, h2.Ss { position: relative; }
1.44 schwarze 267: .An, .Ar, .Cd, .Cm, .Dv, .Em, .Er, .Ev, .Fa, .Fd, .Fl, .Fn, .Ft,
268: .Ic, code.In, .Lb, .Lk, .Ms, .Mt, .Nd, code.Nm, .Pa, .Rs,
269: .St, .Sx, .Sy, .Va, .Vt, .Xr {
270: display: inline-block;
271: position: relative; }
272:
273: .An::before { content: "An"; }
274: .Ar::before { content: "Ar"; }
275: .Cd::before { content: "Cd"; }
276: .Cm::before { content: "Cm"; }
277: .Dv::before { content: "Dv"; }
278: .Em::before { content: "Em"; }
279: .Er::before { content: "Er"; }
280: .Ev::before { content: "Ev"; }
281: .Fa::before { content: "Fa"; }
282: .Fd::before { content: "Fd"; }
283: .Fl::before { content: "Fl"; }
284: .Fn::before { content: "Fn"; }
285: .Ft::before { content: "Ft"; }
286: .Ic::before { content: "Ic"; }
287: code.In::before { content: "In"; }
288: .Lb::before { content: "Lb"; }
289: .Lk::before { content: "Lk"; }
290: .Ms::before { content: "Ms"; }
291: .Mt::before { content: "Mt"; }
292: .Nd::before { content: "Nd"; }
293: code.Nm::before { content: "Nm"; }
294: .Pa::before { content: "Pa"; }
295: .Rs::before { content: "Rs"; }
1.45 schwarze 296: h1.Sh::before { content: "Sh"; }
297: h2.Ss::before { content: "Ss"; }
1.44 schwarze 298: .St::before { content: "St"; }
299: .Sx::before { content: "Sx"; }
300: .Sy::before { content: "Sy"; }
301: .Va::before { content: "Va"; }
302: .Vt::before { content: "Vt"; }
303: .Xr::before { content: "Xr"; }
304:
305: .An::before, .Ar::before, .Cd::before, .Cm::before,
306: .Dv::before, .Em::before, .Er::before, .Ev::before,
307: .Fa::before, .Fd::before, .Fl::before, .Fn::before, .Ft::before,
308: .Ic::before, code.In::before, .Lb::before, .Lk::before,
309: .Ms::before, .Mt::before, .Nd::before, code.Nm::before,
310: .Pa::before, .Rs::before,
1.45 schwarze 311: h1.Sh::before, h2.Ss::before, .St::before, .Sx::before, .Sy::before,
1.44 schwarze 312: .Va::before, .Vt::before, .Xr::before {
313: opacity: 0;
314: transition: .15s ease opacity;
315: pointer-events: none;
316: position: absolute;
317: bottom: 100%;
1.46 schwarze 318: box-shadow: 0 0 .35em var(--fg);
1.44 schwarze 319: padding: .15em .25em;
320: white-space: nowrap;
321: font-family: Helvetica,Arial,sans-serif;
322: font-style: normal;
323: font-weight: bold;
1.46 schwarze 324: background: var(--bg);
325: color: var(--fg); }
1.44 schwarze 326: .An:hover::before, .Ar:hover::before, .Cd:hover::before, .Cm:hover::before,
327: .Dv:hover::before, .Em:hover::before, .Er:hover::before, .Ev:hover::before,
328: .Fa:hover::before, .Fd:hover::before, .Fl:hover::before, .Fn:hover::before,
329: .Ft:hover::before, .Ic:hover::before, code.In:hover::before,
330: .Lb:hover::before, .Lk:hover::before, .Ms:hover::before, .Mt:hover::before,
331: .Nd:hover::before, code.Nm:hover::before, .Pa:hover::before,
1.45 schwarze 332: .Rs:hover::before, h1.Sh:hover::before, h2.Ss:hover::before, .St:hover::before,
1.44 schwarze 333: .Sx:hover::before, .Sy:hover::before, .Va:hover::before, .Vt:hover::before,
334: .Xr:hover::before {
335: opacity: 1;
336: pointer-events: inherit; }
1.31 schwarze 337:
338: /* Overrides to avoid excessive margins on small devices. */
339:
340: @media (max-width: 37.5em) {
1.36 schwarze 341: .manual-text {
1.31 schwarze 342: margin-left: 0.5em; }
1.45 schwarze 343: h1.Sh, h2.Ss { margin-left: 0em; }
1.33 schwarze 344: .Bd-indent { margin-left: 2em; }
1.36 schwarze 345: .Bl-hang > dd {
1.31 schwarze 346: margin-left: 2em; }
1.36 schwarze 347: .Bl-tag { margin-left: 2em; }
348: .Bl-tag > dt {
1.31 schwarze 349: margin-left: -2em; }
1.34 schwarze 350: .HP { margin-left: 2em;
351: text-indent: -2em; }
1.46 schwarze 352: }
353:
354: /* Overrides for a dark color scheme for accessibility. */
355:
356: @media (prefers-color-scheme: dark) {
357: html { --bg: #1E1F21;
358: --fg: #EEEFF1; }
359: :link { color: #BAD7FF; }
360: :visited { color: #F6BAFF; }
1.31 schwarze 361: }
CVSweb