diff options
author | Karl Berry <karl@freefriends.org> | 2007-10-13 22:42:44 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2007-10-13 22:42:44 +0000 |
commit | 00fd18b649b5eaa172d3831df80680767d22be33 (patch) | |
tree | e3eb17ea921ac52daecd5852599288d6b80680a2 /Master/texmf-dist/source | |
parent | 90e9a2ff73654ae1262eb867fc7ab09bb0f587d3 (diff) |
glossaries 1.08 (13oct07)
git-svn-id: svn://tug.org/texlive/trunk@5177 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source')
-rw-r--r-- | Master/texmf-dist/source/latex/glossaries/glossaries.dtx | 289 | ||||
-rw-r--r-- | Master/texmf-dist/source/latex/glossaries/glossaries.ins | 2 |
2 files changed, 276 insertions, 15 deletions
diff --git a/Master/texmf-dist/source/latex/glossaries/glossaries.dtx b/Master/texmf-dist/source/latex/glossaries/glossaries.dtx index a86c855cb85..a47abec2adb 100644 --- a/Master/texmf-dist/source/latex/glossaries/glossaries.dtx +++ b/Master/texmf-dist/source/latex/glossaries/glossaries.dtx @@ -2,9 +2,9 @@ % glossaries.dtx generated using makedtx version 0.94b (c) Nicola Talbot % Command line args: % -macrocode "glossaries\.perl" -% -src "glossaries.sty=>glossaries.sty" +% -src "glossaries.sty\Z=>glossaries.sty" % -src "(glossary-.+)\.(sty)\Z=>\1.\2" -% -src "glossaries\.perl=>glossaries.perl" +% -src "glossaries\.perl\Z=>glossaries.perl" % -author "Nicola Talbot" % -dir "source" % -setambles "glossaries\.perl=>\nopreamble\nopostamble" @@ -12,7 +12,7 @@ % -doc "manual.tex" % -codetitle "Documented Code" % glossaries -% Created on 2007/9/13 20:21 +% Created on 2007/10/13 15:35 %\fi %\iffalse %<*package> @@ -63,7 +63,7 @@ \makeatother \RecordChanges \PageIndex -\CheckSum{2826} +\CheckSum{3027} \CodelineNumbered \newcommand*{\termdef}[1]{\emph{#1}\iterm{#1}} \newcommand*{\term}[1]{#1\iterm{#1}} @@ -96,7 +96,7 @@ %\MakeShortVerb{"} %\DeleteShortVerb{\|} % -% \title{glossaries.sty v 1.07: \LaTeXe\ Package to Assist Generating Glossaries} +% \title{glossaries.sty v 1.08: \LaTeXe\ Package to Assist Generating Glossaries} % \author{Nicola L.C. Talbot\\[10pt] %School of Computing Sciences\\ %University of East Anglia\\ @@ -104,7 +104,7 @@ %NR4 7TJ. United Kingdom.\\ %\url{http://theoval.cmp.uea.ac.uk/~nlct/}} % -% \date{13th September 2007} +% \date{13th October 2007} % \maketitle %\tableofcontents % @@ -157,6 +157,13 @@ %defined in your document, so where possible you should use %\appname{makeglossaries} instead to reduce the possibility of error. % +%As from version 1.08, the \styname{glossaries} package now has +%limited multi-lingual support, thanks to all the people who have sent +%me the relevant translations either via email or via comp.text.tex. +%However, you must load \styname{babel} \emph{before} +%\styname{glossaries}. (See \autoref{sec:predefinednames} for the +%predefined names used by the \styname{glossaries} package.) +% %This documentation is structured as follows: \autoref{sec:quick} %is for people who want a few quick pointers of how to get started, %without having to read through lengthy descriptions, @@ -166,6 +173,12 @@ %package works, and how to do more complicated things, such as %changing the way glossary entries appear. % +%\subsection{Troubleshooting} +% +%There is a list of frequently asked questions for the +%\styname{glossaries} package available at: +%\url{http://theoval.cmp.uea.ac.uk/~nlct/latex/packages/faq/}. +% %\section{A Quick Guide For The Impatient} %\label{sec:quick} % @@ -1089,8 +1102,6 @@ %or using the \gloskey[printglossary]{style} key in the optional %argument to \icmdname{printglossary}, or using the command:\\[10pt] %\cs{glossarystyle}\marg{style-name}\\[10pt] -%For further details on creating or modifying glossary styles see -%\autoref{sec:printglos} and \autoref{sec:styles}. % % \changes{1.03}{2007 July 4}{'glspostdescription added} %All the styles except for the three and four column styles use the @@ -1100,6 +1111,111 @@ %say a comma), you will need to redefine \cs{glspostdescription} %before the glossary is displayed. % +%\subsection{Defining your own glossary style} +% +%If the predefined styles don't fit your requirements, you can +%define your own style using\DescribeMacro{\newglossarystyle}:\\[10pt] +%\cs{newglossarystyle}\marg{name}\marg{definitions}\\[10pt] +%where \meta{name} is the name of the new glossary style (to be +%used in \cs{glossarystyle}. The second argument \meta{definitions}, +%needs to redefine the following: +% +%\DescribeEnv{theglossary} +%\noindent\envname{theglossary}\par\noindent +%This environment defines how the main body of the glossary should +%be typeset. Note that this does not include the section heading, +%the glossary preamble (defined by \cs{glossarypreamble}) or the +%glossary postamble (defined by \cs{glossarypostamble}.) For example, +%the \glostyle{list} style uses the \envname{description} environment, +%so the \envname{theglossary} environment is simply redefined to begin +%and end the \envname{description} environment. +% +%\DescribeMacro{\glossaryheader} +%\noindent\cs{glossaryheader}\par\noindent +%This macro indicates what to do at the start of the main body +%of the glossary. Note that this is not the same as +%\cs{glossarypreamble}, which should not be affected by changes in +%the glossary style. The \glostyle{list} glossary style redefines +%\cs{glossaryheader} to do nothing, whereas the \glostyle{longheader} +%glossary style redefines \cs{glossaryheader} to do a header row. +% +%\DescribeMacro{\glsgroupheading} +%\noindent\cs{glsgroupheading}\marg{label}\par\noindent +%This macro indicates what to do at the start of each logical block +%within the main body of the glossary. The glossary is sub-divided +%into 28 logical blocks that are determined by the first character of +%the \gloskey{sort} key (or \gloskey{name} key if the \gloskey{sort} +%key is omitted.) The sub-divisions are in the following order: +%symbols, numbers, A, \ldots, Z. Note that the argument to +%\cs{glsgroupheading} is a label, \emph{not} the group title. The +%group title can be obtained via \cs{glsgetgrouptitle}\marg{label}, +%and a navigation hypertarget can be created using +%\cs{glsnavhypertarget}\marg{label}. Most of the predefined glossary +%styles redefine \cs{glsgroupheading} to simply ignore its argument. +%The \glostyle{listhypergroup} style redefines \cs{glsgroupheading} +%as follows: +%\begin{verbatim} +%\renewcommand*{\glsgroupheading}[1]{% +%\item[\glsnavhypertarget{##1}{\glsgetgrouptitle{##1}}]} +%\end{verbatim} +%See also \cs{glsgroupskip} below. +% +%\DescribeMacro{\glossaryentryfield} +%\cs{glossaryentryfield}\marg{label}\marg{formatted +%name}\marg{description}\marg{symbol} +%\marg{number list}\par\noindent +%This macro indicates what to do for a given glossary entry. +%Note that \meta{formatted name} will always be in the form +%\cs{glsnamefont}\marg{name}. This allows the user to set a given +%font for the entry name, regardless of the glossary style used. +%Note that \meta{label} is the label used when the glossary entry +%was defined via either \cs{newglossaryentry} or \cs{newacronym}. +%Each time you use a glossary entry it creates a +%link\footnote{if the document doesn't have hyperlinks enabled, +%\cs{@glslink} ignores the label, and simply typesets the text.} +%using \cs{@glslink}\marg{label}\marg{text} with the label +%\texttt{glo:}\meta{label}. Your +%new glossary style must therefore redefine \cs{glossaryentryfield} +%so that it uses \cs{@glstarget}\{\texttt{glo:}\meta{label}\}\marg{text} +%to ensure the hyperlinks function correctly\footnote{again, if the +%document doesn't support hyperlinks, \cs{@glstarget} will ignore +%the label, and just typeset the text.}. +% +%Note also that \meta{number list} will always be of the form\\[10pt] +%\cs{glossaryentrynumbers}\{\cs{relax}\\ +%\cs{setentrycounter}\marg{counter name}\cs{glsnumberformat}\marg{number(s)}\}\\[10pt] +%where \meta{number(s)} +%may contain \cs{delimN} (to delimit individual numbers) and/or +%\cs{delimR} (to indicate a range of numbers.) There may be +%multiple occurrences of +%\cs{setentrycounter}\marg{counter name}\cs{glsnumberformat}\marg{number(s)}, but note +%that the entire number list is enclosed within the argument +%to \cs{glossaryentrynumbers}. The user can redefine this to change +%the way the entire number list is formatted, regardless of +%the glossary style (although, obviously, the \gloskey{format} +%key may over-ride this.) However the most common use of +%\cs{glossaryentrynumbers} is to provide a means of suppressing the +%number list altogether. (In fact, the \pkgopt{nonumberlist} option +%redefines \cs{glossaryentrynumbers} to ignore its argument.) +%Therefore, when you define a new glossary style, you don't need +%to worry about whether the user has specified the +%\pkgopt{nonumberlist} package option. +% +%One more thing to remember is that when you are redefining a command +%within the argument to another command, you must use \verb|##1|, +%\verb|##2|, etc instead of \verb|#1|, \verb|#2|, etc. For examples, +%look at the way the predefined styles are defined in +%\autoref{sec:styles}. +% +%\DescribeMacro{\glsgroupskip} +%\noindent\cs{glsgroupskip}\par\noindent +%This macro determines what to do after one logical group but before +%the header for the next logical group. The \glostyle{list} glossary +%style simply redefines \cs{glsgroupskip} to be \cs{indexspace}. +% +%For further details on creating or modifying glossary styles see +%\autoref{sec:printglos} and \autoref{sec:styles}. +% % \StopEventually{\phantomsection\addcontentsline{toc}{section}{Index}\PrintIndex} % % @@ -1116,7 +1232,7 @@ % This package requires \LaTeXe. % \begin{macrocode} \NeedsTeXFormat{LaTeX2e} -\ProvidesPackage{glossaries}[2007/09/13 v1.07 (NLCT)] +\ProvidesPackage{glossaries}[2007/10/13 v1.08 (NLCT)] % \end{macrocode} % Required packages: % \begin{macrocode} @@ -1368,7 +1484,7 @@ name=true]{% \@ifundefined{hyperdef}{}{\hyperdef{section}{\thesection}{}}}}}{} % \end{macrocode} % -%\subsection{Default values} +%\subsection{Default values}\label{sec:predefinednames} % This section sets up default values that are used by this % package. Some of the names may already be defined (e.g.\ by % \styname{babel}) so \cs{providecommand} is used. @@ -1424,6 +1540,147 @@ name=true]{% \providecommand*{\glsnumbersgroupname}{Numbers} % \end{macrocode} %\end{macro} +% Add multi-lingual support\changes{1.08}{2007 Oct 13}{Added +% babel support}. Thanks to everyone who contributed to the +% translations from both comp.text.tex and via email. +% \begin{macrocode} +\@ifpackageloaded{babel}{% +% \end{macrocode} +% English: +% \begin{macrocode} +\addto\captionsenglish{% +\renewcommand*{\glossaryname}{Glossary}% +\renewcommand*{\acronymname}{Acronyms}% +\renewcommand*{\entryname}{Notation}% +\renewcommand*{\descriptionname}{Description}% +\renewcommand*{\symbolname}{Symbol}% +\renewcommand*{\pagelistname}{Page List}% +\renewcommand*{\glssymbolsgroupname}{Symbols}% +\renewcommand*{\glsnumbersgroupname}{Numbers}% +}% +% \end{macrocode} +% German (quite a few variations were suggested for German, +% I settled on the following): +% \begin{macrocode} +\addto\captionsgerman{% +\renewcommand*{\glossaryname}{Glossar}% +\renewcommand*{\acronymname}{Akronyme}% +\renewcommand*{\entryname}{Bezeichnung}% +\renewcommand*{\descriptionname}{Beschreibung}% +\renewcommand*{\symbolname}{Symbol}% +\renewcommand*{\pagelistname}{Seiten}% +\renewcommand*{\glssymbolsgroupname}{Symbole}% +\renewcommand*{\glsnumbersgroupname}{Zahlen}} +% \end{macrocode} +% ngerman is identical to German: +% \begin{macrocode} +\addto\captionsngerman{% +\renewcommand*{\glossaryname}{Glossar}% +\renewcommand*{\acronymname}{Akronyme}% +\renewcommand*{\entryname}{Bezeichnung}% +\renewcommand*{\descriptionname}{Beschreibung}% +\renewcommand*{\symbolname}{Symbol}% +\renewcommand*{\pagelistname}{Seiten}% +\renewcommand*{\glssymbolsgroupname}{Symbole}% +\renewcommand*{\glsnumbersgroupname}{Zahlen}} +% \end{macrocode} +% Italian: +% \begin{macrocode} +\addto\captionsitalian{% +\renewcommand*{\glossaryname}{Glossario}% +\renewcommand*{\acronymname}{Acronimi}% +\renewcommand*{\entryname}{Nomenclatura}% +\renewcommand*{\descriptionname}{Descrizione}% +\renewcommand*{\symbolname}{Simbolo}% +\renewcommand*{\pagelistname}{Elenco delle pagine}% +\renewcommand*{\glssymbolsgroupname}{Simboli}% +\renewcommand*{\glsnumbersgroupname}{Numeri}} +% \end{macrocode} +% Dutch: +% \begin{macrocode} +\addto\captionsdutch{% +\renewcommand*{\glossaryname}{Woordenlijst}% +\renewcommand*{\acronymname}{Acroniemen}% +\renewcommand*{\entryname}{Benaming}% +\renewcommand*{\descriptionname}{Beschrijving}% +\renewcommand*{\symbolname}{Symbool}% +\renewcommand*{\pagelistname}{Pagina's}% +\renewcommand*{\glssymbolsgroupname}{Symbolen}% +\renewcommand*{\glsnumbersgroupname}{Cijfers}} +% \end{macrocode} +% Spanish: +% \begin{macrocode} +\addto\captionsspanish{% +\renewcommand*{\glossaryname}{Glosario}% +\renewcommand*{\acronymname}{Siglas}% +\renewcommand*{\entryname}{Entrada}% +\renewcommand*{\descriptionname}{Descripci\'on}% +\renewcommand*{\symbolname}{S\'{\i}mbolo}% +\renewcommand*{\pagelistname}{Lista de p\'aginas}% +\renewcommand*{\glssymbolsgroupname}{S\'{\i}mbolos}% +\renewcommand*{\glsnumbersgroupname}{N\'umeros}} +% \end{macrocode} +% French: +% \begin{macrocode} +\addto\captionsfrench{% +\renewcommand*{\glossaryname}{Glossaire}% +\renewcommand*{\acronymname}{Acronymes}% +\renewcommand*{\entryname}{Terme}% +\renewcommand*{\descriptionname}{Description}% +\renewcommand*{\symbolname}{Symbole}% +\renewcommand*{\pagelistname}{Pages}% +\renewcommand*{\glssymbolsgroupname}{Symboles}% +\renewcommand*{\glsnumbersgroupname}{Nombres}} +% \end{macrocode} +% Danish: +% \begin{macrocode} +\addto\captionsdanish{% +\renewcommand*{\glossaryname}{Ordliste}% +\renewcommand*{\acronymname}{Akronymer}% +\renewcommand*{\entryname}{Symbolforklaring}% +\renewcommand*{\descriptionname}{Beskrivelse}% +\renewcommand*{\symbolname}{Symbol}% +\renewcommand*{\pagelistname}{Side}% +\renewcommand*{\glssymbolsgroupname}{Symboler}% +\renewcommand*{\glsnumbersgroupname}{Tal}} +% \end{macrocode} +% Irish: +% \begin{macrocode} +\addto\captionsirish{% +\renewcommand*{\glossaryname}{Gluais}% +\renewcommand*{\acronymname}{Acrainmneacha}% 'Acronyms' +% \end{macrocode} +% wasn't sure whether to go for N\'ota (Note), Ciall (`Meaning', +% `sense') ot Br\'{\i} (`Meaning'). In the end I chose Ciall. +% \begin{macrocode} +\renewcommand*{\entryname}{Ciall}% +\renewcommand*{\descriptionname}{Tuairisc}% +% \end{macrocode} +% Again, not sure whether to use Comhartha/Comhartha\'{\i} or +% Siombail/Siombaile, so have chosen the former. +% \begin{macrocode} +\renewcommand*{\symbolname}{Comhartha}% +\renewcommand*{\glssymbolsgroupname}{Comhartha\'{\i}}%OR +\renewcommand*{\pagelistname}{Leathanaigh}% +\renewcommand*{\glsnumbersgroupname}{Uimhreacha}} +% \end{macrocode} +% Hungarian: +% \begin{macrocode} +\addto\captionsmagyar{% +\renewcommand*{\glossaryname}{Sz\'ojegyz\'ek}% +\renewcommand*{\acronymname}{Bet\H uszavak}% +\renewcommand*{\entryname}{Kifejez\'es}% +\renewcommand*{\descriptionname}{Magyar\'azat}% +\renewcommand*{\symbolname}{Jel\"ol\'es}% +\renewcommand*{\pagelistname}{Oldalsz\'am}% +\renewcommand*{\glssymbolsgroupname}{Jelek}% +\renewcommand*{\glsnumbersgroupname}{Sz\'amjegyek}% +} +% \end{macrocode} +% babel not loaded: +% \begin{macrocode} +}{} +% \end{macrocode} % The description terminator is given by \cs{glspostdescription} % (except for the 3 and 4 column styles). This is a full stop % by default: @@ -1963,10 +2220,12 @@ counter as its value}}{% % keys are omitted, an error will be generated. %\changes{1.05}{2007 Aug 10}{Changed the default value of the sort % key to just the value of the name key}% +%\changes{1.08}{2007 Oct 13}{Fixed error message to say ``description +%key'' rather than ``desc key''} % \begin{macrocode} \def\@glo@name{\PackageError{glossaries}{name key required in \string\newglossaryentry}{You haven't specified the entry name}}% -\def\@glo@desc{\PackageError{glossaries}{desc key required in +\def\@glo@desc{\PackageError{glossaries}{description key required in \string\newglossaryentry}{You haven't specified the entry description}}% \def\@glo@type{\glsdefaulttype}% \def\@glo@symbol{\relax}% @@ -3861,7 +4120,7 @@ first={#4 (#3)},plural={#3s},firstplural={#4s (#3s)},#1}} % \icmdname{item} command, it will appear in a bold font by % default. % \begin{macrocode} -\ProvidesPackage{glossary-list}[2007/07/04 v1.01 (NLCT)] +\ProvidesPackage{glossary-list}[2007/10/04 v1.02 (NLCT)] % \end{macrocode} % The \glostyle{list} glossary style % uses the \envname{description} environment. The group separator @@ -3880,10 +4139,11 @@ first={#4 (#3)},plural={#3s},firstplural={#4s (#3s)},#1}} % \end{macrocode} % The \glostyle{listgroup} style is like the \glostyle{list} % style, but the glossary groups have headings. +%\changes{1.08}{2007 Oct 13}{changed listgroup style to use \cs{glsgetgrouptitle}} % \begin{macrocode} \newglossarystyle{listgroup}{% \glossarystyle{list}% -\renewcommand*{\glsgroupheading}[1]{\item[##1]}} +\renewcommand*{\glsgroupheading}[1]{\item[\glsgetgrouptitle{##1}]}} % \end{macrocode} % The \glostyle{listhypergroup} style is like the \glostyle{listgroup} % style, but has a set of links to the groups at the @@ -3907,10 +4167,11 @@ first={#4 (#3)},plural={#3s},firstplural={#4s (#3s)},#1}} % \end{macrocode} % The \glostyle{altlistgroup} glossary style is like the % \glostyle{altlist} style, but the glossary groups have headings. +%\changes{1.08}{2007 Oct 13}{changed altlistgroup style to use \cs{glsgetgrouptitle}} % \begin{macrocode} \newglossarystyle{altlistgroup}{% \glossarystyle{altlist}% -\renewcommand*{\glsgroupheading}[1]{\item[##1]}} +\renewcommand*{\glsgroupheading}[1]{\item[\glsgetgrouptitle{##1}]}} % \end{macrocode} % The \glostyle{altlisthypergroup} glossary style is like the % \glostyle{altlisthypergroup} style, but has a diff --git a/Master/texmf-dist/source/latex/glossaries/glossaries.ins b/Master/texmf-dist/source/latex/glossaries/glossaries.ins index c9bcf74cb43..170da75cd4e 100644 --- a/Master/texmf-dist/source/latex/glossaries/glossaries.ins +++ b/Master/texmf-dist/source/latex/glossaries/glossaries.ins @@ -1,4 +1,4 @@ -% glossaries.ins generated using makedtx version 0.94b 2007/9/13 20:21 +% glossaries.ins generated using makedtx version 0.94b 2007/10/13 15:35 \input docstrip \preamble |