summaryrefslogtreecommitdiff
path: root/macros/latex/contrib/glossaries/samples/sampleAcrDesc.tex
diff options
context:
space:
mode:
Diffstat (limited to 'macros/latex/contrib/glossaries/samples/sampleAcrDesc.tex')
-rw-r--r--macros/latex/contrib/glossaries/samples/sampleAcrDesc.tex76
1 files changed, 76 insertions, 0 deletions
diff --git a/macros/latex/contrib/glossaries/samples/sampleAcrDesc.tex b/macros/latex/contrib/glossaries/samples/sampleAcrDesc.tex
new file mode 100644
index 0000000000..896bbbb1fb
--- /dev/null
+++ b/macros/latex/contrib/glossaries/samples/sampleAcrDesc.tex
@@ -0,0 +1,76 @@
+ % This file is public domain
+ % If you want to use arara, you need the following directives:
+ % arara: pdflatex: { synctex: on }
+ % arara: makeglossaries
+ % arara: pdflatex: { synctex: on }
+ % arara: pdflatex: { synctex: on }
+\documentclass[a4paper]{report}
+
+\usepackage[colorlinks,plainpages=false]{hyperref}
+\usepackage[acronym,% create 'acronym' glossary type
+ % The package option "nomain" is used here to suppress the
+ % main glossary, since this example doesn't use it. If you
+ % want to use the main glossary, remove the "nomain" option.
+ nomain,%
+ style=altlist, % use altlist style
+ toc, % add the glossary to the table of contents
+ ]{glossaries}
+
+\makeglossaries
+
+ % Change the acronym style to long-sc-short-desc:
+\setacronymstyle{long-sc-short-desc}
+
+ % Change the "see" items so that they use \acronymfont:
+\renewcommand*{\glsseeitemformat}[1]{\acronymfont{\glsentrytext{#1}}}
+
+ % Not using a font that supports bold smallcaps so change the way
+ % the name is formatted in the glossary:
+
+\renewcommand*{\glsnamefont}[1]{\textmd{#1}}
+
+\newacronym[description={Statistical pattern recognition
+technique~\protect\cite{svm}}, % acronym's description
+]{svm}{svm}{support vector machine}
+
+\newacronym
+ [description={Statistical pattern recognition technique
+ using the ``kernel trick''},% acronym's description
+ see={[see also]{svm}},
+]
+{ksvm}{ksvm}{kernel support vector machine}
+
+\begin{document}
+\tableofcontents
+
+\chapter{Support Vector Machines}
+
+The \gls{svm} is used widely in the area of pattern recognition.
+ % plural form with initial letter in uppercase:
+\Glspl{svm} are \ldots\ (but beware, converting the initial letter to
+upper case for a small caps acronym is sometimes considered
+poor style).
+
+Short version: \acrshort{svm}. Long version: \acrlong{svm}. Full
+version: \acrfull{svm}. Description: \glsentrydesc{svm}.
+
+This is the entry in uppercase: \GLS{svm}.
+
+\chapter{Kernel Support Vector Machines}
+
+The \gls{ksvm} is \ifglsused{svm}{an}{a} \gls{svm} that uses
+the so called ``kernel trick''. This is the entry's description without
+a link: \glsentrydesc{ksvm}.
+
+\glsresetall
+Possessive: \gls{ksvm}['s].
+Make the glossary entry number bold for this
+one \gls[format=hyperbf]{svm}.
+
+\begin{thebibliography}{1}
+\bibitem{svm} \ldots
+\end{thebibliography}
+
+\printglossary
+
+\end{document}