Skip to content

Commit

Permalink
Infra: Improve print style (#3486)
Browse files Browse the repository at this point in the history
  • Loading branch information
srittau authored Nov 14, 2023
1 parent bf0b381 commit 6643c37
Showing 1 changed file with 61 additions and 1 deletion.
62 changes: 61 additions & 1 deletion pep_sphinx_extensions/pep_theme/static/mq.css
Original file line number Diff line number Diff line change
Expand Up @@ -88,8 +88,12 @@
img {
max-width: 100% !important;
}
/* Page margins according to DIN 5008, leaves space for punched holes. */
@page {
margin: 0.5cm;
margin-top: 2cm;
margin-bottom: 2cm;
margin-left: 2.5cm;
margin-right: 2.5cm;
}
p,
h2,
Expand All @@ -102,4 +106,60 @@
h3 {
page-break-after: avoid;
}
h1 {
font-size: 18pt;
font-weight: bold;
text-align: center;
}
h2, details > summary {
font-size: 15pt;
font-weight: normal;
}
h3 {
font-size: 13pt;
font-weight: normal;
}
h4 {
font-size: 10pt;
font-weight: 600;
}
a, abbr {
text-decoration: none;
}

details {
display: none;
}
details[open] {
display: block;
}

h1.page-title:first-child {
margin-top: 0;
}

section#pep-page-section {
display: flex;
justify-content: center;
padding: 0;
margin: 0 auto;
}

section#pep-page-section > header,
nav#pep-sidebar {
display: none;
}

section#pep-page-section > article {
float: none;
max-width: 17.5cm;
width: auto;
margin: 0;
padding: 0;
}

/* This blocks a small portion on each page. */
readthedocs-flyout {
display: none;
}
}

0 comments on commit 6643c37

Please sign in to comment.