Skip to content

Commit

Permalink
comparing rendering methods
Browse files Browse the repository at this point in the history
  • Loading branch information
fredrik-1 committed Jul 20, 2018
1 parent 9b8da51 commit 80fbd53
Show file tree
Hide file tree
Showing 4 changed files with 113 additions and 5 deletions.
27 changes: 27 additions & 0 deletions doc/_templates/autoclass.rst
@@ -0,0 +1,27 @@
{{ fullname | escape | underline }}

.. currentmodule:: {{ module }}

.. autoclass:: {{ objname }}
:no-members:
:show-inheritance:

{% if '__init__' in methods %}
{% set caught_result = methods.remove('__init__') %}
{% endif %}

{% block methods %}
{% if methods %}

.. rubric:: Methods

.. autosummary::
:template: autosummary.rst
:toctree:
:nosignatures:
{% for item in methods %}
~{{ name }}.{{ item }}
{% endfor %}

{% endif %}
{% endblock %}
57 changes: 57 additions & 0 deletions doc/_templates/autoclass_onefile.rst
@@ -0,0 +1,57 @@
.. contents:: Table of Contents
:depth: 2
:local:
:backlinks: entry
:class: multicol-toc

{{ fullname | escape | underline }}

.. currentmodule:: {{ module }}

.. autoclass:: {{ objname }}
:no-members:
:show-inheritance:

{% if '__init__' in methods %}
{% set caught_result = methods.remove('__init__') %}
{% endif %}

{% block methods %}
{% if methods %}

Methods
^^^^^^^

.. autosummary::
:nosignatures:
{% for item in methods %}
~{{ name }}.{{ item }}
{% endfor %}

{% endif %}
{% endblock %}

Documentation
=============

.. autoclass:: {{ objname }}
:members:
:undoc-members:
:inherited-members:
:show-inheritance:

Examples
========

.. include:: {{module}}.{{name}}.examples
{% block examples %}
{% if members %}
{% for item in members %}
.. include:: {{module}}.{{name}}.{{item}}.examples
.. raw:: html

<div class="clearer"></div>
{% endfor %}
{% endif %}
{% endblock %}

32 changes: 28 additions & 4 deletions doc/api/collections_api.rst
Expand Up @@ -9,8 +9,32 @@ collections
:mod:`matplotlib.collections`
=============================

.. currentmodule:: matplotlib.collections

.. automodule:: matplotlib.collections
:members:
:undoc-members:
:show-inheritance:
:inherited-members:
:no-members:

Classes
-------

.. autosummary::
:toctree: _as_gen/
:template: autoclass.rst
:nosignatures:

AsteriskPolygonCollection
BrokenBarHCollection
CircleCollection
Collection
EllipseCollection
EventCollection
LineCollection
PatchCollection
PathCollection
PolyCollection
QuadMesh
RegularPolyCollection
StarPolygonCollection
TriMesh


2 changes: 1 addition & 1 deletion doc/api/figure_api.rst
Expand Up @@ -17,7 +17,7 @@ Classes

.. autosummary::
:toctree: _as_gen/
:template: autosummary.rst
:template: autoclass_onefile.rst
:nosignatures:

AxesStack
Expand Down

0 comments on commit 80fbd53

Please sign in to comment.