mirror of
https://github.com/ThePhD/sol2.git
synced 2024-03-22 13:10:44 +08:00
Merge branch 'linkcolors-autodoc' of github.com:tony/sphinx_rtd_theme into tony-linkcolors-autodoc
This commit is contained in:
commit
e9ec0f8332
|
@ -60,6 +60,27 @@ The first hexagram is made up of six unbroken lines. These unbroken lines stand
|
|||
|
||||
The power represented by the hexagram is to be interpreted in a dual sense in terms of its action on the universe and of its action on the world of men. In relation to the universe, the hexagram expresses the strong, creative action of the Deity. In relation to the human world, it denotes the creative action of the holy man or sage, of the ruler or leader of men, who through his power awakens and develops their higher nature.
|
||||
|
||||
Inline code and references
|
||||
==========================
|
||||
|
||||
`reStructuredText`_ is a markup language. It can use roles and
|
||||
declarations to turn reST into HTML.
|
||||
|
||||
In reST, ``*hello world*`` becomes ``<em>hello world</em>``. This is
|
||||
because a library called `Docutils`_ was able to parse the reST and use a
|
||||
``Writer`` to output it that way.
|
||||
|
||||
If I type ````an inline literal```` it will wrap it in ``<tt>``. You can
|
||||
see more details on the `Inline Markup`_ on the Docutils homepage.
|
||||
|
||||
Also with ``sphinx.ext.autodoc``, which I use in the demo, I can link to
|
||||
:class:`test_py_module.test.Foo`. It will link you right my code
|
||||
documentation for it.
|
||||
|
||||
.. _reStructuredText: http://docutils.sourceforge.net/rst.html
|
||||
.. _Docutils: http://docutils.sourceforge.net/
|
||||
.. _Inline Markup: http://docutils.sourceforge.net/docs/ref/rst/restructuredtext.html#inline-markup
|
||||
|
||||
Citation
|
||||
========
|
||||
|
||||
|
|
|
@ -1,7 +1,31 @@
|
|||
# -*- coding: utf-8 -*-
|
||||
"""Test Module for sphinx_rtd_theme."""
|
||||
|
||||
class Foo:
|
||||
"""Docstring for class Foo."""
|
||||
|
||||
r"""Docstring for class Foo.
|
||||
|
||||
This text tests for the formatting of docstrings generated from output
|
||||
``sphinx.ext.autodoc``. Which contain reST, but sphinx nests it in the
|
||||
``<dl>``, and ``<dt>`` tags. Also, ``<tt>`` is used for class, method names
|
||||
and etc, but those will *always* have the ``.descname`` or
|
||||
``.descclassname`` class.
|
||||
|
||||
Normal ``<tt>`` (like the <tt> I just wrote here) needs to be shown with
|
||||
the same style as anything else with ````this type of markup````.
|
||||
|
||||
It's common for programmers to give a code example inside of their
|
||||
docstring::
|
||||
|
||||
from test_py_module import Foo
|
||||
|
||||
myclass = Foo()
|
||||
myclass.dothismethod('with this argument')
|
||||
myclass.flush()
|
||||
|
||||
print(myclass)
|
||||
|
||||
"""
|
||||
|
||||
#: Doc comment for class attribute Foo.bar.
|
||||
#: It can have multiple lines.
|
||||
|
|
|
@ -108,12 +108,12 @@
|
|||
.field-body
|
||||
text-align: left
|
||||
padding-left: 0
|
||||
// This is seen in sphinx.ext.autodoc output
|
||||
dl
|
||||
dt
|
||||
@extend code
|
||||
display: inline-block
|
||||
margin: $base-line-height / 4 0
|
||||
font-size: 80%
|
||||
font-size: 90%
|
||||
line-height: normal
|
||||
background: $gray-lighter
|
||||
color: $gray-dark
|
||||
|
@ -123,34 +123,54 @@
|
|||
.headerlink
|
||||
color: $text-color
|
||||
font-size: 100% !important
|
||||
.descname, .descclassname, big, em
|
||||
font-size: 100% !important
|
||||
line-height: normal
|
||||
|
||||
|
||||
dt:first-child
|
||||
margin-top: 0
|
||||
dd
|
||||
margin-left: $base-line-height
|
||||
|
||||
tt // for sphinx.ext.autodoc generated content
|
||||
&.descname, &.descclassname
|
||||
background-color: transparent
|
||||
&.descname
|
||||
font-weight: bold
|
||||
padding-right: 0.08em
|
||||
|
||||
dl dl
|
||||
dt
|
||||
@extend code
|
||||
display: inline-block
|
||||
margin-bottom: $base-line-height / 4
|
||||
font-size: 80%
|
||||
line-height: normal
|
||||
font-size: 90%
|
||||
background: none
|
||||
border: none
|
||||
|
||||
.headerlink
|
||||
color: $text-color
|
||||
font-size: 100% !important
|
||||
|
||||
// reST for ``inline code`` statements
|
||||
// This does a few things to make inline code easier to read
|
||||
// Even though the font size of $code-font-family is same as normal font
|
||||
// it looks huge compared to it, so lets trial with it @ 90%.
|
||||
tt
|
||||
background-color: $table-stripe-color
|
||||
font-family: $code-font-family
|
||||
&.literal
|
||||
@extend code
|
||||
font-size: 90%
|
||||
padding: 1px, 2px
|
||||
|
||||
big, em
|
||||
font-size: 100% !important
|
||||
line-height: normal
|
||||
|
||||
.xref, a &
|
||||
font-weight: bold
|
||||
|
||||
blockquote
|
||||
margin-left: $base-line-height
|
||||
line-height: $base-line-height
|
||||
margin-bottom: $base-line-height
|
||||
|
||||
|
||||
#search-results
|
||||
.search li
|
||||
margin-bottom: $base-line-height
|
||||
|
|
|
@ -1 +1,236 @@
|
|||
*{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}.font-smooth,.icon:before{-webkit-font-smoothing:antialiased}.clearfix{*zoom:1}.clearfix:before,.clearfix:after{display:table;content:""}.clearfix:after{clear:both}@font-face{font-family:fontawesome-webfont;font-weight:normal;font-style:normal;src:url("../font/fontawesome_webfont.eot");src:url("../font/fontawesome_webfont.eot?#iefix") format("embedded-opentype"),url("../font/fontawesome_webfont.woff") format("woff"),url("../font/fontawesome_webfont.ttf") format("truetype"),url("../font/fontawesome_webfont.svg#fontawesome-webfont") format("svg")}.icon:before{display:inline-block;font-family:fontawesome-webfont;font-style:normal;font-weight:normal;line-height:1;text-decoration:inherit}a .icon{display:inline-block;text-decoration:inherit}li .icon{display:inline-block}li .icon-large:before,li .icon-large:before{width:1.875em}ul.icons{list-style-type:none;margin-left:2em;text-indent:-0.8em}ul.icons li .icon{width:0.8em}ul.icons li .icon-large:before,ul.icons li .icon-large:before{vertical-align:baseline}.icon-book:before{content:"\f02d"}.icon-caret-down:before{content:"\f0d7"}.icon-caret-up:before{content:"\f0d8"}.icon-caret-left:before{content:"\f0d9"}.icon-caret-right:before{content:"\f0da"}.rst-versions{position:fixed;bottom:0;left:0;width:300px;color:#fcfcfc;background:#1f1d1d;border-top:solid 10px #343131;font-family:"Lato","proxima-nova","Helvetica Neue",Arial,sans-serif;z-index:400}.rst-versions a{color:#2980b9;text-decoration:none}.rst-versions .rst-badge-small{display:none}.rst-versions .rst-current-version{padding:12px;background-color:#272525;display:block;text-align:right;font-size:90%;cursor:pointer;color:#27ae60;*zoom:1}.rst-versions .rst-current-version:before,.rst-versions .rst-current-version:after{display:table;content:""}.rst-versions .rst-current-version:after{clear:both}.rst-versions .rst-current-version .icon{color:#fcfcfc}.rst-versions .rst-current-version .icon-book{float:left}.rst-versions .rst-current-version.rst-out-of-date{background-color:#e74c3c;color:#fff}.rst-versions.shift-up .rst-other-versions{display:block}.rst-versions .rst-other-versions{font-size:90%;padding:12px;color:gray;display:none}.rst-versions .rst-other-versions hr{display:block;height:1px;border:0;margin:20px 0;padding:0;border-top:solid 1px #413d3d}.rst-versions .rst-other-versions dd{display:inline-block;margin:0}.rst-versions .rst-other-versions dd a{display:inline-block;padding:6px;color:#fcfcfc}.rst-versions.rst-badge{width:auto;bottom:20px;right:20px;left:auto;border:none;max-width:300px}.rst-versions.rst-badge .icon-book{float:none}.rst-versions.rst-badge.shift-up .rst-current-version{text-align:right}.rst-versions.rst-badge.shift-up .rst-current-version .icon-book{float:left}.rst-versions.rst-badge .rst-current-version{width:auto;height:30px;line-height:30px;padding:0 6px;display:block;text-align:center}@media screen and (max-width: 768px){.rst-versions{width:85%;display:none}.rst-versions.shift{display:block}img{width:100%;height:auto}}
|
||||
/* line 2, /home/tony/workspace/sphinx_rtd_theme/bower_components/neat/app/assets/stylesheets/grid/_grid.scss */
|
||||
* {
|
||||
-webkit-box-sizing: border-box;
|
||||
-moz-box-sizing: border-box;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
/* line 70, /home/tony/workspace/sphinx_rtd_theme/bower_components/wyrm/sass/wyrm_core/_mixin.sass */
|
||||
.font-smooth, .icon:before {
|
||||
-webkit-font-smoothing: antialiased;
|
||||
}
|
||||
|
||||
/* line 124, /home/tony/workspace/sphinx_rtd_theme/bower_components/wyrm/sass/wyrm_core/_mixin.sass */
|
||||
.clearfix {
|
||||
*zoom: 1;
|
||||
}
|
||||
/* line 117, /home/tony/workspace/sphinx_rtd_theme/bower_components/wyrm/sass/wyrm_core/_mixin.sass */
|
||||
.clearfix:before, .clearfix:after {
|
||||
display: table;
|
||||
content: "";
|
||||
}
|
||||
/* line 121, /home/tony/workspace/sphinx_rtd_theme/bower_components/wyrm/sass/wyrm_core/_mixin.sass */
|
||||
.clearfix:after {
|
||||
clear: both;
|
||||
}
|
||||
|
||||
@font-face {
|
||||
font-family: fontawesome-webfont;
|
||||
font-weight: normal;
|
||||
font-style: normal;
|
||||
src: url("../font/fontawesome_webfont.eot");
|
||||
src: url("../font/fontawesome_webfont.eot?#iefix") format("embedded-opentype"), url("../font/fontawesome_webfont.woff") format("woff"), url("../font/fontawesome_webfont.ttf") format("truetype"), url("../font/fontawesome_webfont.svg#fontawesome-webfont") format("svg");
|
||||
}
|
||||
|
||||
/* line 5, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge_fa.sass */
|
||||
.icon:before {
|
||||
display: inline-block;
|
||||
font-family: fontawesome-webfont;
|
||||
font-style: normal;
|
||||
font-weight: normal;
|
||||
line-height: 1;
|
||||
text-decoration: inherit;
|
||||
}
|
||||
|
||||
/* line 14, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge_fa.sass */
|
||||
a .icon {
|
||||
display: inline-block;
|
||||
text-decoration: inherit;
|
||||
}
|
||||
|
||||
/* line 20, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge_fa.sass */
|
||||
li .icon {
|
||||
display: inline-block;
|
||||
}
|
||||
/* line 22, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge_fa.sass */
|
||||
li .icon-large:before,
|
||||
li .icon-large:before {
|
||||
/* 1.5 increased font size for icon-large * 1.25 width */
|
||||
width: 1.875em;
|
||||
}
|
||||
|
||||
/* line 27, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge_fa.sass */
|
||||
ul.icons {
|
||||
list-style-type: none;
|
||||
margin-left: 2em;
|
||||
text-indent: -0.8em;
|
||||
}
|
||||
/* line 32, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge_fa.sass */
|
||||
ul.icons li .icon {
|
||||
width: 0.8em;
|
||||
}
|
||||
/* line 34, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge_fa.sass */
|
||||
ul.icons li .icon-large:before,
|
||||
ul.icons li .icon-large:before {
|
||||
/* 1.5 increased font size for icon-large * 1.25 width */
|
||||
vertical-align: baseline;
|
||||
}
|
||||
|
||||
/* line 40, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge_fa.sass */
|
||||
.icon-book:before {
|
||||
content: "\f02d";
|
||||
}
|
||||
|
||||
/* line 43, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge_fa.sass */
|
||||
.icon-caret-down:before {
|
||||
content: "\f0d7";
|
||||
}
|
||||
|
||||
/* line 46, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge_fa.sass */
|
||||
.icon-caret-up:before {
|
||||
content: "\f0d8";
|
||||
}
|
||||
|
||||
/* line 49, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge_fa.sass */
|
||||
.icon-caret-left:before {
|
||||
content: "\f0d9";
|
||||
}
|
||||
|
||||
/* line 52, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge_fa.sass */
|
||||
.icon-caret-right:before {
|
||||
content: "\f0da";
|
||||
}
|
||||
|
||||
/* line 1, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions {
|
||||
position: fixed;
|
||||
bottom: 0;
|
||||
left: 0;
|
||||
width: 300px;
|
||||
color: #fcfcfc;
|
||||
background: #1f1d1d;
|
||||
border-top: solid 10px #343131;
|
||||
font-family: "Lato", "proxima-nova", "Helvetica Neue", Arial, sans-serif;
|
||||
z-index: 400;
|
||||
}
|
||||
/* line 11, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions a {
|
||||
color: #2980b9;
|
||||
text-decoration: none;
|
||||
}
|
||||
/* line 14, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions .rst-badge-small {
|
||||
display: none;
|
||||
}
|
||||
/* line 16, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions .rst-current-version {
|
||||
padding: 12px;
|
||||
background-color: #272525;
|
||||
display: block;
|
||||
text-align: right;
|
||||
font-size: 90%;
|
||||
cursor: pointer;
|
||||
color: #27ae60;
|
||||
*zoom: 1;
|
||||
}
|
||||
/* line 117, /home/tony/workspace/sphinx_rtd_theme/bower_components/wyrm/sass/wyrm_core/_mixin.sass */
|
||||
.rst-versions .rst-current-version:before, .rst-versions .rst-current-version:after {
|
||||
display: table;
|
||||
content: "";
|
||||
}
|
||||
/* line 121, /home/tony/workspace/sphinx_rtd_theme/bower_components/wyrm/sass/wyrm_core/_mixin.sass */
|
||||
.rst-versions .rst-current-version:after {
|
||||
clear: both;
|
||||
}
|
||||
/* line 25, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions .rst-current-version .icon {
|
||||
color: #fcfcfc;
|
||||
}
|
||||
/* line 27, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions .rst-current-version .icon-book {
|
||||
float: left;
|
||||
}
|
||||
/* line 29, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions .rst-current-version.rst-out-of-date {
|
||||
background-color: #e74c3c;
|
||||
color: white;
|
||||
}
|
||||
/* line 32, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions.shift-up .rst-other-versions {
|
||||
display: block;
|
||||
}
|
||||
/* line 34, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions .rst-other-versions {
|
||||
font-size: 90%;
|
||||
padding: 12px;
|
||||
color: gray;
|
||||
display: none;
|
||||
}
|
||||
/* line 39, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions .rst-other-versions hr {
|
||||
display: block;
|
||||
height: 1px;
|
||||
border: 0;
|
||||
margin: 20px 0;
|
||||
padding: 0;
|
||||
border-top: solid 1px #413d3d;
|
||||
}
|
||||
/* line 46, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions .rst-other-versions dd {
|
||||
display: inline-block;
|
||||
margin: 0;
|
||||
}
|
||||
/* line 49, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions .rst-other-versions dd a {
|
||||
display: inline-block;
|
||||
padding: 6px;
|
||||
color: #fcfcfc;
|
||||
}
|
||||
/* line 53, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions.rst-badge {
|
||||
width: auto;
|
||||
bottom: 20px;
|
||||
right: 20px;
|
||||
left: auto;
|
||||
border: none;
|
||||
max-width: 300px;
|
||||
}
|
||||
/* line 60, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions.rst-badge .icon-book {
|
||||
float: none;
|
||||
}
|
||||
/* line 62, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions.rst-badge.shift-up .rst-current-version {
|
||||
text-align: right;
|
||||
}
|
||||
/* line 64, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions.rst-badge.shift-up .rst-current-version .icon-book {
|
||||
float: left;
|
||||
}
|
||||
/* line 66, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions.rst-badge .rst-current-version {
|
||||
width: auto;
|
||||
height: 30px;
|
||||
line-height: 30px;
|
||||
padding: 0 6px;
|
||||
display: block;
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
@media screen and (max-width: 768px) {
|
||||
/* line 75, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions {
|
||||
width: 85%;
|
||||
display: none;
|
||||
}
|
||||
/* line 78, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
.rst-versions.shift {
|
||||
display: block;
|
||||
}
|
||||
|
||||
/* line 80, /home/tony/workspace/sphinx_rtd_theme/sass/_theme_badge.sass */
|
||||
img {
|
||||
width: 100%;
|
||||
height: auto;
|
||||
}
|
||||
}
|
||||
|
|
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue
Block a user