summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/caption/caption3.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/source/latex/caption/caption3.dtx')
-rw-r--r--Master/texmf-dist/source/latex/caption/caption3.dtx26
1 files changed, 22 insertions, 4 deletions
diff --git a/Master/texmf-dist/source/latex/caption/caption3.dtx b/Master/texmf-dist/source/latex/caption/caption3.dtx
index 6a2d11419ab..75d79b1a2ca 100644
--- a/Master/texmf-dist/source/latex/caption/caption3.dtx
+++ b/Master/texmf-dist/source/latex/caption/caption3.dtx
@@ -2,7 +2,7 @@
%
% This is file `caption3.dtx'.
%
-% $Id: caption3.dtx 63 2013-02-03 13:27:05Z sommerfeldt $
+% $Id: caption3.dtx 71 2013-04-14 15:14:26Z sommerfeldt $
% $HeadURL: svn+ssh://sommerfeldt@svn.code.sf.net/p/latex-caption/code/trunk/source/caption3.dtx $
%
% Copyright (C) 1994-2013 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm)
@@ -28,7 +28,7 @@
% and the user manuals caption-deu.tex, caption-eng.tex, and caption-rus.tex.
%
% \fi
-% \CheckSum{3470}
+% \CheckSum{3477}
%
% \iffalse
%<*driver>
@@ -203,7 +203,7 @@
\NeedsTeXFormat{LaTeX2e}[1994/12/01]
\def\caption@tempa$Id: #1 #2 #3-#4-#5 #6${%
\def\caption@tempa{#3/#4/#5 }\def\caption@tempb{#2 }}
-\caption@tempa $Id: caption3.dtx 63 2013-02-03 13:27:05Z sommerfeldt $
+\caption@tempa $Id: caption3.dtx 71 2013-04-14 15:14:26Z sommerfeldt $
\ProvidesPackage{caption3}[\caption@tempa v1.5-\caption@tempb caption3 kernel (AR)]
% \end{macrocode}
%
@@ -3055,7 +3055,8 @@
{\ignorespaces #2}}}}
% \end{macrocode}
% \begin{macrocode}
-\newcommand*\caption@add@contentsline{\caption@@@addcontentsline}
+\newcommand*\caption@add@contentsline{%
+ \caption@@@addcontentsline}
% \end{macrocode}
% \begin{macrocode}
\newcommand*\caption@@@addcontentsline[4]{%
@@ -3259,11 +3260,13 @@
% \changes{v1.1d}{2007/10/23}{`SingleLine' renamed to `singleline' for consistency}
% \changes{v1.3}{2010/09/04}{Split into \cs{caption@slc} and \cs{caption@@slc}}
% \changes{v1.5}{2012/12/26}{Merged into a single macro again}
+% \changes{v3.3}{2013/04/14}{Definition and usage of \cs{ifsinglelinecaption} added}
% |\caption@slc|\marg{label}\marg{text}\marg{single-line-code}\marg{multi-line-code}\par
% This one does the single-line-check.
% \begin{macrocode}
\newcommand\caption@slc[4]{%
\caption@Debug{Begin SLC}%
+ \singlelinecaptiontrue
\begingroup
\caption@singleline
\let\caption@hj\@empty
@@ -3272,6 +3275,7 @@
\sbox\@tempboxa{\caption@@@make{#1}{#2}}%
\ifdim\wd\@tempboxa>\captionwidth
\endgroup
+ \singlelinecaptionfalse
#4%
\else
\endgroup
@@ -3280,6 +3284,9 @@
\caption@Debug{End SLC}}
% \end{macrocode}
% \begin{macrocode}
+\newif\ifsinglelinecaption
+% \end{macrocode}
+% \begin{macrocode}
\newcommand*\caption@singleline{%
\caption@xsetup\caption@opt@singleline
\let\caption@fmt\caption@slfmt}
@@ -3299,6 +3306,7 @@
% \changes{v1.3}{2011/07/07}{Bugfix 11-07-06: Redefinition of \cs{footnote} and \cs{footnotemark} added, redefinition of \cs{stepcounter} and \cs{refstepcounter} dropped}
% \changes{v1.4a}{2011/10/21}{Redefinition of \cs{pagenote} from \textsf{memoir} document class added}
% \changes{v1.4a}{2011/10/22}{Redefinition of \cs{footnote} revised}
+% \changes{v3.3}{2013/04/13}{Redefinition os \cs{glsunset} added}
% Re-define anything which would disturb the single-line-check.
% \begin{macrocode}
\newcommand*\caption@prepareslc{%
@@ -3316,6 +3324,16 @@
% \begin{macrocode}
\let\pagenote\caption@gobble
% \end{macrocode}
+% Adaption to the \package{glossaries} package.\par
+% Please note that while this adaption is usually sufficient
+% it could give incorrect measuring results if \cs{gls} is both used
+% for the very first time and more than once (for a particular acronym).
+% The alternative would be using internal macros of the
+% \package{glossaries} package which I would like to avoid.\par
+% See also \url{http://tex.stackexchange.com/questions/108368}
+% \begin{macrocode}
+ \let\glsunset\@gobble
+% \end{macrocode}
% \begin{macrocode}
}
% \end{macrocode}