Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

glossaries package and footnote in LaTeX

I am currently stuck, having two separate glossaries: main & acronyms. Acronyms glossary prints footnotes on first use in the text, but main glossary does not. Is there any way to make any other glossary than acronyms to print footnote on first use of the term? I don't get how to do it.

Here is the code example compiled with TeXnic Center and MiKTeX 2.7:

\documentclass{article}
\usepackage{index}
\usepackage[toc,style=long3colheaderborder,footnote,acronym]{glossaries} 

\makeindex 
\makeglossaries


\newglossaryentry{appdomain}{name={application domain}, description={app Domain Description...}}
\newglossaryentry{sample}{name={[has been inserted aaa]},description={testing testing 123}}

\newacronym{aca}{aca}{a contrived acronym}

\begin{document}
\section{this is a test section}
This is the test line... a \gls{sample} \gls{appdomain} 
\index{entry} and \gls{aca}
\thispagestyle{empty}\cleardoublepage

\printglossary[type=main,title={Glossary},toctitle={Glossary}]
\thispagestyle{empty}\cleardoublepage
\printglossary[type=\acronymtype,title={List of Abbreviations},toctitle={List of Abbreviations}]

\printindex
\thispagestyle{empty}\cleardoublepage
\end{document}

I want sample and appdomain either contain a footnote with description or a footnote stating: please refer to Glossary

Many thanks,
Ovanes

like image 611
ovanes Avatar asked Oct 27 '09 19:10

ovanes


1 Answers

In short, with the glossaries package, you can't get footnotes on the first use for non-acronym glossaries.

However, you can redefine some commands in the preamble (after you \usepackage{glossaries}) to get what you want:

\makeatletter
\renewcommand{\gls@main@displayfirst}[4]{
  #1#4\protect\footnote{#2}
}
\makeatother

But that will be really fragile.

like image 185
Rupert Nash Avatar answered Oct 31 '22 12:10

Rupert Nash