diff options
Diffstat (limited to 'macros/latex/contrib/postnotes/postnotes.tex')
-rw-r--r-- | macros/latex/contrib/postnotes/postnotes.tex | 46 |
1 files changed, 28 insertions, 18 deletions
diff --git a/macros/latex/contrib/postnotes/postnotes.tex b/macros/latex/contrib/postnotes/postnotes.tex index c47a9d9cdf..e9fa40b215 100644 --- a/macros/latex/contrib/postnotes/postnotes.tex +++ b/macros/latex/contrib/postnotes/postnotes.tex @@ -157,6 +157,16 @@ \ExplSyntaxOff \NewDocumentCommand\opt{m}{\texttt{#1}} +% Temporary workaround for 'l3doc' bug. +% https://github.com/latex3/latex3/issues/1111 +% FIXME Remove when fixed upstream. +\NewDocElement[ + macrolike = false , + printtype = \textit{opt.} , +]{Option}{optiondesc} +\NewDocElement[ + macrolike = true , +]{UserMacro}{usermacro} \begin{document} @@ -321,7 +331,7 @@ receives options and values in \texttt{key=value} fashion. \bigskip{} \DescribeOption{heading} % -\DescribeOption{\cs{pnheading}} % +\DescribeUserMacro{\pnheading} % The \opt{heading} option sets the heading for the printed notes or, more generally put, that which is printed at the beginning of \cs{printpostnotes}. Its default value depends on the document class in use. If \cs{chapter} is @@ -364,7 +374,7 @@ different than the defaults. \DescribeOption{makemark} % \DescribeOption{maketextmark} % -\DescribeOption{\cs{pnthepage}} % +\DescribeUserMacro{\pnthepage} % The \opt{makemark} and \opt{maketextmark} options control how the mark is to be typeset, at the point \cs{postnote} is called and at the point the note's text is printed at \cs{printpostnotes}, respectively. They both can receive @@ -520,10 +530,10 @@ case, but be able to override it manually for an occasional unnumbered one. For this reason, a more semantic name was chosen for it, instead of the generic ``add to''. -\DescribeOption{\cs{pnthechapter}} % -\DescribeOption{\cs{pnthesection}} % -\DescribeOption{\cs{pnthechapternextnote}} % -\DescribeOption{\cs{pnthesectionnextnote}} % +\DescribeUserMacro{\pnthechapter} % +\DescribeUserMacro{\pnthesection} % +\DescribeUserMacro{\pnthechapternextnote} % +\DescribeUserMacro{\pnthesectionnextnote} % Just like with \cs{postnote}, the contents of \cs{postnotesection} are not expanded in place, but rather stored with ``no manipulation'' to be typeset later at \cs{printpostnotes}. For this reason, some contextual information is @@ -679,14 +689,14 @@ part of the definition: \ExplSyntaxOff \end{pnsnippet} -\DescribeOption{\cs{pnhdpagefirst}} % -\DescribeOption{\cs{pnhdpagelast}} % -\DescribeOption{\cs{pnhdchapfirst}} % -\DescribeOption{\cs{pnhdchaplast}} % -\DescribeOption{\cs{pnhdsectfirst}} % -\DescribeOption{\cs{pnhdsectlast}} % -\DescribeOption{\cs{pnhdnamefirst}} % -\DescribeOption{\cs{pnhdnamelast}} % +\DescribeUserMacro{\pnhdpagefirst} % +\DescribeUserMacro{\pnhdpagelast} % +\DescribeUserMacro{\pnhdchapfirst} % +\DescribeUserMacro{\pnhdchaplast} % +\DescribeUserMacro{\pnhdsectfirst} % +\DescribeUserMacro{\pnhdsectlast} % +\DescribeUserMacro{\pnhdnamefirst} % +\DescribeUserMacro{\pnhdnamelast} % \cs{pnhdpagefirst} and \cs{pnhdpagelast} store the value of \cs{thepage} for the first and the last notes (where these notes were originally placed) of the current page (at the point they are being printed). These variables are @@ -810,10 +820,10 @@ places, etc. \section{Localization} \zlabel{sec:localization} -\DescribeOption{\cs{pntitle}} % -\DescribeOption{\cs{pnhdnotes}} % -\DescribeOption{\cs{pnhdtopage}} % -\DescribeOption{\cs{pnhdtopages}} % +\DescribeUserMacro{\pntitle} % +\DescribeUserMacro{\pnhdnotes} % +\DescribeUserMacro{\pnhdtopage} % +\DescribeUserMacro{\pnhdtopages} % \pkg{postnotes} uses a few localized strings, stored in the variables \cs{pntitle}, \cs{pnhdnotes}, \cs{pnhdtopage}, and \cs{pnhdtopages}. The first one is used in the default value of the \opt{heading} option and |