mirror of
https://github.com/sphinx-doc/sphinx.git
synced 2025-02-25 18:55:22 -06:00
Update docs
This commit is contained in:
parent
621a4e6f61
commit
55818b7419
@ -300,7 +300,7 @@ brings to users easy setting up ways.
|
|||||||
|
|
||||||
To distribute your theme as a python package, please define an entry point
|
To distribute your theme as a python package, please define an entry point
|
||||||
called ``sphinx.html_themes`` in your setup.py file, and write a ``setup()``
|
called ``sphinx.html_themes`` in your setup.py file, and write a ``setup()``
|
||||||
function to register your themes in it::
|
function to register your themes using ``add_html_theme()`` API in it::
|
||||||
|
|
||||||
# 'setup.py'
|
# 'setup.py'
|
||||||
setup(
|
setup(
|
||||||
@ -319,6 +319,10 @@ function to register your themes in it::
|
|||||||
def setup(app):
|
def setup(app):
|
||||||
app.add_html_theme('name_of_theme', path.abspath(path.dirname(__file__)))
|
app.add_html_theme('name_of_theme', path.abspath(path.dirname(__file__)))
|
||||||
|
|
||||||
|
|
||||||
|
If your theme package contains two or more themes, please call ``add_html_theme()``
|
||||||
|
twice or more.
|
||||||
|
|
||||||
.. versionadded:: 1.2
|
.. versionadded:: 1.2
|
||||||
'sphinx_themes' entry_points feature.
|
'sphinx_themes' entry_points feature.
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user