docgen: implement doc link resolution in current module (#18642)
This commit is contained in:
parent
c80e2c1736
commit
7ba2659f73
24 changed files with 1833 additions and 143 deletions
|
|
@ -56,6 +56,17 @@ $seeSrc
|
|||
</div>
|
||||
"""
|
||||
|
||||
# A wrapper of a few overloaded `doc.item`s with the same basic name
|
||||
# * $header_plain - see above
|
||||
# * $overloadGroupName - the anchor for this whole group
|
||||
# * $content - string containing `doc.item`s themselves
|
||||
doc.item2 = """
|
||||
|
||||
<div id="$overloadGroupName">
|
||||
$content
|
||||
</div>
|
||||
"""
|
||||
|
||||
# Chunk of HTML emitted for each entry in the HTML table of contents.
|
||||
# See doc.item for available substitution variables.
|
||||
|
||||
|
|
|
|||
|
|
@ -19,7 +19,8 @@ doc.section.toc = ""
|
|||
doc.item = """
|
||||
|
||||
\vspace{1em}
|
||||
\phantomsection\addcontentsline{toc}{subsection}{$uniqueName}
|
||||
\phantomsection\addcontentsline{toc}{subsubsection}{$uniqueName}
|
||||
\label{$itemSymOrID}\hypertarget{$itemSymOrID}{}
|
||||
|
||||
\begin{rstdocitem}
|
||||
$header
|
||||
|
|
@ -30,6 +31,13 @@ $desc
|
|||
\end{addmargin}
|
||||
"""
|
||||
|
||||
doc.item2 = """
|
||||
\phantomsection\addcontentsline{toc}{subsection}{$header_plain}
|
||||
\label{$overloadGroupName}\hypertarget{$overloadGroupName}{}
|
||||
|
||||
$content
|
||||
"""
|
||||
|
||||
doc.item.toc = ""
|
||||
|
||||
doc.toc = r"\tableofcontents \newpage"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue