Package: pylons-sphinx-themes
Pylons Sphinx ThemesThis repository is a Python package that contains Sphinx themes for Pylons related projects. This project is based onPylons Sphinx Theme(singular), but uses a package implementation instead of git submodules and manual steps.To use a theme in your Sphinx documentation, follow this guide.Edit your project’ssetup.pyAddpylons-sphinx-themesto your project’s requirements in itssetup.py.
Here’s an example from Pyramid.docs_extras=['Sphinx >= 1.7.5',# Read The Docs minimum version'docutils','repoze.sphinx.autointerface','pylons-sphinx-themes',]Edit your Sphinx’sconf.pyNear the top, add the following.importpylons_sphinx_themesActivate the theme.html_theme='pyramid'html_theme_path=pylons_sphinx_themes.get_html_themes_path()(Recommended) EnableEthical Ads.
Doing so supports bothRead the Docsand thePython Software Foundationwith ad revenue.# Control display of sidebarshtml_sidebars={'**':['localtoc.html','ethicalads.html','relations.html','sourcelink.html','searchbox.html',]}If you were previously using the git submodule method to use the Pylons theme, then comment or delete the block of code under the following statement.# Add and use Pylons themeif'sphinx-build'in' '.join(sys.argv):# protect against dumb importers(Optional) Set a canonical root URL.
The URL points to the root of the documentation, and requires a trailing slash.html_theme_options=dict(canonical_url='http://the_root_domain/latest/docs/')Undo git submodule methodIf you were previously using the git submodule method to use the Pylons theme, then perform the following additional steps.Remove.gitmodules.cd<your_project_directory>gitrm.gitmodulesDeinitialize the submodule.cddocs/_themesgitsubmoduledeinit.Remove the submodule’s directory.cd..gitrm_themes/Edit your Sphinx’sMakefile. The following is anexample difffrom Pyramid.-html: themes+html:# ...-htmlhelp: themes+htmlhelp:#...-themes:-    cd ..; git submodule update --init --recursive; cd docs;Updatetox.iniIf you use tox, you can specify dependencies for building your docs either in yoursetup.py(preferred) or in yourtox.ini(duplicitous). See theexample from Pyramid.docs_extras=['Sphinx >=1.7.5','docutils','repoze.sphinx.autointerface','pylons_sphinx_latesturl','pylons-sphinx-themes',]# ...extras_require={'testing':testing_extras,'docs':docs_extras,},Otherwise you can repeat yourself and edit yourtox.ini. The following example is fromwaitress.deps=Sphinxrepoze.sphinx.autointerfacepylons-sphinx-themesUpdate Read the Docs configurationIf you specify package requirements for Read the Docs, specify dependencies in yourrtd.txt. You can either name them explicitly, which might be duplicitous:pylons-sphinx-themesor you can rely on yoursetup.pyconfiguration, specifying dependencies in only one place, by simply using this in yourrtd.txt.-e .[docs]Available themespylons- the generic Pylons Project documentation themepyramid- the specific Pyramid documentation themepylonsfw- the specific Pylons Framework documentation themeChange log for pylons-sphinx-themes1.0.13 (2020-11-30)Revert fix of linenos in tables. Sphinx fixed this issue in v3.0. RTD rolled
it out as a feature flag in April 2020, and it now appears to be rolling out
in more projects.Add padding to the top oflinenodivto align with code in tables and its
extra 2px top border.1.0.12 (2020-11-28)Added style.wy-table-responsive{overflow-x:scroll; }to prevent
tables from blowout by long dotted method names.1.0.11 (2020-01-13)Fix the width of linenos table column when used in code-blocks.1.0.10 (2018-09-25)Add Read the Docs to the recipients of ad revenue.1.0.9 (2018-09-23)Remove hyphenation because it sometimes hyphenates inappropriately, such as
in code.1.0.8 (2018-09-21)Fix support for Ethical Ads.1.0.7 (2018-09-21)Added support for Ethical Ads for Read The Docs. Seehttps://github.com/Pylons/pylons-sphinx-themes/pull/121.0.6 (2017-09-22)Update zest.releaser in order to release to PyPI.1.0.5 (2017-09-22)Clean up licensinghttps://github.com/Pylons/pylons-sphinx-themes/issues/81.0.4 (2017-06-20)Specify line spacing for list items for only within the .body class.1.0.3 (2017-06-20)Add line spacing for list items. Closes #4.1.0.2 (2017-06-16)Remove HTTPS protocol to allow either HTTPS or HTTP.1.0.1 (2017-06-16)Use HTTPS for protocol of stylesheets.1.0 (2017-04-18)Use zest.releaser for releasing.Improve documentation.0.3.1 (2015-04-15)Improve documentation.0.3 (2015-04-15)Convert from using git submodule used inhttps://github.com/Pylons/pylons_sphinx_themeto a package. Seehttps://github.com/Pylons/pyramid/issues/1614Initial commit.