summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/glossaries/base
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2009-06-01 23:39:05 +0000
committerKarl Berry <karl@freefriends.org>2009-06-01 23:39:05 +0000
commit0c13c2fa41ec19c3844414c339528abe82a9cd79 (patch)
treeef475ebee484639f9162b6cb4fc503ff7a19b744 /Master/texmf-dist/tex/latex/glossaries/base
parenta8d496072399303044632adc3815973fe69ff748 (diff)
glossaries 2.01 (1jun09)
git-svn-id: svn://tug.org/texlive/trunk@13568 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/glossaries/base')
-rw-r--r--Master/texmf-dist/tex/latex/glossaries/base/glossaries-babel.sty2
-rw-r--r--Master/texmf-dist/tex/latex/glossaries/base/glossaries.sty117
-rw-r--r--Master/texmf-dist/tex/latex/glossaries/base/mfirstuc.sty2
3 files changed, 75 insertions, 46 deletions
diff --git a/Master/texmf-dist/tex/latex/glossaries/base/glossaries-babel.sty b/Master/texmf-dist/tex/latex/glossaries/base/glossaries-babel.sty
index f0040827507..86a6c1d5dea 100644
--- a/Master/texmf-dist/tex/latex/glossaries/base/glossaries-babel.sty
+++ b/Master/texmf-dist/tex/latex/glossaries/base/glossaries-babel.sty
@@ -21,7 +21,7 @@
%%
%% The Current Maintainer of this work is Nicola Talbot.
%%
-%% This work consists of the files glossaries.dtx and glossaries.ins and the derived files glossaries.sty, mfirstuc.sty, glossary-hypernav.sty, glossary-list.sty, glossary-long.sty, glossary-super.sty, glossary-tree.sty, glossaries-accsupp.sty, glossaries-babel.sty, glossaries-dictionary-Brazil.dict, glossaries-dictionary-Danish.dict, glossaries-dictionary-Dutch.dict, glossaries-dictionary-English.dict, glossaries-dictionary-French.dict, glossaries-dictionary-German.dict, glossaries-dictionary-Irish.dict, glossaries-dictionary-Italian.dict, glossaries-dictionary-Magyar.dict, glossaries-dictionary-Polish.dict, glossaries-dictionary-Spanish.dict, minimalgls.tex, sample.tex, sample4col.tex, sampleaccsupp.tex, sampleAcr.tex, sampleAcrDesc.tex, sampleDB.tex, sampleDesc.tex, sampleEq.tex, sampleEqPg.tex, sampleNtn.tex, sampleSec.tex, sampletree.tex, sampleutf8.tex, samplexdy.tex, samplexdy-mc.xdy, database1.tex, database2.tex, glossaries.perl.
+%% This work consists of the files glossaries.dtx and glossaries.ins and the derived files glossaries.sty, mfirstuc.sty, glossary-hypernav.sty, glossary-list.sty, glossary-long.sty, glossary-longragged.sty, glossary-super.sty, glossary-superragged.sty, glossary-tree.sty, glossaries-accsupp.sty, glossaries-babel.sty, glossaries-dictionary-Brazil.dict, glossaries-dictionary-Danish.dict, glossaries-dictionary-Dutch.dict, glossaries-dictionary-English.dict, glossaries-dictionary-French.dict, glossaries-dictionary-German.dict, glossaries-dictionary-Irish.dict, glossaries-dictionary-Italian.dict, glossaries-dictionary-Magyar.dict, glossaries-dictionary-Polish.dict, glossaries-dictionary-Spanish.dict, minimalgls.tex, sample.tex, sample4col.tex, sampleaccsupp.tex, sampleAcr.tex, sampleAcrDesc.tex, sampleDB.tex, sampleDesc.tex, sampleEq.tex, sampleEqPg.tex, sampleNtn.tex, sampleSec.tex, sampletree.tex, sampleutf8.tex, samplexdy.tex, samplexdy-mc.xdy, database1.tex, database2.tex, glossaries.perl.
%%
%% \CharacterTable
%% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
diff --git a/Master/texmf-dist/tex/latex/glossaries/base/glossaries.sty b/Master/texmf-dist/tex/latex/glossaries/base/glossaries.sty
index 69c3674a549..76356d94361 100644
--- a/Master/texmf-dist/tex/latex/glossaries/base/glossaries.sty
+++ b/Master/texmf-dist/tex/latex/glossaries/base/glossaries.sty
@@ -21,7 +21,7 @@
%%
%% The Current Maintainer of this work is Nicola Talbot.
%%
-%% This work consists of the files glossaries.dtx and glossaries.ins and the derived files glossaries.sty, mfirstuc.sty, glossary-hypernav.sty, glossary-list.sty, glossary-long.sty, glossary-super.sty, glossary-tree.sty, glossaries-accsupp.sty, glossaries-babel.sty, glossaries-dictionary-Brazil.dict, glossaries-dictionary-Danish.dict, glossaries-dictionary-Dutch.dict, glossaries-dictionary-English.dict, glossaries-dictionary-French.dict, glossaries-dictionary-German.dict, glossaries-dictionary-Irish.dict, glossaries-dictionary-Italian.dict, glossaries-dictionary-Magyar.dict, glossaries-dictionary-Polish.dict, glossaries-dictionary-Spanish.dict, minimalgls.tex, sample.tex, sample4col.tex, sampleaccsupp.tex, sampleAcr.tex, sampleAcrDesc.tex, sampleDB.tex, sampleDesc.tex, sampleEq.tex, sampleEqPg.tex, sampleNtn.tex, sampleSec.tex, sampletree.tex, sampleutf8.tex, samplexdy.tex, samplexdy-mc.xdy, database1.tex, database2.tex, glossaries.perl.
+%% This work consists of the files glossaries.dtx and glossaries.ins and the derived files glossaries.sty, mfirstuc.sty, glossary-hypernav.sty, glossary-list.sty, glossary-long.sty, glossary-longragged.sty, glossary-super.sty, glossary-superragged.sty, glossary-tree.sty, glossaries-accsupp.sty, glossaries-babel.sty, glossaries-dictionary-Brazil.dict, glossaries-dictionary-Danish.dict, glossaries-dictionary-Dutch.dict, glossaries-dictionary-English.dict, glossaries-dictionary-French.dict, glossaries-dictionary-German.dict, glossaries-dictionary-Irish.dict, glossaries-dictionary-Italian.dict, glossaries-dictionary-Magyar.dict, glossaries-dictionary-Polish.dict, glossaries-dictionary-Spanish.dict, minimalgls.tex, sample.tex, sample4col.tex, sampleaccsupp.tex, sampleAcr.tex, sampleAcrDesc.tex, sampleDB.tex, sampleDesc.tex, sampleEq.tex, sampleEqPg.tex, sampleNtn.tex, sampleSec.tex, sampletree.tex, sampleutf8.tex, samplexdy.tex, samplexdy-mc.xdy, database1.tex, database2.tex, glossaries.perl.
%%
%% \CharacterTable
%% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
@@ -39,7 +39,7 @@
%% Grave accent \` Left brace \{ Vertical bar \|
%% Right brace \} Tilde \~}
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{glossaries}[2009/04/16 v2.0 (NLCT)]
+\ProvidesPackage{glossaries}[2009/05/30 v2.01 (NLCT)]
\RequirePackage{ifthen}
\RequirePackage{xkeyval}[2006/11/18]
\RequirePackage{mfirstuc}
@@ -92,8 +92,15 @@ false,nolabel,autolabel}[nolabel]{%
\renewcommand*{\@gls@loadtree}{}%
\let\@glossary@default@style\relax
}
-\newcommand{\glsdefaulttype}{main}
-\newcommand{\acronymtype}{\glsdefaulttype}
+\newcommand*{\glsdefmain}{%
+ \newglossary{main}{gls}{glo}{\glossaryname}%
+}
+\newcommand*{\glsdefaulttype}{main}
+\newcommand*{\acronymtype}{\glsdefaulttype}
+\DeclareOptionX{nomain}{%
+ \let\glsdefaulttype\relax
+ \renewcommand*{\glsdefmain}{}%
+}
\define@boolkey{glossaries.sty}[gls]{acronym}[true]{}
\newcommand{\glscounter}{page}
\define@key{glossaries.sty}{counter}{%
@@ -170,6 +177,16 @@ name=true]{%
\glsxindytrue
\setkeys[gls]{xindy}{#1}%
}
+\newcommand*{\GlossariesWarning}[1]{%
+ \PackageWarning{glossaries}{#1}%
+}
+\newcommand*{\GlossariesWarningNoLine}[1]{%
+ \PackageWarningNoLine{glossaries}{#1}%
+}
+\DeclareOptionX{nowarn}{%
+ \renewcommand*{\GlossariesWarning}[1]{}%
+ \renewcommand*{\GlossariesWarningNoLine}[1]{}%
+}
\ProcessOptionsX
\ifthenelse{\equal{\glscounter}{section}}{%
\@ifundefined{chapter}{}{%
@@ -318,8 +335,8 @@ name=true]{%
\fi
\fi}
\newcommand*{\glsnoxindywarning}[1]{%
- \PackageWarning{glossaries}{Not in xindy mode --- ignoring
- \string#1}}
+ \GlossariesWarning{Not in xindy mode --- ignoring \string#1}%
+}
\ifglsxindy
\edef\@xdyattributes{\string"default\string"}%
\fi
@@ -516,44 +533,54 @@ name=true]{%
(define-letter-group \string"#1\string"^^J\space\space\space#2)}%
}%
\newcommand*{\forallglossaries}[3][\@glo@types]{%
-\@for#2:=#1\do{\ifthenelse{\equal{#2}{}}{}{#3}}}
+ \@for#2:=#1\do{\ifx#2\@empty\else#3\fi}%
+}
\newcommand*{\forglsentries}[3][\glsdefaulttype]{%
-\edef\@@glo@list{\csname glolist@#1\endcsname}%
-\@for#2:=\@@glo@list\do{%
-\ifthenelse{\equal{#2}{}}{}{#3}}}
+ \edef\@@glo@list{\csname glolist@#1\endcsname}%
+ \@for#2:=\@@glo@list\do{\ifx#2\@empty\else#3\fi}%
+}
\newcommand*{\forallglsentries}[3][\@glo@types]{%
\expandafter\forallglossaries\expandafter[#1]{\@@this@glo@}{%
\forglsentries[\@@this@glo@]{#2}{#3}}}
\newcommand{\ifglossaryexists}[3]{%
-\@ifundefined{@glotype@#1@out}{#3}{#2}}
+ \@ifundefined{@glotype@#1@out}{#3}{#2}%
+}
\newcommand{\ifglsentryexists}[3]{%
\@ifundefined{glo@#1@name}{#3}{#2}}
\newcommand*{\ifglsused}[3]{\ifthenelse{\boolean{glo@#1@flag}}{#2}{#3}}
-\newcommand{\glsdoifexists}[2]{\ifglsentryexists{#1}{#2}{%
-\PackageError{glossaries}{Glossary entry `#1' has not been
-defined.}{You need to define a glossary entry before you
-can use it.}}}
-\newcommand{\glsdoifnoexists}[2]{\ifglsentryexists{#1}{%
-\PackageError{glossaries}{Glossary entry `#1' has already
-been defined.}{}}{#2}}
+\newcommand{\glsdoifexists}[2]{%
+ \ifglsentryexists{#1}{#2}{%
+ \PackageError{glossaries}{Glossary entry `#1' has not been
+ defined}{You need to define a glossary entry before you
+ can use it.}}%
+}
+\newcommand{\glsdoifnoexists}[2]{%
+ \ifglsentryexists{#1}{%
+ \PackageError{glossaries}{Glossary entry `#1' has already
+ been defined}{}}{#2}%
+}
\newcommand*{\@glo@types}{,}
\newcommand*{\newglossary}[5][glg]{%
\ifglossaryexists{#2}{%
-\PackageError{glossaries}{Glossary type `#2' already exists}{%
-You can't define a new glossary called `#2' because it already
-exists}%
+ \PackageError{glossaries}{Glossary type `#2' already exists}{%
+ You can't define a new glossary called `#2' because it already
+ exists}%
}{%
-\toks@{#2}\edef\@glo@types{\@glo@types\the\toks@,}%
-\expandafter\gdef\csname glolist@#2\endcsname{,}%
-\expandafter\def\csname @glotype@#2@in\endcsname{#3}%
-\expandafter\def\csname @glotype@#2@out\endcsname{#4}%
-\expandafter\def\csname @glotype@#2@title\endcsname{#5}%
-\protected@write\@auxout{}{\string\@newglossary{#2}{#1}{#3}{#4}}%
-\expandafter\gdef\csname gls@#2@display\endcsname{%
-\glsdisplay}%
-\expandafter\gdef\csname gls@#2@displayfirst\endcsname{%
-\glsdisplayfirst}%
-\@ifnextchar[{\@gls@setcounter{#2}}{\@gls@setcounter{#2}[\glscounter]}}}
+ \ifx\glsdefaulttype\relax
+ \gdef\glsdefaulttype{#2}%
+ \fi
+ \toks@{#2}\edef\@glo@types{\@glo@types\the\toks@,}%
+ \expandafter\gdef\csname glolist@#2\endcsname{,}%
+ \expandafter\def\csname @glotype@#2@in\endcsname{#3}%
+ \expandafter\def\csname @glotype@#2@out\endcsname{#4}%
+ \expandafter\def\csname @glotype@#2@title\endcsname{#5}%
+ \protected@write\@auxout{}{\string\@newglossary{#2}{#1}{#3}{#4}}%
+ \expandafter\gdef\csname gls@#2@display\endcsname{%
+ \glsdisplay}%
+ \expandafter\gdef\csname gls@#2@displayfirst\endcsname{%
+ \glsdisplayfirst}%
+ \@ifnextchar[{\@gls@setcounter{#2}}%
+ {\@gls@setcounter{#2}[\glscounter]}}}
\@onlypreamble{\newglossary}
\@onlypremakeg\newglossary
\newcommand*{\@newglossary}[4]{}
@@ -562,7 +589,7 @@ exists}%
}
\newcommand*{\@gls@getcounter}[1]{%
\csname @glotype@#1@counter\endcsname}
-\newglossary{main}{gls}{glo}{\glossaryname}
+\glsdefmain
\define@key{glossentry}{name}{%
\def\@glo@name{#1}%
}
@@ -835,12 +862,12 @@ counter as its value}}{%
\setkeys{glslink}{#1}%
\edef\theglsentrycounter{\expandafter\noexpand
\csname the\@gls@counter\endcsname}%
+ \@do@wrglossary{#2}%
\ifKV@glslink@hyper
\@glslink{glo:#2}{\glstextformat{#3}}%
\else
\glstextformat{#3}\relax
\fi
- \@do@wrglossary{#2}%
}%
}
\def\@set@glo@numformat#1#2#3{%
@@ -1897,7 +1924,6 @@ counter as its value}}{%
\write\istfile{item_x1
\string"\string\\relax \string\\glsresetentrylist\string\n
\string"}
- \write\istfile{item_02 \string"\string\%\string\n\string"}
\write\istfile{item_12 \string"\string\%\string\n\string"}
\write\istfile{item_x2
\string"\string\\relax \string\\glsresetentrylist\string\n
@@ -1947,7 +1973,7 @@ counter as its value}}{%
Glossary type `#1' not defined}{New glossaries must be defined before
using \string\makeglossary}}}
\newcommand*{\warn@nomakeglossaries}{%
- \PackageWarningNoLine{glossaries}{\string\makeglossaries\space
+ \GlossariesWarningNoLine{\string\makeglossaries\space
hasn't been used,^^Jthe glossaries will not be updated}%
}
\newcommand*{\makeglossaries}{%
@@ -2054,12 +2080,13 @@ using \string\makeglossary}}}
\newcommand*{\glsseelastsep}{\space\andname\space}
\newcommand*{\glsseesep}{, }
\newcommand*{\glsseeitem}[1]{\glshyperlink{#1}}
-\def\warn@noprintglossary{\PackageWarningNoLine{glossaries}{No
+\def\warn@noprintglossary{\GlossariesWarningNoLine{No
\string\printglossary\space or \string\printglossaries\space
- found.^^JThis document will not have a glossary.}}
+ found.^^JThis document will not have a glossary}}
\@ifundefined{printglossary}{}{%
-\PackageWarning{glossaries}{Overriding \string\printglossary}%
-\let\printglossary\undefined}
+ \GlossariesWarning{Overriding \string\printglossary}%
+ \let\printglossary\undefined
+}
\newcommand*{\printglossary}[1][type=\glsdefaulttype]{%
\ifglsxindy\findrootlanguage\fi
\def\@glo@type{\glsdefaulttype}%
@@ -2128,9 +2155,11 @@ false,nolabel,autolabel}[nolabel]{%
\global\let\glossaryentrynumbers\org@glossaryentrynumbers}
\newcommand*{\glsnonextpages}{}
\@ifundefined{theglossary}{%
-\newenvironment{theglossary}{}{}}{%
-\PackageWarning{glossaries}{overriding `theglossary' environment}%
-\renewenvironment{theglossary}{}{}}
+ \newenvironment{theglossary}{}{}%
+}{%
+ \GlossariesWarning{overriding `theglossary' environment}%
+ \renewenvironment{theglossary}{}{}%
+}
\newcommand*{\glossaryheader}{}
\newcommand*{\glstarget}[2]{\@glstarget{glo:#1}{#2}}
\newcommand*{\glossaryentryfield}[5]{%
@@ -2218,7 +2247,7 @@ style `#1' undefined}{}}{%
\newcommand*{\hyperemph}[1]{\emph{\glshypernumber{#1}}}
\ifglsacronym
\newglossary[alg]{acronym}{acr}{acn}{\acronymname}
- \renewcommand{\acronymtype}{acronym}
+ \renewcommand*{\acronymtype}{acronym}
\defglsdisplay[acronym]{#1#4}
\defglsdisplayfirst[acronym]{#1#4}
\fi
diff --git a/Master/texmf-dist/tex/latex/glossaries/base/mfirstuc.sty b/Master/texmf-dist/tex/latex/glossaries/base/mfirstuc.sty
index 0f9cc96c9ec..0e2fa594361 100644
--- a/Master/texmf-dist/tex/latex/glossaries/base/mfirstuc.sty
+++ b/Master/texmf-dist/tex/latex/glossaries/base/mfirstuc.sty
@@ -21,7 +21,7 @@
%%
%% The Current Maintainer of this work is Nicola Talbot.
%%
-%% This work consists of the files glossaries.dtx and glossaries.ins and the derived files glossaries.sty, mfirstuc.sty, glossary-hypernav.sty, glossary-list.sty, glossary-long.sty, glossary-super.sty, glossary-tree.sty, glossaries-accsupp.sty, glossaries-babel.sty, glossaries-dictionary-Brazil.dict, glossaries-dictionary-Danish.dict, glossaries-dictionary-Dutch.dict, glossaries-dictionary-English.dict, glossaries-dictionary-French.dict, glossaries-dictionary-German.dict, glossaries-dictionary-Irish.dict, glossaries-dictionary-Italian.dict, glossaries-dictionary-Magyar.dict, glossaries-dictionary-Polish.dict, glossaries-dictionary-Spanish.dict, minimalgls.tex, sample.tex, sample4col.tex, sampleaccsupp.tex, sampleAcr.tex, sampleAcrDesc.tex, sampleDB.tex, sampleDesc.tex, sampleEq.tex, sampleEqPg.tex, sampleNtn.tex, sampleSec.tex, sampletree.tex, sampleutf8.tex, samplexdy.tex, samplexdy-mc.xdy, database1.tex, database2.tex, glossaries.perl.
+%% This work consists of the files glossaries.dtx and glossaries.ins and the derived files glossaries.sty, mfirstuc.sty, glossary-hypernav.sty, glossary-list.sty, glossary-long.sty, glossary-longragged.sty, glossary-super.sty, glossary-superragged.sty, glossary-tree.sty, glossaries-accsupp.sty, glossaries-babel.sty, glossaries-dictionary-Brazil.dict, glossaries-dictionary-Danish.dict, glossaries-dictionary-Dutch.dict, glossaries-dictionary-English.dict, glossaries-dictionary-French.dict, glossaries-dictionary-German.dict, glossaries-dictionary-Irish.dict, glossaries-dictionary-Italian.dict, glossaries-dictionary-Magyar.dict, glossaries-dictionary-Polish.dict, glossaries-dictionary-Spanish.dict, minimalgls.tex, sample.tex, sample4col.tex, sampleaccsupp.tex, sampleAcr.tex, sampleAcrDesc.tex, sampleDB.tex, sampleDesc.tex, sampleEq.tex, sampleEqPg.tex, sampleNtn.tex, sampleSec.tex, sampletree.tex, sampleutf8.tex, samplexdy.tex, samplexdy-mc.xdy, database1.tex, database2.tex, glossaries.perl.
%%
%% \CharacterTable
%% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z