No Description

miili 2dd740ad7e bugfix sphinx GAttribute 1 year ago
src 2dd740ad7e bugfix sphinx GAttribute 1 year ago
tests 640d8926e4 Bump version: 2.3.2 → 2.4.0 3 years ago
.bumpversion.cfg 640d8926e4 Bump version: 2.3.2 → 2.4.0 3 years ago
.cookiecutterrc e83951ea25 Update skel. Add some mock docs for testing. 4 years ago
.gitignore e83951ea25 Update skel. Add some mock docs for testing. 4 years ago
.travis.yml b293215dfb Force fetch the ghpages branch before. 4 years ago
AUTHORS.rst e234088779 Update changelog. 3 years ago
CHANGELOG.rst e234088779 Update changelog. 3 years ago
CONTRIBUTING.rst e83951ea25 Update skel. Add some mock docs for testing. 4 years ago
LICENSE d90aeb2210 Upgrade project skel. 5 years ago
MANIFEST.in 50bd06442e Add publish to github pages configuration to make it easy to preview changes. 4 years ago
README.rst 0bb6bbbb8a added piwik tracking code 2 years ago
publish-key.enc 50bd06442e Add publish to github pages configuration to make it easy to preview changes. 4 years ago
setup.cfg e83951ea25 Update skel. Add some mock docs for testing. 4 years ago
setup.py 13fc367154 Renaming to `sphinx_sleekcat_theme` 3 years ago
tox.ini c044358a93 Don't install anything in these envs (builds faster). 4 years ago

README.rst

==============================================
Enhanced Sphinx theme (based on Python 3 docs)
==============================================

Theme customized for https://pyrocko.org

!! Includes pyrocko piwik tracking code !!

.. list-table::
:stub-columns: 1

* - docs
- |docs|
* - tests
- | |travis|
* - demo
- `default `_,
`bare `_
* - package
- |version| |downloads|

.. |docs| image:: https://readthedocs.org/projects/sphinx-py3doc-enhanced-theme/badge/?style=flat
:target: https://readthedocs.org/projects/sphinx-py3doc-enhanced-theme
:alt: Documentation Status

.. |travis| image:: http://img.shields.io/travis/ionelmc/sphinx-py3doc-enhanced-theme/master.svg?style=flat&label=Travis
:alt: Travis-CI Build Status
:target: https://travis-ci.org/ionelmc/sphinx-py3doc-enhanced-theme

.. |version| image:: http://img.shields.io/pypi/v/sphinx-py3doc-enhanced-theme.svg?style=flat
:alt: PyPI Package latest release
:target: https://pypi.python.org/pypi/sphinx-py3doc-enhanced-theme

.. |downloads| image:: http://img.shields.io/pypi/dm/sphinx-py3doc-enhanced-theme.svg?style=flat
:alt: PyPI Package monthly downloads
:target: https://pypi.python.org/pypi/sphinx-py3doc-enhanced-theme

A theme based on https://github.com/ionelmc/sphinx-py3doc-enhanced-theme

* Free software: BSD license

Installation
============

::

pip install sphinx_sleekcat_theme

Add this in your documentation's ``conf.py``:

.. sourcecode:: python

import sphinx_sleekcat_theme
html_theme = "sphinx_sleekcat_theme"
html_theme_path = [sphinx_sleekcat_theme.get_html_theme_path()]

Customization
=============

No extra styling
----------------

This theme has some extra styling like different fonts, text shadows for headings, slightly different styling for inline code and code blocks.

To get the original styling Python 3 docs have add this in you ``conf.py``:

.. sourcecode:: python

html_theme_options = {
'githuburl': 'https://github.com/pyrocko/pyrocko/',
'bodyfont': '"Lucida Grande",Arial,sans-serif',
'headfont': '"Lucida Grande",Arial,sans-serif',
'codefont': 'monospace,sans-serif',
'linkcolor': '#0072AA',
'visitedlinkcolor': '#6363bb',
'extrastyling': False,
'googlewebfonturl': 'http://fonts.googleapis.com/css?family=Rubik+One|Kalam',
'fontawesome': 'https://use.fontawesome.com/d51e5252e5.js',
}
pygments_style = 'friendly'

Custom favicon
--------------

To have a custom favicon create a ``theme`` directory near your ``conf.py`` and add this ``theme.conf`` in it:

.. sourcecode:: ini

[theme]
inherit = sphinx_sleekcat_theme

Then create a ``favicon.png`` in the ``static`` directory.

And then edit your ``conf.py`` to have something like this:

.. sourcecode:: python

import sphinx_sleekcat_theme
html_theme = "theme"
html_theme_path = [sphinx_sleekcat_theme.get_html_theme_path(), "."]

The final file structure should be like this::

docs
├── conf.py
└── theme
├── static
│   └── favicon.png
└── theme.conf

A bit of extra css
------------------

.. sourcecode:: python

html_theme_options = {
'appendcss': 'div.body code.descclassname { display: none }',
}

Examples
========

* http://python-aspectlib.readthedocs.org/en/latest/
* http://python-manhole.readthedocs.org/en/latest/