Skip to content

Commit

Permalink
DOC: Explain leading dot in object references
Browse files Browse the repository at this point in the history
  • Loading branch information
timhoffm committed Mar 19, 2024
1 parent 6378d48 commit 2b5bb79
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion doc/devel/document.rst
Original file line number Diff line number Diff line change
Expand Up @@ -317,7 +317,10 @@ target is unambiguous you can simply leave them out:
`.LineCollection`
and the link still works: `.LineCollection`.
and the link still works: `.LineCollection`. Note that you should typically include
the leading dot. It tells Sphinx to look for the given name in the whole project.
See also the explanation at `Sphinx: Cross-referencing Python objects
<https://www.sphinx-doc.org/en/master/usage/domains/python.html#cross-referencing-python-objects>`_.

If there are multiple code elements with the same name (e.g. ``plot()`` is a
method in multiple classes), you'll have to extend the definition:
Expand Down

0 comments on commit 2b5bb79

Please sign in to comment.