diff options
author | Manuel Pégourié-Gonnard <mpg@elzevir.fr> | 2008-06-21 16:05:24 +0000 |
---|---|---|
committer | Manuel Pégourié-Gonnard <mpg@elzevir.fr> | 2008-06-21 16:05:24 +0000 |
commit | 2591d5bab21119052bb58e82db7fd9fab8e97a7c (patch) | |
tree | 7062a197de46919fef0fdc72a5320096d4cacc06 /Master/texmf-dist/tex/latex/glossaries | |
parent | 557142a18ecd2e95285292dc54e46edec842ecc2 (diff) |
glossaries update 21jun08
git-svn-id: svn://tug.org/texlive/trunk@8904 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/glossaries')
4 files changed, 75 insertions, 52 deletions
diff --git a/Master/texmf-dist/tex/latex/glossaries/base/glossaries.sty b/Master/texmf-dist/tex/latex/glossaries/base/glossaries.sty index 9eb6e8071f1..c30716a7552 100644 --- a/Master/texmf-dist/tex/latex/glossaries/base/glossaries.sty +++ b/Master/texmf-dist/tex/latex/glossaries/base/glossaries.sty @@ -39,7 +39,7 @@ %% Grave accent \` Left brace \{ Vertical bar \| %% Right brace \} Tilde \~} \NeedsTeXFormat{LaTeX2e} -\ProvidesPackage{glossaries}[2008/05/10 v1.13 (NLCT)] +\ProvidesPackage{glossaries}[2008/06/17 v1.14 (NLCT)] \RequirePackage{ifthen} \RequirePackage{xkeyval}[2006/11/18] \RequirePackage{mfirstuc} @@ -55,6 +55,7 @@ subsection,subsubsection,paragraph,subparagraph}[section]{% \renewcommand*{\@@glossarysec}{#1}} \newcommand*{\@@glossarysecstar}{*} \newcommand*{\@@glossaryseclabel}{} +\newcommand*{\glsautoprefix}{} \define@choicekey{glossaries.sty}{numberedsection}[\val\nr]{% false,nolabel,autolabel}[nolabel]{% \ifcase\nr\relax @@ -65,7 +66,7 @@ false,nolabel,autolabel}[nolabel]{% \renewcommand*{\@@glossaryseclabel}{}% \or \renewcommand*{\@@glossarysecstar}{}% - \renewcommand*{\@@glossaryseclabel}{\label{\@glo@type}}% + \renewcommand*{\@@glossaryseclabel}{\label{\glsautoprefix\@glo@type}}% \fi} \newcommand*{\@glossary@default@style}{list} \define@key{glossaries.sty}{style}{% @@ -1263,8 +1264,8 @@ to move \string\makeglossaries\space after all your \def\glossarytitle{\csname @glotype@\@glo@type @title\endcsname}% \def\glossarytoctitle{\glossarytitle}% \def\@glossarystyle{}% -\setkeys{printgloss}{#1}% \bgroup +\setkeys{printgloss}{#1}% \@glossarystyle \makeatletter \@input@{\jobname.\csname @glotype@\@glo@type @in\endcsname}% @@ -1279,6 +1280,24 @@ to move \string\makeglossaries\space after all your \@ifundefined{@glsstyle@#1}{\PackageError{glossaries}{Glossary style `#1' undefined}{}}{% \def\@glossarystyle{\csname @glsstyle@#1\endcsname}}} +\define@choicekey{printgloss}{numberedsection}[\val\nr]{% +false,nolabel,autolabel}[nolabel]{% +\ifcase\nr\relax + \renewcommand*{\@@glossarysecstar}{*}% + \renewcommand*{\@@glossaryseclabel}{}% +\or + \renewcommand*{\@@glossarysecstar}{}% + \renewcommand*{\@@glossaryseclabel}{}% +\or + \renewcommand*{\@@glossarysecstar}{}% + \renewcommand*{\@@glossaryseclabel}{\label{\glsautoprefix\@glo@type}}% +\fi} +\define@boolkey{printgloss}[gls]{nonumberlist}[true]{% +\ifglsnonumberlist + \def\glossaryentrynumbers##1{}% +\else + \def\glossaryentrynumbers##1{##1}% +\fi} \@ifundefined{theglossary}{% \newenvironment{theglossary}{}{}}{% \PackageWarning{glossaries}{overriding `theglossary' environment}% @@ -1424,6 +1443,7 @@ firstplural={\@glo@descplural\space (\@glo@plural)},% \new@ifnextchar[{\@ACRfullpl{#1}{#2}}{\@ACRfullpl{#1}{#2}[]}} \def\@ACRfullpl#1#2[#3]{\@GLSfirstplural@{#1}{#2}[#3]} \newcommand{\acronymfont}[1]{#1} +\newcommand{\firstacronymfont}[1]{\acronymfont{#1}} \ifglsacrdescription \ifglsacrfootnote \renewcommand{\newacronym}[4][]{% @@ -1464,7 +1484,7 @@ firstplural={\@glo@descplural\space (\@glo@plural)},% \def\@ACRfullpl#1#2[#3]{\@GLSsymbolplural@{#1}{#2}[#3] (\acronymfont{\@GLSplural@{#1}{#2}[#3]})} \defglsdisplayfirst[\acronymtype]{% - \acronymfont{#1}#4\noexpand\protect\noexpand\footnote{% + \firstacronymfont{#1}#4\noexpand\protect\noexpand\footnote{% \noexpand\protect\noexpand\glslink [\@gls@link@opts]{\@gls@link@label}{#3}}}% \defglsdisplay[\acronymtype]{\acronymfont{#1}#4}% @@ -1496,8 +1516,6 @@ firstplural={\@glo@descplural\space (\@glo@plural)},% \newglossaryentry{#2}{type=\acronymtype,% name={\acronymfont#4},% sort={#4}, - first={#4},% - firstplural={#4\acrpluralsuffix},% text={#4},% plural={#4\acrpluralsuffix},% symbol={#3},% @@ -1545,8 +1563,8 @@ firstplural={\@glo@descplural\space (\@glo@plural)},% firstplural={#4\acrpluralsuffix},% text={#3},% plural={#3\acrpluralsuffix},% - symbol={#3},% - symbolplural={#3\acrpluralsuffix},% + symbol={\@glo@text},% + symbolplural={\@glo@plural},% #1}} \def\glsshortkey{text}% \def\glsshortpluralkey{plural}% @@ -1576,7 +1594,7 @@ firstplural={\@glo@descplural\space (\@glo@plural)},% (\acronymfont{\@glssymbolplural@{#1}{#2}[#3]})} \def\@ACRfullpl#1#2[#3]{\@GLSfirstplural@{#1}{#2}[#3] (\acronymfont{\@GLSsymbolplural@{#1}{#2}[#3]})} - \defglsdisplayfirst[\acronymtype]{#1#4 (\acronymfont{#3})} + \defglsdisplayfirst[\acronymtype]{#1#4 (\firstacronymfont{#3})} \defglsdisplay[\acronymtype]{\acronymfont{#1}#4} \ifglsacrsmallcaps \renewcommand{\acronymfont}[1]{\textsc{#1}} @@ -1605,7 +1623,7 @@ firstplural={\@glo@descplural\space (\@glo@plural)},% \def\glslongkey{description}% \def\glslongpluralkey{descriptionplural}% \defglsdisplayfirst[\acronymtype]{% - \acronymfont{#1}#4\noexpand\protect\noexpand\footnote{% + \firstacronymfont{#1}#4\noexpand\protect\noexpand\footnote{% \noexpand\protect\noexpand\glslink [\@gls@link@opts]{\@gls@link@label}{#2}}}% \defglsdisplay[\acronymtype]{\acronymfont{#1}#4}% @@ -1652,12 +1670,12 @@ firstplural={\@glo@descplural\space (\@glo@plural)},% \newglossaryentry{#2}{type=\acronymtype,% name={\acronymfont{#3}},% sort={#3},% - text={#3},% - plural={#3\acrpluralsuffix},% + text={\@glo@symbol},% + plural={\@glo@symbolplural},% first={#4},% firstplural={#4\acrpluralsuffix},% - description={#4},% - descriptionplural={#4\acrpluralsuffix},% + description={\@glo@first},% + descriptionplural={\@glo@firstplural},% symbol={#3},% symbolplural={#3\acrpluralsuffix},% #1}} @@ -1665,7 +1683,7 @@ firstplural={\@glo@descplural\space (\@glo@plural)},% \def\glsshortpluralkey{symbolplural}% \def\glslongkey{first}% \def\glslongpluralkey{firstplural}% - \defglsdisplayfirst[\acronymtype]{#1#4 (\acronymfont{#3})} + \defglsdisplayfirst[\acronymtype]{#1#4 (\firstacronymfont{#3})} \defglsdisplay[\acronymtype]{\acronymfont{#1}#4} \ifglsacrsmallcaps \renewcommand*{\acronymfont}[1]{\textsc{#1}} @@ -1712,10 +1730,9 @@ firstplural={\@glo@descplural\space (\@glo@plural)},% \renewcommand{\newacronym}[4][]{% \newglossaryentry{#2}{type=\acronymtype,% name={#3},% - description={#4},% - descriptionplural={#4\acrpluralsuffix},% text={#4},% plural={#4\acrpluralsuffix},% + description={#4},% symbol={#3},% symbolplural={#3\acrpluralsuffix},% #1}} diff --git a/Master/texmf-dist/tex/latex/glossaries/base/mfirstuc.sty b/Master/texmf-dist/tex/latex/glossaries/base/mfirstuc.sty index fee68259460..10832f723f1 100644 --- a/Master/texmf-dist/tex/latex/glossaries/base/mfirstuc.sty +++ b/Master/texmf-dist/tex/latex/glossaries/base/mfirstuc.sty @@ -39,7 +39,7 @@ %% Grave accent \` Left brace \{ Vertical bar \| %% Right brace \} Tilde \~} \NeedsTeXFormat{LaTeX2e} -\ProvidesPackage{mfirstuc}[2008/05/13 v1.01 (NLCT)] +\ProvidesPackage{mfirstuc}[2008/06/18 v1.02 (NLCT)] \newif\if@glscs \def\makefirstuc#1{% \def\gls@argi{#1}% @@ -51,15 +51,21 @@ \if@glscs \@gls@getbody #1{}\@nil \ifx\@gls@rest\@empty - \MakeUppercase #1% + \@gls@makefirstuc{#1}% \else - \@gls@body{\expandafter\@gls@makefirstuc\@gls@rest}% + \expandafter\@gls@split\@gls@rest\@nil + \ifx\@gls@first\@empty + \@gls@makefirstuc{#1}% + \else + \@gls@body{\expandafter\@gls@makefirstuc\@gls@first}\@gls@rest% + \fi \fi \else - \MakeUppercase #1% + \@gls@makefirstuc{#1}% \fi \fi } +\def\@gls@split#1#2\@nil{\def\@gls@first{#1}\def\@gls@rest{#2}} \def\@gls@checkcs#1 #2#3\relax{% \def\@gls@argi{#1}\def\@gls@argii{#2}% \ifx\@gls@argi\@gls@argii diff --git a/Master/texmf-dist/tex/latex/glossaries/styles/glossary-hypernav.sty b/Master/texmf-dist/tex/latex/glossaries/styles/glossary-hypernav.sty index b79b1e8a822..e8d3a4ee331 100644 --- a/Master/texmf-dist/tex/latex/glossaries/styles/glossary-hypernav.sty +++ b/Master/texmf-dist/tex/latex/glossaries/styles/glossary-hypernav.sty @@ -42,40 +42,40 @@ \@ifundefined{hyperlink}{% \newcommand*{\glsnavhyperlink}[3][]{#3}}{% \newcommand*{\glsnavhyperlink}[3][\@glo@type]{% -\edef\gls@grplabel{#2}\edef\@gls@grptitle{#3}% +\edef\gls@grplabel{#2}\protected@edef\@gls@grptitle{#3}% \hyperlink{glsn:#1@#2}{#3}}} \@ifundefined{hypertarget}{% -\newcommand*{\glsnavhypertarget}[3][]{#3}}{% \newcommand*{\glsnavhypertarget}[3][\@glo@type]{% +\protected@write\@auxout{}{\string\@gls@hypergroup{#1}{#2}}% +#3}}{% +\newcommand*{\glsnavhypertarget}[3][\@glo@type]{% +\protected@write\@auxout{}{\string\@gls@hypergroup{#1}{#2}}% \hypertarget{glsn:#1@#2}{#3}}} +\newcommand*{\@gls@hypergroup}[2]{% +\@ifundefined{@gls@hypergrouplist@#1}{% + \expandafter\xdef\csname @gls@hypergrouplist@#1\endcsname{#2}% +}{% + \expandafter\let\expandafter\@gls@tmp + \csname @gls@hypergrouplist@#1\endcsname + \expandafter\xdef\csname @gls@hypergrouplist@#1\endcsname{% + \@gls@tmp,#2}% +}% +} \newcommand*{\glsnavigation}{% -\glssymbolnav -\glsnavhyperlink{A}{\glsgetgrouptitle{A}} \textbar\ -\glsnavhyperlink{B}{\glsgetgrouptitle{B}} \textbar\ -\glsnavhyperlink{C}{\glsgetgrouptitle{C}} \textbar\ -\glsnavhyperlink{D}{\glsgetgrouptitle{D}} \textbar\ -\glsnavhyperlink{E}{\glsgetgrouptitle{E}} \textbar\ -\glsnavhyperlink{F}{\glsgetgrouptitle{F}} \textbar\ -\glsnavhyperlink{G}{\glsgetgrouptitle{G}} \textbar\ -\glsnavhyperlink{H}{\glsgetgrouptitle{H}} \textbar\ -\glsnavhyperlink{I}{\glsgetgrouptitle{I}} \textbar\ -\glsnavhyperlink{J}{\glsgetgrouptitle{J}} \textbar\ -\glsnavhyperlink{K}{\glsgetgrouptitle{K}} \textbar\ -\glsnavhyperlink{L}{\glsgetgrouptitle{L}} \textbar\ -\glsnavhyperlink{M}{\glsgetgrouptitle{M}} \textbar\ -\glsnavhyperlink{N}{\glsgetgrouptitle{N}} \textbar\ -\glsnavhyperlink{O}{\glsgetgrouptitle{O}} \textbar\ -\glsnavhyperlink{P}{\glsgetgrouptitle{P}} \textbar\ -\glsnavhyperlink{Q}{\glsgetgrouptitle{Q}} \textbar\ -\glsnavhyperlink{R}{\glsgetgrouptitle{R}} \textbar\ -\glsnavhyperlink{S}{\glsgetgrouptitle{S}} \textbar\ -\glsnavhyperlink{T}{\glsgetgrouptitle{T}} \textbar\ -\glsnavhyperlink{U}{\glsgetgrouptitle{U}} \textbar\ -\glsnavhyperlink{V}{\glsgetgrouptitle{V}} \textbar\ -\glsnavhyperlink{W}{\glsgetgrouptitle{W}} \textbar\ -\glsnavhyperlink{X}{\glsgetgrouptitle{X}} \textbar\ -\glsnavhyperlink{Y}{\glsgetgrouptitle{Y}} \textbar\ -\glsnavhyperlink{Z}{\glsgetgrouptitle{Z}}} +\def\@gls@between{}% +\@ifundefined{@gls@hypergrouplist@\@glo@type}{% + \def\@gls@list{}% +}{% + \expandafter\let\expandafter\@gls@list + \csname @gls@hypergrouplist@\@glo@type\endcsname +}% +\@for\@gls@tmp:=\@gls@list\do{% + \@gls@between + \glsnavhyperlink{\@gls@tmp}{\glsgetgrouptitle{\@gls@tmp}}% + \let\@gls@between\glshypernavsep% +}% +} +\newcommand*{\glshypernavsep}{\space\textbar\space} \newcommand*{\glssymbolnav}{% \glsnavhyperlink{glssymbols}{\glsgetgrouptitle{glssymbols}} \textbar\ \glsnavhyperlink{glsnumbers}{\glsgetgrouptitle{glsnumbers}} \textbar\ diff --git a/Master/texmf-dist/tex/latex/glossaries/styles/glossary-list.sty b/Master/texmf-dist/tex/latex/glossaries/styles/glossary-list.sty index db784552c3e..36b24637b95 100644 --- a/Master/texmf-dist/tex/latex/glossaries/styles/glossary-list.sty +++ b/Master/texmf-dist/tex/latex/glossaries/styles/glossary-list.sty @@ -52,7 +52,7 @@ \newglossarystyle{listhypergroup}{% \glossarystyle{list}% \renewcommand*{\glossaryheader}{% -\item[]\glsnavigation}% +\item[\glsnavigation]}% \renewcommand*{\glsgroupheading}[1]{% \item[\glsnavhypertarget{##1}{\glsgetgrouptitle{##1}}]}} \newglossarystyle{altlist}{% @@ -66,7 +66,7 @@ \newglossarystyle{altlisthypergroup}{% \glossarystyle{altlist}% \renewcommand*{\glossaryheader}{% -\item[]\glsnavigation}% +\item[\glsnavigation]}% \renewcommand*{\glsgroupheading}[1]{% \item[\glsnavhypertarget{##1}{\glsgetgrouptitle{##1}}]}} \newlength\glslistdottedwidth |