2

I'm working on a report that requires an acronym list with some customization. My intent is to generate an acronym list with an extra column for a customized parameter associated with the acronym. In the end I' thinking that I want to be able to do something like the following:

\usepackage[acronym, section]{glossaries}

\glsaddkey{detail}{} ...

\newacronym[detail=(info)]{AD}{AD}{Acronym Definition}

I want to follow this up so that in the acronym list it had an output at the end of the document that looks something like the following:

(info)    AD     Acronym Definition

I don't want to change anything about how the acronyms are displayed in report text.

In investigating how to do this on my own I came across this question: Custom glossary style, \makenoidxglossaries and \glsgroupskip. This question seems to be very similar to what I'm trying to accomplish however I can't get the MWE in their answer to work, making adapting it to my own application rather difficult. Specifically, I get the following error on compile:

! Undefined control sequence.
l.42 \glsaddkey
               {math}{}{\acem}{\Acem}{\acm}{\Acm}{\ACm}

I have to be missing something simple here as I can't seem to find any hints as to what I'm doing wrong here. If I could get that MWE to work I should be able to reverse engineer and hack my way to applying it my specific application on my own. Here is the MWE from the example I cited above, for convenience.

\documentclass{article}
\usepackage{amsfonts}
\usepackage{booktabs}
\usepackage[shortcuts]{glossaries}
\makeglossaries

\glsaddkey{math}{}{\acem}{\Acem}{\acm}{\Acm}{\ACm}

\newacronym[math=\mathfrak{foo}]{foo}{foo}{Foo}
\newacronym[math=\mathfrak{bar}]{bar}{bar}{Bar}
\newacronym[math=\mathfrak{baz}]{baz}{baz}{Baz}
\newacronym[math=\mathfrak{qux}]{qux}{qux}{Qux}

\newglossarystyle{my}{%
  \setglossarystyle{long3colheader}%
  \renewcommand*{\glossaryheader}{%
    \toprule
    Abbreviation & Symbol in Mathematical Expressions & Description \tabularnewline\midrule\endhead
    \bottomrule\endfoot
  }%
  \renewcommand*{\glsgroupskip}{%
     & &\tabularnewline}%
  \setlength\glsdescwidth{.275\textwidth}%
  \setlength\glspagelistwidth{.45\textwidth}%
  \renewcommand{\glossentry}[2]{%
    \glsentryitem{##1}\glstarget{##1}{\glossentryname{##1}} & $\acem{##1}$ & \glossentrydesc{##1}\tabularnewline
  }%
}

\setglossarystyle{my}

\begin{document}
  \glsaddallunused
  \printglossaries
\end{document}

closed as off-topic by user31729, Zarko, John Kormylo, Stefan Kottwitz Dec 28 '15 at 1:50

  • This question does not fall within the scope of TeX, LaTeX or related typesetting systems as defined in the help center.
If this question can be reworded to fit the rules in the help center, please edit the question.

  • 2
    Welcome to TeX.SX! It looks as though your version of glossaries is too old. \glsaddkey was added to version v3.12a. – Nicola Talbot Dec 16 '15 at 23:45
  • You are correct, thanks. An update seems to resolve my issues. It's always the simple things that get you. :) – Patrick Dec 22 '15 at 19:37
  • 3
    I'm voting to close this question as off-topic because the issue could be solved by updating the glossaries package – user31729 Dec 27 '15 at 23:53
  • I'm happy to have this closed. – Patrick Dec 29 '15 at 13:39

Browse other questions tagged or ask your own question.