Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

When I have many glossary words that describe the same, how do I neatly put these into the glossary? Ideally, something like:

\newglossaryentry{digest, hash, hash code} {
name=digest, description={The output of a hash function).}
}

producing

   digest, hash or hash code The output of a hash function.

is what I'm looking for, and I can't seem to find this anywhere.

share|improve this question
add comment

1 Answer

up vote 6 down vote accepted

I'd define one entry (say, digest) in the usual way and then use \gls{digest} in the description field of the alternative entries. See section 8 of the glossaries manual for details.

\documentclass{article}

\usepackage[nonumberlist]{glossaries}
\makeglossaries

\newglossaryentry{digest}{name={digest (\textmd{also} hash, hash code)},%
    text=digest,description={The output of a hash function}}

\newglossaryentry{hash}
    {name=hash,description={\emph{See} \gls{digest}}}

\newglossaryentry{hash code}
    {name={hash code},description={\emph{See} \gls{digest}}}

\begin{document}

\null\vfill% just for the example

Some text about \gls{digest}.

Some text about \gls{hash}.

Some text about \gls{hash code}.

\printglossaries

\end{document}

enter image description here

share|improve this answer
    
That's clever! Brilliant, thanks. –  Henning Klevjer Aug 20 '12 at 12:29
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.