File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -986,7 +986,7 @@ div.sphx-glr-download a {
986986 background-image : none !important ;
987987}
988988
989- p .sphx-glr-signature a . reference . external {
989+ p .sphx-glr-signature {
990990 display : none !important ;
991991}
992992
Original file line number Diff line number Diff line change 1717import matplotlib
1818import sphinx
1919
20+ # This is only necessary to monkey patch the signature later on.
21+ from sphinx_gallery import gen_rst
22+
2023# If your extensions are in another directory, add it here. If the directory
2124# is relative to the documentation root, use os.path.abspath to make it
2225# absolute, like shown here.
@@ -132,6 +135,16 @@ def _check_deps():
132135
133136plot_gallery = 'True'
134137
138+ # Monkey-patching gallery signature to include search keywords
139+ gen_rst .SPHX_GLR_SIG = """\n
140+ .. only:: html
141+
142+ .. rst-class:: sphx-glr-signature
143+
144+ Keywords: matplotlib code example, codex, python plot, pyplot
145+ `Gallery generated by Sphinx-Gallery
146+ <https://sphinx-gallery.readthedocs.io>`_\n """
147+
135148# Add any paths that contain templates here, relative to this directory.
136149templates_path = ['_templates' ]
137150
You can’t perform that action at this time.
0 commit comments