summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex/glossaries-extra/sample-crossref2.tex
blob: abadf2b8509a19e6d284a39bcf2610cf74b076ad (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
% arara: pdflatex
% arara: makeglossaries
% arara: pdflatex
\documentclass{article}

\usepackage[nonumberlist]{glossaries-extra}

\makeglossaries

\renewcommand*{\glsxtrpostdescgeneral}{%
 \ifglshasfield{see}{\glscurrententrylabel}
 {, \glsxtrusesee{\glscurrententrylabel}}%
 {}%
 \ifglshasfield{seealso}{\glscurrententrylabel}
 { (\glsxtruseseealso{\glscurrententrylabel})}%
 {}%
}

\newglossaryentry{sample1}{name={sample 1},description={an example}}
\newglossaryentry{sample2}{name={sample 2},description={an
example},see={sample1}}
\newglossaryentry{sample3}{name={sample 3},description={an
example},see={sample2}}
\newglossaryentry{sample4}{name={sample 4},description={an
example},seealso={sample2,sample3}}

\begin{document}
\gls{sample4}.

\printglossaries

\end{document}