Skip to content

Commit

Permalink
Merge pull request #2666 from Grimmys/docs-sphinx-4-upgrade
Browse files Browse the repository at this point in the history
Docs sphinx 4 upgrade
  • Loading branch information
Charlie Hayden committed Oct 5, 2021
2 parents f5568a0 + b576d34 commit 3d0d25c
Show file tree
Hide file tree
Showing 2 changed files with 45 additions and 35 deletions.
2 changes: 0 additions & 2 deletions docs/reST/ref/scrap.rst
Original file line number Diff line number Diff line change
Expand Up @@ -78,8 +78,6 @@ For an example of how the scrap module works refer to the examples page

:raises pygame.error: if unable to initialize scrap module

|
.. note:: The scrap module requires :func:`pygame.display.set_mode()` be
called before being initialized.

Expand Down
78 changes: 45 additions & 33 deletions docs/reST/themes/classic/static/pygame.css_t
Original file line number Diff line number Diff line change
Expand Up @@ -66,8 +66,7 @@ div.body table.matrix th.stub {

/* Let a float element be beside a code block */
div.highlight-python.notranslate {
margin: 0;
clear: none;
display: inline-block;
}

/* -- page layout ----------------------------------------------------------- */
Expand Down Expand Up @@ -147,13 +146,6 @@ div.document {
}
}

/* Make tables be responsive-ish. */
@media only screen and (max-width: 680px) {
table, thead, tbody, th, td, tr {
display: block;
}
}

.toc td {
display:block;
width: 200%;
Expand Down Expand Up @@ -485,28 +477,13 @@ pre {
line-height: 120%;
margin-bottom: 1em;
padding: 5px 5px 5px 15px;
text-align: justify;
}

div.highlight pre {
border: none;
}

table.highlighttable {
display: table;
}

@media only screen and (max-width: 680px) {
table.highlighttable {
display: block;
}
}

table.highlighttable,
table.highlighttable pre {
border: none;
background-color: #eeffcc;
}

ul.simple {
list-style-type: circle;
margin-bottom: 1em;
Expand All @@ -517,8 +494,12 @@ code.descclassname, code.descname {
font-weight: bold;
}

/* Top level section title format */
div.body > div.section > dl > dt.title {
/*
Top level section title format
section tag has been introduced in docutils 0.17 as a replacement for div.section
Both rule variations are kept to support old versions of docutils
*/
div.body > section > dl > dt.title, div.body > div.section > dl > dt.title {
font-size: 120%;
font-weight: bold;
margin-bottom: 1em;
Expand Down Expand Up @@ -575,6 +556,7 @@ div.body p.small-heading {
div.body div.inlined,
div.body img.inlined-right {
float: right;
margin: 1em 0;
}

div.body .inset {
Expand All @@ -593,6 +575,10 @@ div.body span.codelineref {
background-color: {{ theme_keywordbgcolor }};
}

span.linenos {
margin-right: 15px;
}

/* Examples section: contains one or more example subsections */
div.examples > div.example {
clear: both;
Expand All @@ -618,12 +604,6 @@ div.example div.break {
height: 0;
}

/* -- parameters returns table style ---------------------------------------- */

dl.field-list > dt {
padding-right: 10px;
}

/* -- tooltip style --------------------------------------------------------- */

a.tooltip {
Expand Down Expand Up @@ -689,3 +669,35 @@ pre.commentContent {
border: 0;
white-space: pre-wrap;
}

/* -- responsive design --------------------------------------------------------- */

@media only screen and (max-width: 680px) {
/* Make tables be responsive-ish. */
table, thead, tbody, th, td, tr {
display: block;
}

div.body img.inlined-right {
float: none;
display: block;
margin: auto
}

span.linenos {
margin-right: 10px;
}

.addcomment input, a.commentButton {
font-size: 10px;
}

pre {
white-space: pre-wrap;
word-wrap: break-word;
}

.toc td {
width: 100%;
}
}

0 comments on commit 3d0d25c

Please sign in to comment.