summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/caption/subcaption.dtx
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2016-06-12 16:12:11 +0000
committerKarl Berry <karl@freefriends.org>2016-06-12 16:12:11 +0000
commit01c5b7b8dfc848413685e16692be37a4cad2a14a (patch)
treeb0c3b60b2864a8b2d094bdef920cb993da777a94 /Master/texmf-dist/source/latex/caption/subcaption.dtx
parent1da26fe4bf4ac2b50bbce09e9874582c8593a2d3 (diff)
caption (24may16)
git-svn-id: svn://tug.org/texlive/trunk@41409 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex/caption/subcaption.dtx')
-rw-r--r--Master/texmf-dist/source/latex/caption/subcaption.dtx73
1 files changed, 51 insertions, 22 deletions
diff --git a/Master/texmf-dist/source/latex/caption/subcaption.dtx b/Master/texmf-dist/source/latex/caption/subcaption.dtx
index 74ba9ac7b13..5ca25e16531 100644
--- a/Master/texmf-dist/source/latex/caption/subcaption.dtx
+++ b/Master/texmf-dist/source/latex/caption/subcaption.dtx
@@ -2,7 +2,7 @@
%
% This is file `subcaption.dtx'.
%
-% $Id: subcaption.dtx 142 2016-02-20 19:59:43Z sommerfeldt $
+% $Id: subcaption.dtx 161 2016-05-22 14:39:14Z sommerfeldt $
% $HeadURL: svn+ssh://sommerfeldt@svn.code.sf.net/p/latex-caption/code/branches/3.3/source/subcaption.dtx $
%
% Copyright (C) 2007-2016 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{147}
+% \CheckSum{165}
%
% \iffalse
%<*driver>
@@ -903,7 +903,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: subcaption.dtx 142 2016-02-20 19:59:43Z sommerfeldt $
+\caption@tempa $Id: subcaption.dtx 161 2016-05-22 14:39:14Z sommerfeldt $
\ProvidesPackage{subcaption}[\caption@tempa v1.1-\caption@tempb Sub-captions (AR)]
% \end{macrocode}
%
@@ -913,32 +913,61 @@
% \begin{macrocode}
\RequirePackage{caption}[2012/03/25] % needs v3.3 or newer
% \end{macrocode}
-% \changes{v1.1}{2011/09/01}{Compatibility error added}
-% \begin{macrocode}
-\caption@AtBeginDocument{\caption@ifcompatibility{%
- \caption@Error{%
- The `subcaption' package does not work correctly\MessageBreak
- in compatibility mode}}{}}
-% \end{macrocode}
%
+% \begin{macro}{\subcaption@CheckCompatibility}
+% \changes{v1.1}{2011/09/01}{Compatibility error added}
+% \changes{v1.1}{2016/05/22}{The presence of \package{subfigure} or \package{subfig} will be checked \cs{AtBeginDocument}, too}
% Since we are incompatible to them an error message will be issued when
% the \package{subfigure} or \package{subfig} package is loaded.
% \begin{macrocode}
-\@ifpackageloaded{subfigure}{%
- \PackageError{subcaption}%
- {This package can't be used in cooperation\MessageBreak
- with the subfigure package}%
- {RTFM}%
- \endinput}{}%
+\newcommand\subcaption@CheckCompatibility{%
+% \end{macrocode}
+% \begin{macrocode}
+ \@ifpackageloaded{subfigure}{%
+ \PackageError{subcaption}%
+ {This package can't be used in cooperation\MessageBreak
+ with the subfigure package}%
+ {\subcaption@EH}%
+ \endinput}{}%
% \end{macrocode}
% \begin{macrocode}
-\@ifpackageloaded{subfig}{%
- \PackageError{subcaption}%
- {This package can't be used in cooperation\MessageBreak
- with the subfig package}%
- {RTFM}%
- \endinput}{}%
+ \@ifpackageloaded{subfig}{%
+ \PackageError{subcaption}%
+ {This package can't be used in cooperation\MessageBreak
+ with the subfig package}%
+ {\subcaption@EH}%
+ \endinput}{}%
% \end{macrocode}
+% \begin{macrocode}
+}
+% \end{macrocode}
+% \begin{macrocode}
+\newcommand*\subcaption@EH{%
+ If you do not understand this error, please take a closer look\MessageBreak
+ at the documentation of the `subcaption' package, especially the\MessageBreak
+ section about errors.\MessageBreak\@ehc}
+% \end{macrocode}
+% \begin{macrocode}
+\subcaption@CheckCompatibility
+% \end{macrocode}
+% \begin{macrocode}
+\caption@AtBeginDocument{%
+% \end{macrocode}
+% \begin{macrocode}
+ \caption@ifcompatibility{%
+ \caption@Error{%
+ The `subcaption' package does not work correctly\MessageBreak
+ in compatibility mode}}{}%
+% \end{macrocode}
+% \begin{macrocode}
+ \subcaption@CheckCompatibility
+ \let\subcaption@CheckCompatibility\@undefined
+ \let\subcaption@EH\@undefined
+% \end{macrocode}
+% \begin{macrocode}
+}
+% \end{macrocode}
+% \end{macro}
%
% \iffalse
% \subsection{Declaration of options}