Debian Codegraph @

texmf-dist/tex/latex/caption/caption_2011-11-10.sty

raw
1 %%
2 %% This is file `caption_2011-11-10.sty',
3 %% generated with the docstrip utility.
4 %%
5 %% The original source files were:
6 %%
7 %% fallback/v3.2/caption.dtx (with options: `package')
8 %%
9 %% Copyright (C) 1994-2023 Axel Sommerfeldt ([email protected])
10 %%
11 %% https://gitlab.com/axelsommerfeldt/caption
12 %%
13 %% --------------------------------------------------------------------------
14 %%
15 %% This work may be distributed and/or modified under the
16 %% conditions of the LaTeX Project Public License, either version 1.3
17 %% of this license or (at your option) any later version.
18 %% The latest version of this license is in
19 %% http://www.latex-project.org/lppl.txt
20 %% and version 1.3 or later is part of all distributions of LaTeX
21 %% version 2003/12/01 or later.
22 %%
23 %% This work has the LPPL maintenance status "maintained".
24 %%
25 %% This Current Maintainer of this work is Axel Sommerfeldt.
26 %%
27 %% This work consists of the files
28 %% caption.ins, caption.dtx, caption-light.dtx, caption2.dtx, caption3.dtx,
29 %% caption-ams-smf.dtx, caption-beamer.dtx, caption-elsarticle.dtx,
30 %% caption-koma.dtx, caption-memoir.dtx, caption-ntg.dtx,
31 %% caption-thesis.dtx, bicaption.dtx, ltcaption.dtx, subcaption.dtx,
32 %% the derived files
33 %% caption.sty, caption-light.sty, caption2.sty, caption3.sty,
34 %% caption-ams-smf.sto, caption-beamer.sto, caption-elsarticle.sto,
35 %% caption-koma.sto, caption-memoir.sto, caption-ntg.sto,
36 %% caption-thesis.sto, bicaption.sty, ltcaption.sty, subcaption.sty.
37 %%
38 \NeedsTeXFormat{LaTeX2e}[1994/12/01]
39 \ProvidesPackage{caption}[2023/08/05 v3.2g Customizing captions (AR)]
40 \RequirePackage{caption3}[=2011/08/30] % needs v1.4 or newer
41 \caption@ifbool{documentclass}{}{%
42 \caption@WarningNoLine{%
43 Unsupported document class (or package) detected,\MessageBreak
44 usage of the caption package is not recommended}%
45 \caption@InfoNoLine{\string\@makecaption\space=\space\meaning\@makecaption}%
46 }
47 \@ifpackageloaded{caption2}{%
48 \caption@Error{%
49 You can't use both, the (obsolete) caption2 *and*\MessageBreak
50 the (current) caption package}%
51 \endinput
52 }{}
53 \caption@AtBeginDocument{%
54 \@ifpackageloaded{ftcap}{\caption@DisablePositionOption{ftcap}}{}%
55 \@ifpackageloaded{nonfloat}{\caption@DisablePositionOption{nonfloat}}{}%
56 \@ifpackageloaded{topcapt}{\caption@DisablePositionOption{topcapt}}{}}
57 \newcommand*\caption@DisablePositionOption[1]{%
58 \caption@InfoNoLine{%
59 `#1' package detected; setting `position=b' for compatibility reasons}%
60 \caption@setposition b%
61 \DeclareCaptionOption{position}{%
62 \caption@Error{Usage of the `position' option is incompatible\MessageBreak
63 to the `#1' package}}}
64 \@onlypreamble\caption@DisablePositionOption
65 \DeclareCaptionOption{figureposition}{%
66 \captionsetup*[figure]{position=#1}}
67 \@onlypreamble@key{caption}{figureposition}
68 \DeclareCaptionOption{tableposition}{%
69 \captionsetup*[table]{position=#1}}
70 \@onlypreamble@key{caption}{tableposition}
71 \DeclareCaptionOption{figurename}{\caption@SetName{figure}{#1}}
72 \DeclareCaptionOption{tablename}{\caption@SetName{table}{#1}}
73 \DeclareCaptionOption{name}{\caption@setname\@captype{#1}}
74 \DeclareCaptionOption{listfigurename}{\caption@SetName{listfigure}{#1}}
75 \DeclareCaptionOption{listtablename}{\caption@SetName{listtable}{#1}}
76 \newcommand*\caption@SetName{%
77 \RequirePackage{newfloat}%
78 \newfloat@setname}
79 \newcommand*\caption@setname[2]{\@namedef{#1name}{#2}}
80 \caption@AtBeginDocument{\let\caption@SetName\caption@setname}
81 \newcommand*\caption@DeclareWithinOption[1]{%
82 \DeclareCaptionOption{#1within}{\caption@Within{#1}{##1}}%
83 \DeclareCaptionOptionNoValue{#1without}{\caption@Within{#1}{none}}}
84 \@onlypreamble\caption@DeclareWithinOption
85 \caption@DeclareWithinOption{figure}
86 \caption@DeclareWithinOption{table}
87 \DeclareCaptionOption{within}{%
88 \RequirePackage{newfloat}%
89 \newfloatsetup{within=#1}}
90 \DeclareCaptionOptionNoValue{without}{%
91 \RequirePackage{newfloat}%
92 \newfloatsetup{without}}
93 \newcommand*\caption@Within{%
94 \RequirePackage{newfloat}%
95 \newfloat@setwithin}
96 \DeclareCaptionOption*{config}[caption]{%
97 \InputIfFileExists{#1.cfg}%
98 {\typeout{*** Local configuration file #1.cfg used ***}}%
99 {\caption@Warning{Configuration file #1.cfg not found}}}
100 \newcommand*\caption@setparboxrestore[1]{%
101 \caption@ifinlist{#1}{full}{%
102 \caption@setfullparboxrestore
103 }{\caption@ifinlist{#1}{default,light,partial}{%
104 \let\caption@parboxrestore\@secondoftwo
105 }{%
106 \caption@Error{Undefined parboxrestore `#1'}%
107 }}}
108 \newcommand*\caption@setfullparboxrestore{%
109 \let\caption@parboxrestore\@firstoftwo}
110 \DeclareCaptionOption{parboxrestore}{\caption@setparboxrestore{#1}}
111 \captionsetup{parboxrestore=default}
112 \DeclareCaptionOption{@minipage}{%
113 \caption@ifinlist{#1}{auto,default}%
114 {\let\caption@if@minipage\@gobbletwo}%
115 {\caption@set@bool\caption@if@minipage{#1}}}
116 \captionsetup{@minipage=default}
117 \DeclareCaptionOption{compatibility}[1]{\caption@setbool{compatibility}{#1}}
118 \@onlypreamble@key{caption}{compatibility}
119 \DeclareCaptionOptionNoValue*{normal}{%
120 \caption@setformat{plain}%
121 \caption@setjustification{justified}}
122 \DeclareCaptionOptionNoValue*{isu}{%
123 \caption@setformat{hang}%
124 \caption@setjustification{justified}}
125 \DeclareCaptionOptionNoValue*{hang}{%
126 \caption@setformat{hang}%
127 \caption@setjustification{justified}}
128 \DeclareCaptionOptionNoValue*{center}{%
129 \caption@setformat{plain}%
130 \caption@setjustification{centering}}
131 \DeclareCaptionOptionNoValue*{anne}{%
132 \caption@setformat{plain}%
133 \caption@setjustification{centerlast}}
134 \DeclareCaptionOptionNoValue*{centerlast}{%
135 \caption@setformat{plain}%
136 \caption@setjustification{centerlast}}
137 \DeclareCaptionOptionNoValue*{scriptsize}{\def\captionfont{\scriptsize}}
138 \DeclareCaptionOptionNoValue*{footnotesize}{\def\captionfont{\footnotesize}}
139 \DeclareCaptionOptionNoValue*{small}{\def\captionfont{\small}}
140 \DeclareCaptionOptionNoValue*{normalsize}{\def\captionfont{\normalsize}}
141 \DeclareCaptionOptionNoValue*{large}{\def\captionfont{\large}}
142 \DeclareCaptionOptionNoValue*{Large}{\def\captionfont{\Large}}
143 \DeclareCaptionOptionNoValue*{up}{\l@addto@macro\captionlabelfont\upshape}
144 \DeclareCaptionOptionNoValue*{it}{\l@addto@macro\captionlabelfont\itshape}
145 \DeclareCaptionOptionNoValue*{sl}{\l@addto@macro\captionlabelfont\slshape}
146 \DeclareCaptionOptionNoValue*{sc}{\l@addto@macro\captionlabelfont\scshape}
147 \DeclareCaptionOptionNoValue*{md}{\l@addto@macro\captionlabelfont\mdseries}
148 \DeclareCaptionOptionNoValue*{bf}{\l@addto@macro\captionlabelfont\bfseries}
149 \DeclareCaptionOptionNoValue*{rm}{\l@addto@macro\captionlabelfont\rmfamily}
150 \DeclareCaptionOptionNoValue*{sf}{\l@addto@macro\captionlabelfont\sffamily}
151 \DeclareCaptionOptionNoValue*{tt}{\l@addto@macro\captionlabelfont\ttfamily}
152 \DeclareCaptionOptionNoValue*{nooneline}{\caption@setbool{slc}{0}}
153 \caption@setbool{ruled}{0}
154 \DeclareCaptionOptionNoValue*{ruled}{\caption@setbool{ruled}{1}}
155 \DeclareCaptionOptionNoValue*{flushleft}{%
156 \caption@setformat{plain}%
157 \caption@setjustification{raggedright}}
158 \DeclareCaptionOptionNoValue*{flushright}{%
159 \caption@setformat{plain}%
160 \caption@setjustification{raggedleft}}
161 \DeclareCaptionOptionNoValue*{oneline}{\caption@setbool{slc}{1}}
162 \DeclareCaptionOptionNoValue*{ignoreLTcapwidth}{%
163 \caption@WarningNoLine{Obsolete option `ignoreLTcapwidth' ignored}}
164 \DeclareCaptionOption*{caption}{%
165 \caption@setbool{temp}{#1}%
166 \caption@ifbool{temp}{}{%
167 \caption@Error{%
168 The package option `caption=#1' is obsolete.\MessageBreak
169 Please pass this option to the subfig package instead\MessageBreak
170 and do *not* load the caption package anymore}}}
171 \DeclareCaptionOption{FPlist}[1]{\caption@setFPoption{list}{#1}}
172 \DeclareCaptionOption{FPref}[1]{\caption@setFPoption{ref}{#1}}
173 \@onlypreamble@key{caption}{FPlist}
174 \@onlypreamble@key{caption}{FPref}
175 \newcommand*\caption@setFPoption[2]{%
176 \edef\caption@tempa{\@car#2\@nil}%
177 \caption@setbool{FP#1cap}{\if c\caption@tempa 1\else 0\fi}}
178 \@onlypreamble\caption@setFPoption
179 \captionsetup{FPlist=caption,FPref=figure}
180 \DeclareCaptionOption{hypcap}[1]{\caption@setbool{hypcap}{#1}}
181 \DeclareCaptionOption{hypcapspace}{\def\caption@hypcapspace{#1}}
182 \captionsetup{hypcap=1,hypcapspace=.5\baselineskip}
183 \caption@ifamsclass{%
184 \caption@InfoNoLine{AMS or SMF document class}%
185 \setlength\belowcaptionskip{0pt}% set to 12pt by AMS class
186 }
187 \caption@ifkomaclass{%
188 \caption@InfoNoLine{KOMA-Script document class}%
189 \g@addto@macro\@tablecaptionabovetrue{\captionsetup*[table]{position=t}}
190 \g@addto@macro\@tablecaptionabovefalse{\captionsetup*[table]{position=b}}
191 \if@tablecaptionabove
192 \@tablecaptionabovetrue
193 \else
194 \@tablecaptionabovefalse
195 \fi
196 \g@addto@macro\onelinecaptionstrue{\let\caption@ifslc\@firstoftwo}
197 \g@addto@macro\onelinecaptionsfalse{\let\caption@ifslc\@secondoftwo}
198 \ifonelinecaptions
199 \onelinecaptionstrue
200 \else
201 \onelinecaptionsfalse
202 \fi
203 \g@addto@macro\@captionabovetrue{\let\caption@position\@firstoftwo}
204 \g@addto@macro\@captionabovefalse{\let\caption@position\@secondoftwo}
205 \DeclareCaptionOption{figureposition}{%
206 \caption@WarningNoLine{Option `figureposition=#1' has no effect\MessageBreak
207 when used with a KOMA script document class}}
208 \DeclareCaptionOption{tableposition}{%
209 \caption@WarningNoLine{Option `tableposition=#1' has no effect\MessageBreak
210 when used with a KOMA script document class}}
211 \let\caption@KOMA@setcapindent\@setcapindent
212 \renewcommand*\@setcapindent[1]{%
213 \caption@KOMA@setcapindent{#1}\caption@setcapindent}
214 \let\caption@KOMA@@setcapindent\@@setcapindent
215 \renewcommand*\@@setcapindent[1]{%
216 \caption@KOMA@@setcapindent{#1}\caption@setcapindent}
217 \newcommand*\caption@setcapindent{%
218 \captionsetup{indent=\ifdim\cap@indent<\z@\z@\else\cap@indent\fi}}
219 \caption@ifundefined\cap@indent{}{\caption@setcapindent}
220 \expandafter\let\expandafter\caption@KOMA@setcapwidth
221 \csname\string\setcapwidth\endcsname
222 \@namedef{\string\setcapwidth}[#1]#2{%
223 \caption@KOMA@setcapwidth[#1]{#2}\caption@setcapwidth{#1}}
224 \newcommand*\caption@setcapwidth[1]{%
225 \ifx\\#1\\\else
226 \caption@ifundefined\cap@margin{}{%
227 \def\@tempa{captionbeside}%
228 \ifx\@tempa\@currenvir\else\caption@Warning{%
229 Ignoring optional argument [#1] of \string\setcapwidth\MessageBreak}%
230 \fi}%
231 \fi
232 \captionsetup{width=\cap@width}}
233 \def\caption@tempa{\hsize}%
234 \ifx\caption@tempa\cap@width \else
235 \caption@setcapwidth{?}
236 \fi
237 \expandafter\let\expandafter\caption@KOMA@setcapmargin
238 \csname\string\@setcapmargin\endcsname
239 \@namedef{\string\@setcapmargin}[#1]#2{%
240 \caption@KOMA@setcapmargin[#1]{#2}\caption@setcapmargin}
241 \expandafter\let\expandafter\caption@KOMA@@setcapmargin
242 \csname\string\@@setcapmargin\endcsname
243 \@namedef{\string\@@setcapmargin}[#1]#2{%
244 \caption@KOMA@@setcapmargin[#1]{#2}\caption@setcapmargin}
245 \newcommand*\caption@setcapmargin{%
246 \begingroup
247 \let\onelinecaptionsfalse\relax
248 \def\@twoside{0}%
249 \def\if@twoside{\def\@twoside{1}\iffalse}%
250 \cap@margin
251 \def\@tempa{\endgroup}%
252 \ifx\cap@left\hfill\else\ifx\cap@right\hfill\else
253 \def\hspace##1##{\@firstofone}%
254 \edef\@tempa{\endgroup
255 \noexpand\captionsetup{%
256 twoside=\@twoside,slc=0,%
257 margin={\cap@left,\cap@right}}}%
258 \fi\fi
259 \@tempa}
260 \ifx\cap@margin\relax \else
261 \caption@setcapmargin
262 \fi
263 }
264 \caption@SetupOptions{caption}{\caption@setkeys{#1}{#2}}
265 \caption@ProcessOptions*{caption}
266 \def\caption@caption{%
267 \caption@iftype
268 {\caption@checkgrouplevel\@empty\caption
269 \caption@star
270 {\@nameuse{donemaincaptiontrue}%
271 \caption@refstepcounter\@captype}%
272 {\caption@dblarg{\@caption\@captype}}}%
273 {\caption@Error{\noexpand\caption outside float}%
274 \caption@gobble}}
275 \newcommand*\caption@star[2]{%
276 \@ifstar{\caption@startrue#2[]}{#1#2}}
277 \long\def\caption@@caption#1[#2]#3{%
278 \ifcaption@star \else
279 \caption@prepareanchor{#1}{#2}%
280 \M@gettitle{#2}%
281 \memcaptioninfo{#1}{\csname the#1\endcsname}{#2}{#3}%
282 \fi
283 \par
284 \caption@beginex{#1}{#2}{#3}%
285 \caption@setfloatcapt{%
286 \caption@boxrestore
287 \if@minipage
288 \@setminipage
289 \fi
290 \caption@normalsize
291 \ifcaption@star
292 \let\caption@makeanchor\@firstofone
293 \fi
294 \@makecaption{\csname fnum@#1\endcsname}%
295 {\ignorespaces\caption@makeanchor{#3}}\par
296 \caption@if@minipage\@minipagetrue\@minipagefalse}%
297 \caption@end}
298 \providecommand\M@gettitle[1]{}
299 \providecommand\memcaptioninfo[4]{}
300 \newcommand*\caption@prepareanchor[2]{%
301 \caption@makecurrent{#1}{#2}%
302 \caption@ifhypcap\caption@@start{}}
303 \long\def\caption@makecaption#1#2{%
304 \caption@iftop
305 {\vskip\belowcaptionskip}%
306 {\caption@rule\vskip\abovecaptionskip}%
307 \caption@@make{#1}{#2}%
308 \caption@iftop
309 {\vskip\abovecaptionskip\caption@rule}%
310 {\vskip\belowcaptionskip}}
311 \newcommand*\caption@redefine{}
312 \g@addto@macro\caption@redefine{%
313 \caption@setbool{incompatible}{0}%
314 \caption@CheckCommand\caption{%
315 % ltfloat.dtx [2002/10/01 v1.1v LaTeX Kernel (Floats)]
316 \def\caption{%
317 \ifx\@captype\@undefined
318 \@latex@error{\noexpand\caption outside float}\@ehd
319 \expandafter\@gobble
320 \else
321 \refstepcounter\@captype
322 \expandafter\@firstofone
323 \fi
324 {\@dblarg{\@caption\@captype}}%
325 }}%
326 \caption@CheckCommand\caption{%
327 % beamerbaselocalstructure.sty,v 1.53 2007/01/28 20:48:21 tantau
328 \def\caption{
329 \ifx\@captype\@undefined
330 \@latex@error{\noexpand\caption outside figure or table}\@ehd
331 \expandafter\@gobble
332 \else
333 \refstepcounter\@captype
334 \expandafter\@firstofone
335 \fi
336 {\@dblarg{\@caption\@captype}}%
337 }}%
338 \caption@CheckCommand\caption{%
339 % float.sty [2001/11/08 v1.3d Float enhancements (AL)]
340 \renewcommand\caption{%
341 \ifx\@captype\@undefined
342 \@latex@error{\noexpand\caption outside float}\@ehd
343 \expandafter\@gobble
344 \else
345 \refstepcounter\@captype
346 \let\@tempf\@caption
347 \expandafter\ifx\csname @float@c@\@captype\endcsname\relax\else
348 \expandafter\expandafter\let
349 \expandafter\@tempf\csname @float@c@\@captype\endcsname
350 \fi
351 \fi
352 \@dblarg{\@tempf\@captype}}}%
353 \caption@CheckCommand\caption{%
354 % hyperref.sty [2007/02/27 v6.75t Hypertext links for LaTeX]
355 % hyperref.sty [2007/04/09 v6.76a Hypertext links for LaTeX]
356 % hyperref.sty [2007/06/12 v6.76h Hypertext links for LaTeX]
357 \def\caption{%
358 \ifx\@captype\@undefined
359 \@latex@error{\noexpand\caption outside float}\@ehd
360 \expandafter\@gobble
361 \else
362 \H@refstepcounter\@captype
363 \@ifundefined{fst@\@captype}{%
364 \let\Hy@tempa\@caption
365 }{%
366 \let\Hy@tempa\Hy@float@caption
367 }%
368 \expandafter\@firstofone
369 \fi
370 {\@dblarg{\Hy@tempa\@captype}}%
371 }}%
372 \caption@CheckCommand\caption{%
373 % hyperref.sty [2007/08/05 v6.76j Hypertext links for LaTeX]
374 \def\caption{%
375 \ifx\@captype\@undefined
376 \@latex@error{\noexpand\caption outside float}\@ehd
377 \expandafter\@gobble
378 \else
379 \H@refstepcounter\@captype
380 \let\Hy@tempa\@caption
381 \@ifundefined{float@caption}{%
382 }{%
383 \expandafter\ifx\csname @float@c@\@captype\endcsname\float@caption
384 \let\Hy@tempa\Hy@float@caption
385 \fi
386 }%
387 \expandafter\@firstofone
388 \fi
389 {\@dblarg{\Hy@tempa\@captype}}%
390 }}%
391 \caption@CheckCommand\caption{%
392 % memhfixc.sty [2010/08/17 v1.15 nameref/hyperref package fixes for memoir class]
393 % \let\m@moldhypcaption\caption
394 \renewcommand{\caption}{\donemaincaptiontrue\m@moldhypcaption}}%
395 \caption@IfCheckCommand{}{%
396 \caption@InfoNoLine{%
397 Incompatible package detected (regarding \string\caption).\MessageBreak
398 \string\caption\space=\space\meaning\caption}%
399 \caption@setbool{incompatible}{1}}%
400 \caption@CheckCommand\@caption{%
401 % ltfloat.dtx [2002/10/01 v1.1v LaTeX Kernel (Floats)]
402 \long\def\@caption#1[#2]#3{%
403 \par
404 \addcontentsline{\csname ext@#1\endcsname}{#1}%
405 {\protect\numberline{\csname the#1\endcsname}{\ignorespaces #2}}%
406 \begingroup
407 \@parboxrestore
408 \if@minipage
409 \@setminipage
410 \fi
411 \normalsize
412 \@makecaption{\csname fnum@#1\endcsname}{\ignorespaces #3}\par
413 \endgroup}}%
414 \caption@CheckCommand\@caption{%
415 % beamerbaselocalstructure.sty,v 1.53 2007/01/28 20:48:21 tantau
416 \long\def\@caption#1[#2]#3{% second argument ignored
417 \par\nobreak
418 \begingroup
419 \@parboxrestore
420 \if@minipage
421 \@setminipage
422 \fi
423 \beamer@makecaption{#1}{\ignorespaces #3}\par\nobreak
424 \endgroup}}%
425 \caption@CheckCommand\@caption{%
426 % magyar.ldf [2005/03/30 v1.4j Magyar support from the babel system]
427 \long\def\@caption#1[#2]#3{%
428 \csname par\endcsname
429 \addcontentsline{\csname ext@#1\endcsname}{#1}%
430 {\protect\numberline{\csname the#1\endcsname.}{\ignorespaces #2}}%
431 \begingroup
432 \@parboxrestore
433 \if@minipage
434 \@setminipage
435 \fi
436 \normalsize
437 \@makecaption{\csname fnum@#1\endcsname}%
438 {\ignorespaces #3}\csname par\endcsname
439 \endgroup}}%
440 \caption@CheckCommand\@caption{%
441 % hyperref.sty [2007/02/27 v6.75t Hypertext links for LaTeX]
442 \long\def\@caption#1[#2]#3{%
443 \hyper@makecurrent{\@captype}%
444 \def\@currentlabelname{#2}%
445 \par\addcontentsline{\csname ext@#1\endcsname}{#1}{%
446 \protect\numberline{\csname the#1\endcsname}{\ignorespaces #2}%
447 }%
448 \begingroup
449 \@parboxrestore
450 \if@minipage
451 \@setminipage
452 \fi
453 \normalsize
454 \@makecaption{\csname fnum@#1\endcsname}{%
455 \ignorespaces
456 \ifHy@nesting
457 \hyper@@anchor{\@currentHref}{#3}%
458 \else
459 \Hy@raisedlink{\hyper@@anchor{\@currentHref}{\relax}}#3%
460 \fi
461 }%
462 \par
463 \endgroup
464 }}%
465 \caption@CheckCommand\@caption{%
466 % hyperref.sty [2007/04/09 v6.76a Hypertext links for LaTeX]
467 % hyperref.sty [2007/06/12 v6.76h Hypertext links for LaTeX]
468 % hyperref.sty [2007/08/05 v6.76j Hypertext links for LaTeX]
469 \long\def\@caption#1[#2]#3{%
470 \expandafter\ifx\csname if@capstart\expandafter\endcsname
471 \csname iftrue\endcsname
472 \global\let\@currentHref\hc@currentHref
473 \else
474 \hyper@makecurrent{\@captype}%
475 \fi
476 \def\@currentlabelname{#2}%
477 \par\addcontentsline{\csname ext@#1\endcsname}{#1}{%
478 \protect\numberline{\csname the#1\endcsname}{\ignorespaces #2}%
479 }%
480 \begingroup
481 \@parboxrestore
482 \if@minipage
483 \@setminipage
484 \fi
485 \normalsize
486 \expandafter\ifx\csname if@capstart\expandafter\endcsname
487 \csname iftrue\endcsname
488 \global\@capstartfalse
489 \@makecaption{\csname fnum@#1\endcsname}{\ignorespaces#3}%
490 \else
491 \@makecaption{\csname fnum@#1\endcsname}{%
492 \ignorespaces
493 \ifHy@nesting
494 \hyper@@anchor{\@currentHref}{#3}%
495 \else
496 \Hy@raisedlink{\hyper@@anchor{\@currentHref}{\relax}}#3%
497 \fi
498 }%
499 \fi
500 \par
501 \endgroup
502 }}%
503 \caption@CheckCommand\@caption{%
504 % hyperref.sty [2009/11/27 v6.79k Hypertext links for LaTeX]
505 \long\def\@caption#1[#2]#3{%
506 \expandafter\ifx\csname if@capstart\expandafter\endcsname
507 \csname iftrue\endcsname
508 \global\let\@currentHref\hc@currentHref
509 \else
510 \hyper@makecurrent{\@captype}%
511 \fi
512 \def\@currentlabelname{#2}%
513 \par\addcontentsline{\csname ext@#1\endcsname}{#1}{%
514 \protect\numberline{\csname the#1\endcsname}{\ignorespaces #2}%
515 }%
516 \begingroup
517 \@parboxrestore
518 \if@minipage
519 \@setminipage
520 \fi
521 \normalsize
522 \expandafter\ifx\csname if@capstart\expandafter\endcsname
523 \csname iftrue\endcsname
524 \global\@capstartfalse
525 \@makecaption{\csname fnum@#1\endcsname}{\ignorespaces#3}%
526 \else
527 \@makecaption{\csname fnum@#1\endcsname}{%
528 \ignorespaces
529 \ifHy@nesting
530 \expandafter\hyper@@anchor\expandafter{\@currentHref}{#3}%
531 \else
532 \Hy@raisedlink{%
533 \expandafter\hyper@@anchor\expandafter{\@currentHref}{\relax}%
534 }%
535 #3%
536 \fi
537 }%
538 \fi
539 \par
540 \endgroup
541 }}%
542 \caption@CheckCommand\@caption{%
543 % hyperref.sty [2009/12/09 v6.79m Hypertext links for LaTeX]
544 % hyperref.sty [2009/12/28 v6.79z Hypertext links for LaTeX]
545 \long\def\@caption#1[#2]#3{%
546 \expandafter\ifx\csname if@capstart\expandafter\endcsname
547 \csname iftrue\endcsname
548 \global\let\@currentHref\hc@currentHref
549 \else
550 \hyper@makecurrent{\@captype}%
551 \fi
552 \@ifundefined{NR@gettitle}{%
553 \def\@currentlabelname{#2}%
554 }{%
555 \NR@gettitle{#2}%
556 }%
557 \par\addcontentsline{\csname ext@#1\endcsname}{#1}{%
558 \protect\numberline{\csname the#1\endcsname}{\ignorespaces #2}%
559 }%
560 \begingroup
561 \@parboxrestore
562 \if@minipage
563 \@setminipage
564 \fi
565 \normalsize
566 \expandafter\ifx\csname if@capstart\expandafter\endcsname
567 \csname iftrue\endcsname
568 \global\@capstartfalse
569 \@makecaption{\csname fnum@#1\endcsname}{\ignorespaces#3}%
570 \else
571 \@makecaption{\csname fnum@#1\endcsname}{%
572 \ignorespaces
573 \ifHy@nesting
574 \expandafter\hyper@@anchor\expandafter{\@currentHref}{#3}%
575 \else
576 \Hy@raisedlink{%
577 \expandafter\hyper@@anchor\expandafter{%
578 \@currentHref
579 }{\relax}%
580 }%
581 #3%
582 \fi
583 }%
584 \fi
585 \par
586 \endgroup
587 }}%
588 \caption@CheckCommand\@caption{%
589 % nameref.sty [2006/12/27 v2.28 Cross-referencing by name of section]
590 \long\def\@caption#1[#2]{%
591 \def\@currentlabelname{#2}%
592 \NR@@caption{#1}[{#2}]%
593 }}%
594 \caption@CheckCommand\@caption{%
595 % nameref.sty [2009/11/27 v2.32 Cross-referencing by name of section]
596 \long\def\@caption#1[#2]{%
597 \NR@gettitle{#2}%
598 \NR@@caption{#1}[{#2}]%
599 }}%
600 \caption@CheckCommand\@caption{%
601 % subfigure.sty [2002/07/30 v2.1.4 subfigure package]
602 \long\def\@caption#1[#2]#3{%
603 \@ifundefined{if#1topcap}%
604 {\subfig@oldcaption{#1}[{#2}]{#3}}%
605 {\@nameuse{if#1topcap}%
606 \@listsubcaptions{#1}%
607 \subfig@oldcaption{#1}[{#2}]{#3}%
608 \else
609 \subfig@oldcaption{#1}[{#2}]{#3}%
610 \@listsubcaptions{#1}%
611 \fi}}}%
612 \caption@CheckCommand\@caption{%
613 % subfig.sty [2005/06/28 ver: 1.3 subfig package]
614 \def\@caption{\caption@}%
615 }%
616 \caption@IfCheckCommand{}{%
617 \caption@InfoNoLine{%
618 Incompatible package detected (regarding \string\@caption).\MessageBreak
619 \string\@caption\space=\space\meaning\@caption}%
620 \caption@setbool{incompatible}{1}}%
621 \caption@ifundefined\caption@ifcompatibility
622 {\let\caption@ifcompatibility\caption@ifincompatible
623 \let\caption@tempa\caption@WarningNoLine}%
624 {\let\caption@tempa\@gobble}% suppress warning
625 \caption@ifcompatibility{%
626 \caption@tempa{%
627 \noexpand\caption will not be redefined since it's already\MessageBreak
628 redefined by a document class or package which is\MessageBreak
629 unknown to the caption package}%
630 \renewcommand*\caption@redefine{}%
631 \renewcommand*\caption@ContinuedFloat[1]{%
632 \caption@Error{Not available in compatibility mode}}%
633 \caption@AtBeginDocument*{%
634 \let\caption@start\relax
635 \caption@ifundefined\caption@ORI@capstart{}{%
636 \caption@Debug{%
637 Restore hypcap definition of \string\capstart\@gobble}%
638 \let\capstart\caption@ORI@capstart}%
639 \caption@ifundefined\caption@ORI@float@makebox{}{%
640 \caption@Debug{%
641 Restore hyperref redefinition of \string\float@makebox\@gobble}%
642 \let\float@makebox\caption@ORI@float@makebox}%
643 }%
644 \renewcommand*\caption@star[2]{#1#2}%
645 }{%
646 \caption@ifincompatible{%
647 \caption@WarningNoLine{%
648 Forced redefinition of \noexpand\caption since the\MessageBreak
649 unsupported(!) package option `compatibility=false'\MessageBreak
650 was given}%
651 }{}%
652 \renewcommand*\caption@redefine{%
653 \let\caption\caption@caption
654 \let\@caption\caption@@caption}%
655 \caption@redefine
656 }%
657 \caption@AtBeginDocument*{%
658 \let\caption@ORI@capstart\@undefined
659 \let\caption@ORI@float@makebox\@undefined}%
660 \let\caption@ORI@xfloat\@xfloat
661 \def\@xfloat#1[#2]{%
662 \caption@ORI@xfloat{#1}[#2]%
663 \caption@settype{#1}}%
664 }
665 \caption@AtBeginDocument{\caption@redefine}
666 \let\@makecaption\caption@makecaption
667 \caption@AtBeginDocument{%
668 \DeclareCaptionOption{type}{\setcaptiontype{#1}}%
669 \DeclareCaptionOption{type*}{\setcaptiontype*{#1}}%
670 \DeclareCaptionOptionNoValue{subtype}{\setcaptionsubtype\relax}%
671 \DeclareCaptionOptionNoValue{subtype*}{\setcaptionsubtype*}%
672 }
673 \newcommand\setcaptiontype{%
674 \caption@boxrestore@mini
675 \caption@settype}
676 \newcommand\setcaptionsubtype{%
677 \caption@iftype
678 \caption@setsubtype
679 {\caption@Error{\noexpand\setcaptionsubtype outside float}}}%
680 \newcommand\caption@setsubtype{%
681 \@ifstar
682 {\caption@@settype{sub}*{sub\@captype}}%
683 {\caption@@settype{sub}{sub\@captype}}}%
684 \newcommand*\caption@settype{%
685 \caption@@settype{}}
686 \newcommand*\caption@@settype[1]{%
687 \caption@teststar{\caption@@@settype{#1}}\@firstoftwo\@secondoftwo}
688 \newcommand*\caption@@@settype[3]{%
689 \caption@Debug{#1type=#3}%
690 \caption@checkgrouplevel{#1}{%
691 \captionsetup{#1type#2*\@empty=...}#2{ or
692 \@backslashchar#1captionof}{}}%
693 \edef\caption@tempa{#3}%
694 \expandafter\ifx\csname @#1captype\endcsname\caption@tempa \else
695 \ifcaptionsetup@star\else\@nameuse{caption@#1type@warning}\fi
696 \fi
697 \expandafter\let\csname @#1captype\endcsname\caption@tempa
698 \@nameuse{caption@#1typehook}%
699 \caption@setoptions{#3}%
700 \ifx\caption@opt\relax
701 \@nameundef{caption@#1type@warning}%
702 \else
703 \@namedef{caption@#1type@warning}{\caption@Warning{%
704 The #1caption type was already set to
705 `\csname @#1captype\endcsname'\MessageBreak}}%
706 \fi
707 \let\caption@ifrefstepcounter\@secondoftwo
708 #2{}{%
709 \let\@currentlabel\caption@undefinedlabel
710 \ifx\caption@x@label\@undefined
711 \let\caption@x@label\label
712 \let\label\caption@xlabel
713 \fi
714 \caption@start}}
715 \newcommand*\caption@typehook{}
716 \newcommand*\caption@iftype{%
717 \caption@ifundefined\@captype\@secondoftwo\@firstoftwo}
718 \begingroup\expandafter\expandafter\expandafter\endgroup
719 \expandafter\ifx\csname currentgrouplevel\endcsname\relax
720 \caption@Debug{TeX engine: TeX}
721 \let\caption@checkgrouplevel\@gobbletwo
722 \else
723 \caption@Debug{TeX engine: e-TeX}
724 \newcommand*\caption@checkgrouplevel[2]{%
725 \@ifundefined{#1caption@grouplevel}{%
726 \caption@ifundefined\caption@grouplevel{\let\caption@grouplevel\z@}{}%
727 \ifnum\currentgrouplevel>\caption@grouplevel\relax
728 \expandafter\edef\csname #1caption@grouplevel\endcsname{%
729 \the\currentgrouplevel}%
730 \else
731 \caption@Warning{\string#2\MessageBreak outside box or environment}%
732 \fi
733 }{}}
734 \fi
735 \newcommand*\caption@undefinedlabel{%
736 \protect\caption@xref{\caption@labelname}{\on@line}}
737 \DeclareRobustCommand*\caption@xref[2]{%
738 \caption@WarningNoLine{\noexpand\label without proper \string\caption#2}%
739 \@setref\relax\@undefined{#1}}
740 \newcommand*\caption@labelname{??}
741 \newcommand*\caption@xlabel{%
742 \caption@withoptargs\caption@@xlabel}
743 \newcommand*\caption@@xlabel[2]{%
744 \caption@@@xlabel
745 \def\caption@labelname{#2}%
746 \caption@x@label#1{#2}}
747 \newcommand*\caption@@@xlabel{%
748 \global\let\caption@@@xlabel\@empty
749 \@bsphack
750 \protected@write\@auxout{}%
751 {\string\providecommand*\string\caption@xref[2]{%
752 \string\@setref\string\relax\string\@undefined{\string##1}}}%
753 \@esphack}
754 \caption@AtBeginDocument{%
755 \def\captionof{\caption@teststar\caption@of{\caption*}\caption}}
756 \newcommand*\caption@of[2]{\setcaptiontype*{#2}#1}
757 \newcommand*\captionlistentry{%
758 \caption@teststar\@captionlistentry\@firstoftwo\@secondoftwo}
759 \newcommand*\@captionlistentry[1]{%
760 \@testopt{\caption@listentry{#1}}\@captype}
761 \def\caption@listentry#1[#2]#3{%
762 \@bsphack
763 #1{\caption@gettitle{#3}}%
764 {\caption@refstepcounter{#2}%
765 \caption@makecurrent{#2}{#3}}%
766 \caption@addcontentsline{#2}{#3}%
767 \@esphack}
768 \newcommand*\captionbox{%
769 \let\captionbox@settype\@gobble
770 \caption@withoptargs\caption@box}
771 \newcommand\caption@box[2]{%
772 \@testopt{\caption@ibox{#1}{#2}}{\wd\@tempboxa}}
773 \long\def\caption@ibox#1#2[#3]{%
774 \@testopt{\caption@iibox{#1}{#2}{#3}}\captionbox@hj@default}
775 \long\def\caption@iibox#1#2#3[#4]#5{%
776 \setbox\@tempboxa\hbox{#5}%
777 \begingroup
778 \captionbox@settype*% set \caption@position
779 \caption@iftop{%
780 \endgroup
781 \parbox[t]{#3}{%
782 \captionbox@settype\relax
783 \caption@setposition t%
784 \vbox{\caption#1{#2}}%
785 \captionbox@hrule
786 \csname caption@hj@#4\endcsname
787 \unhbox\@tempboxa}%
788 }{%
789 \endgroup
790 \parbox[b]{#3}{%
791 \captionbox@settype\relax
792 \caption@setposition b%
793 \csname caption@hj@#4\endcsname
794 \unhbox\@tempboxa
795 \captionbox@hrule
796 \vtop{\caption#1{#2}}}%
797 }}
798 \newcommand*\captionbox@hj@default{c}
799 \newcommand*\captionbox@hrule{\hrule\@height\z@\relax}
800 \providecommand*\caption@hj@c{\centering}
801 \providecommand*\caption@hj@l{\raggedright}
802 \providecommand*\caption@hj@r{\raggedleft}
803 \providecommand*\caption@hj@s{}
804 \def\ContinuedFloat{%
805 \@ifnextchar[\@Continued@Float\@ContinuedFloat}
806 \def\@Continued@Float[#1]{\addtocounter{#1}\m@ne}
807 \def\@ContinuedFloat{%
808 \caption@iftype
809 {\addtocounter\@captype\m@ne
810 \caption@ContinuedFloat\@captype}%
811 {\caption@Error{\noexpand\ContinuedFloat outside float}}}
812 \def\caption@ContinuedFloat#1{%
813 \@ifstar{\caption@Continued@Float@{#1}}{\caption@Continued@Float{#1}}}
814 \def\caption@Continued@Float@{%
815 \addtocounter\@captype\@ne
816 \@stpelt{ContinuedFloat}\stepcounter{ContinuedFloat}%
817 \def\caption@resetContinuedFloat##1{\xdef\caption@CFtype{##1}}%
818 \caption@@ContinuedFloat}
819 \def\caption@Continued@Float#1{%
820 \edef\caption@tempa{#1}%
821 \ifx\caption@tempa\caption@CFtype
822 \stepcounter{ContinuedFloat}%
823 \let\caption@resetContinuedFloat\@gobble
824 \caption@@ContinuedFloat{#1}%
825 \sf@ContinuedFloat{#1}%
826 \else
827 \caption@Error{Continued `#1' after `\caption@CFtype'}%
828 \fi}
829 \def\caption@@ContinuedFloat#1{%
830 \expandafter\l@addto@macro\csname the#1\endcsname\theContinuedFloat
831 \@ifundefined{theH#1}{}{%
832 \expandafter\l@addto@macro\csname theH#1\endcsname{%
833 \@alph\c@ContinuedFloat}}%
834 \caption@setoptions{ContinuedFloat}%
835 \caption@setoptions{continued#1}}
836 \providecommand*\sf@ContinuedFloat[1]{}
837 \newcommand*\caption@CFtype{??}
838 \newcounter{ContinuedFloat}
839 \let\theContinuedFloat\@empty
840 \newcommand*\caption@resetContinuedFloat[1]{%
841 \@stpelt{ContinuedFloat}\xdef\caption@CFtype{#1}}
842 \newcommand\phantomcaption{%
843 \caption@iftype
844 {\caption@refstepcounter\@captype}%
845 {\caption@Error{\noexpand\phantomcaption outside float}}}%
846 \newcommand*\caption@refstepcounter[1]{%
847 \@ifundefined{c@#1}%
848 {\caption@Error{No float type '#1' defined}}%
849 {\caption@resetContinuedFloat{#1}%
850 \caption@@refstepcounter{#1}%
851 \let\caption@ifrefstepcounter\@firstoftwo}}
852 \newcommand*\caption@@refstepcounter{\refstepcounter}
853 \let\caption@ifrefstepcounter\@secondoftwo
854 \caption@ifundefined\kernel@ifnextchar
855 {\newcommand\caption@dblarg[1]{\@ifnextchar[{#1}{\caption@xdblarg{#1}}}}%
856 {\newcommand\caption@dblarg[1]{\kernel@ifnextchar[{#1}{\caption@xdblarg{#1}}}}%
857 \newcommand\caption@xdblarg[2]{#1[{#2\relax}]{#2}}%
858 \newcommand*\caption@begin[1]{%
859 \begingroup
860 \caption@setfnum{#1}%
861 \caption@fixposition
862 \global\let\caption@fixedposition\caption@position}
863 \newcommand\caption@beginex[3]{%
864 \caption@begin{#1}%
865 \let\lst@@caption\relax
866 \caption@addcontentsline{#1}{#2}%
867 \caption@ifempty{#3}{}}
868 \newcommand*\caption@end{%
869 \endgroup
870 \let\caption@position\caption@fixedposition}
871 \newcommand*\caption@setfnum[1]{%
872 \@ifundefined{fnum@#1}{\iftrue}{\ifx\caption@lfmt\caption@lfmt@default\else}%
873 \@namedef{fnum@#1}{\caption@fnum{#1}}%
874 \fi}
875 \newcommand*\caption@boxrestore{%
876 \caption@parboxrestore{\@parboxrestore}{%
877 \let\if@nobreak\iffalse
878 \let\if@noskipsec\iffalse
879 \let\par\@@par
880 \parindent\z@ \parskip\z@skip
881 \everypar{}%
882 \leftskip\z@skip \rightskip\z@skip \@rightskip\z@skip
883 \parfillskip\@flushglue \lineskip\normallineskip
884 \baselineskip\normalbaselineskip
885 \sloppy
886 \let\\\@normalcr
887 }}
888 \newcommand\caption@boxrestore@mini{%
889 \let\par\@@par
890 \parindent\z@ \parskip\z@skip
891 \sloppy}
892 \newcommand*\caption@normalsize{%
893 \caption@font*{\KV@caption@fnt@normal\@unused}}
894 \let\caption@setfloatcapt\@firstofone
895 \newcommand*\caption@makecurrent[2]{}
896 \let\caption@makeanchor\@firstofone
897 \let\caption@start\relax
898 \let\caption@@start\relax
899 \let\caption@freezeHref\relax
900 \let\caption@defrostHref\relax
901 \newcommand\caption@gettitle[1]{%
902 \caption@ifundefined\NR@gettitle
903 {\caption@ifundefined\NR@sect{}{\def\@currentlabelname{#1}}}% support for older versions of nameref package
904 {\NR@gettitle{#1}}} % support for recent versions of nameref package
905 \def\caption@DeclareSubType sub#1\@nil{%
906 \caption@Debug{Initializing subtype for `#1'\@gobble}%
907 \@namedef{caption@c@#1}{0}%
908 \@namedef{caption@beginsub#1}{\caption@beginsubfloat{#1}}}
909 \@onlypreamble\caption@DeclareSubType
910 \caption@For*{subtypelist}{\caption@DeclareSubType sub#1\@nil}
911 \caption@AtBeginDocument*{%
912 \caption@ifundefined\sf@counterlist{}{%
913 \@for\sf@temp:=\sf@counterlist\do{%
914 \expandafter\caption@DeclareSubType\sf@temp\@nil}}}
915 \newcommand*\caption@subtypehook{%
916 \ifx\caption\caption@subcaption \else
917 \caption@warmup
918 \caption@ifrefstepcounter{}{%
919 % no \caption or \subcaption in this (floating) environment yet
920 \caption@Debug{Increment \@captype\ counter =\the\value\@captype}%
921 \caption@l@stepcounter\@captype
922 \let\caption@@@addcontentsline\caption@addsubcontentsline}%
923 \ifnum\csname caption@c@\@captype\endcsname=\value\@captype \else
924 \caption@Debug{Reset sub\@captype\ counter}%
925 \expandafter\xdef\csname caption@c@\@captype\endcsname{%
926 \the\value\@captype}%
927 \@stpelt\@subcaptype
928 \fi
929 \c@ContinuedFloat=0\relax
930 \let\caption@resetContinuedFloat\@gobble
931 \let\caption@addcontentsline\caption@kernel@addcontentsline
932 \let\caption@setfloatcapt\@firstofone
933 \caption@clearmargin
934 \caption@iflist{}{\let\caption@setlist\@gobble}%
935 \caption@setoptions{sub}%
936 \caption@setoptions{subfloat}% for subfig-package compatibility
937 \let\caption\caption@subcaption
938 \let\phantomcaption\caption@subphantom
939 \if@subfloatrow
940 \caption@Debug{Keeping \string\@makecaption}%
941 \else
942 \let\@makecaption\caption@makecaption
943 \fi
944 \fi}%
945 \caption@AtBeginDocument{%
946 \caption@ifundefined\@subfloatrowtrue
947 {\newif\if@subfloatrow
948 \caption@ifundefined\subfloatrow{}%
949 {\caption@Debug{Patching subfloatrow environment}%
950 \g@addto@macro\capsubrowsettings{\@subfloatrowtrue}%
951 \g@addto@macro\killfloatstyle{%
952 \ifx\c@FRobj\c@FRsobj\@subfloatrowtrue\fi}}}%
953 {\caption@Debug{\string\if@subfloatrow is already defined}}}%
954 \newcommand*\caption@subcaption{%
955 \caption@checkgrouplevel{sub}\subcaption
956 \caption@star
957 {\caption@refstepcounter\@subcaptype}%
958 {\caption@dblarg{\@caption\@subcaptype}}}
959 \newcommand*\caption@subphantom{%
960 \caption@checkgrouplevel{sub}\phantomsubcaption
961 \caption@refstepcounter\@subcaptype}
962 \let\caption@kernel@addcontentsline\caption@addcontentsline
963 \renewcommand\caption@addcontentsline[2]{%
964 \sf@ifpositiontop{\@listsubcaptions{#1}}{}%
965 \caption@kernel@addcontentsline{#1}{#2}%
966 \sf@ifpositiontop{}{\@listsubcaptions{#1}}%
967 \caption@addsubcontentslines{#1}}
968 \newcommand*\caption@addsubcontentslines[1]{%
969 \begingroup
970 \caption@subcontentslines
971 \endgroup
972 \caption@clearsubcontentslines}%
973 \newcommand*\caption@addsubcontentsline[4]{%
974 \begingroup
975 \let\label\caption@gobble \let\index\caption@gobble \let\glossary\caption@gobble
976 \protected@edef\@tempa{\endgroup
977 \noexpand\g@addto@macro\noexpand\caption@subcontentslines{%
978 \noexpand\@namedef{the#2}{\csname the#2\endcsname}%
979 \ifx\@currentHref\@undefined \else
980 \noexpand\def\noexpand\@currentHref{\@currentHref}%
981 \fi
982 \protect\caption@@@addcontentsline{#1}{#2}{#3}{#4}}}%
983 \@tempa}
984 \newcommand*\caption@checksubcontentslines{%
985 \ifx\caption@subcontentslines\@empty \else
986 \caption@Error{%
987 Something's wrong--perhaps a missing \protect\caption\MessageBreak
988 in the last figure or table}%
989 \caption@clearsubcontentslines
990 \fi}
991 \newcommand*\caption@clearsubcontentslines{%
992 \global\let\caption@subcontentslines\@empty}
993 \caption@AtBeginDocument*{%
994 \caption@ifundefined\sf@ifpositiontop{\let\sf@ifpositiontop\@gobbletwo}{}%
995 \caption@clearsubcontentslines
996 \g@addto@macro\caption@typehook{\caption@checksubcontentslines}%
997 \AtEndDocument{\caption@checksubcontentslines}}%
998 \caption@ifundefined\smf@makecaption{}{\let\smf@makecaption\@makecaption}
999 \@ifclassloaded{beamer}{%
1000 \caption@InfoNoLine{beamer document class}%
1001 \expandafter\let\expandafter\caption@ORI@figure
1002 \csname\string\figure\endcsname
1003 \@namedef{\string\figure}[#1]{%
1004 \caption@ORI@figure[#1]%
1005 \caption@settype{figure}}
1006 \expandafter\let\expandafter\caption@ORI@table
1007 \csname\string\table\endcsname
1008 \@namedef{\string\table}[#1]{%
1009 \caption@ORI@table[#1]%
1010 \caption@settype{table}}
1011 }{}
1012 \caption@ifundefined\scr@caption{}{%
1013 \caption@AtBeginDocument{\let\scr@caption\caption}}
1014 \@nameuse{caption@frenchb}\@nameundef{caption@frenchb}
1015 \caption@AtBeginDocument{\caption@ifundefined\frenchTeXmods{}{%
1016 \caption@InfoNoLine{frenchle/pro package is loaded}%
1017 \let\captionfont@ORI\captionfont
1018 \let\captionlabelfont@ORI\captionlabelfont
1019 \let\@makecaption@ORI\@makecaption
1020
1021 \caption@ifundefined\GOfrench
1022 {\let\caption@tempa\@firstofone}%
1023 {\def\caption@tempa{\g@addto@macro\GOfrench}}%
1024 \caption@tempa{%
1025 \let\captionfont\captionfont@ORI
1026 \let\captionfont@ORI\@undefined
1027 \let\captionlabelfont\captionlabelfont@ORI
1028 \let\captionlabelfont@ORI\@undefined
1029 \let\@makecaption\@makecaption@ORI
1030 \let\@makecaption@ORI\@undefined
1031 \let\@cnORI\caption
1032 \let\caption@tcORI\@tablescaption
1033 \def\@tablescaption{\caption@star\relax\caption@tcORI}%
1034 \let\@eatDP\@undefined
1035 \let\caption@tempa\@empty
1036 \ifx\f@ffrench\fnum@figure
1037 \l@addto@macro\caption@tempa{\let\fnum@figure\f@ffrench}%
1038 \fi
1039 \ifx\f@tfrench\fnum@table
1040 \l@addto@macro\caption@tempa{\let\fnum@table\f@tfrench}%
1041 \fi
1042 \def\f@ffrench{\ifx\listoffigures\relax\else\figurename~\thefigure\fi}%
1043 \def\f@tfrench{\ifx\listoftables\relax\else\tablename~\thetable\fi}%
1044 \caption@tempa
1045 }%
1046 }}
1047 \def\caption@tempa#1{%
1048 \@ifundefined{extras#1}\caption@AtBeginDocument\@firstofone{%
1049 \@ifundefined{extras#1}{}{%
1050 \caption@InfoNoLine{#1 babel option is loaded}%
1051 \expandafter\addto\csname extras#1\endcsname{%
1052 % reverse changes made by magyar.ldf
1053 \let\@makecaption\caption@makecaption
1054 \babel@save\@makecaption
1055 \caption@redefine
1056 \babel@save\@caption}%
1057 }}}
1058 \caption@tempa{hungarian}%
1059 \caption@tempa{magyar}%
1060 \newcommand\caption@IfPackageLoaded[1]{%
1061 \@testopt{\caption@@IfPackageLoaded{#1}}{}}
1062 \@onlypreamble\caption@IfPackageLoaded
1063 \long\def\caption@@IfPackageLoaded#1[#2]#3#4{%
1064 \@ifpackageloaded{#1}\@firstofone{%
1065 \caption@Debug{#1 package is not loaded (yet)\@gobble}%
1066 \caption@AtBeginDocument}{%
1067 \caption@@ifpackageloaded{#1}[#2]{#3}{#4}}}
1068 \@onlypreamble\caption@@IfPackageLoaded
1069 \newcommand\caption@ifpackageloaded[1]{%
1070 \@testopt{\caption@@ifpackageloaded{#1}}{}}
1071 \@onlypreamble\caption@ifpackageloaded
1072 \long\def\caption@@ifpackageloaded#1[#2]{%
1073 \@ifpackageloaded{#1}{%
1074 \caption@InfoNoLine{#1 package is loaded}%
1075 \@ifpackagelater{#1}{#2}\@firstoftwo{%
1076 \caption@Error{%
1077 For a successful cooperation we need at least version\MessageBreak
1078 `#2' of package #1,\MessageBreak
1079 but only version\MessageBreak
1080 `\csname ver@#1.\@pkgextension\endcsname'\MessageBreak
1081 is available}%
1082 \@secondoftwo}%
1083 }{\@secondoftwo}}
1084 \@onlypreamble\caption@@ifpackageloaded
1085 \newcommand*\caption@clearmargin{%
1086 \setcaptionmargin\z@
1087 \let\caption@minmargin\@undefined}
1088 \caption@setbool{needfreeze}{0}
1089 \caption@AtBeginDocument*{%
1090 \caption@ifneedfreeze{%
1091 \newcommand*\caption@freeze{%
1092 \let\caption@frozen@ContinuedFloat\ContinuedFloat
1093 \def\ContinuedFloat{%
1094 \caption@withoptargs\caption@SC@ContinuedFloat}%
1095 \def\caption@SC@ContinuedFloat##1{%
1096 \caption@@freeze{\ContinuedFloat##1}%
1097 \let\caption@frozen@setcounter\setcounter
1098 \let\caption@frozen@addtocounter\addtocounter
1099 \def\setcounter####1####2{\csname c@####1\endcsname####2\relax}%
1100 \def\addtocounter####1####2{\advance\csname c@####1\endcsname ####2\relax}%
1101 \caption@frozen@ContinuedFloat##1%
1102 \let\setcounter\caption@frozen@setcounter
1103 \let\addtocounter\caption@frozen@addtocounter}%
1104 \let\caption@frozen@setup\caption@setup
1105 \def\caption@setup##1{%
1106 \caption@@freeze{\caption@setup{##1}}%
1107 \caption@frozen@setup{##1}}%
1108 \let\caption@frozen@caption\caption
1109 \def\caption{%
1110 \def\caption{%
1111 \caption@Error{%
1112 Only one \noexpand\caption can be placed in this environment}%
1113 \caption@gobble}%
1114 \@ifstar
1115 {\caption@SC@caption*}%
1116 {\let\caption@frozen@refstepcounter\caption@@refstepcounter
1117 \let\caption@@refstepcounter\caption@l@stepcounter
1118 \caption@refstepcounter\@captype
1119 \let\caption@@refstepcounter\caption@frozen@refstepcounter
1120 \let\@currentlabel\caption@SClabel
1121 \caption@withoptargs\caption@SC@caption}}%
1122 \long\def\caption@SC@caption##1##2{%
1123 \caption@@freeze{\caption##1{##2}}%
1124 \ignorespaces}%
1125 \let\caption@frozen@label\label
1126 \def\label{%
1127 \caption@withoptargs\caption@SC@label}%
1128 \def\caption@SC@label##1##2{%
1129 \ifx\@currentlabel\caption@SClabel
1130 \@bsphack
1131 \caption@freeze@label{##1}{##2}%
1132 \@esphack
1133 \else
1134 \caption@frozen@label##1{##2}%
1135 \fi}%
1136 \def\caption@SClabel{\caption@undefinedlabel}%
1137 \def\caption@freeze@label##1##2{%
1138 \caption@@freeze{\label##1{##2}}}%
1139 \global\let\caption@frozen@content\@empty
1140 \long\def\caption@@freeze{%
1141 \g@addto@macro\caption@frozen@content}%
1142 \def\caption@warmup{%
1143 \let\ContinuedFloat\caption@frozen@ContinuedFloat
1144 \let\caption@setup\caption@frozen@setup
1145 \let\caption\caption@frozen@caption
1146 \let\label\caption@frozen@label}}%
1147 \newcommand*\caption@defrost{%
1148 \ifx\caption@frozen@caption\@undefined
1149 \caption@frozen@content
1150 \else
1151 \caption@Error{Internal Error:\MessageBreak
1152 \noexpand\caption@defrost in same group as \string\caption@freeze}%
1153 \fi}%
1154 }{}%
1155 \caption@undefbool{needfreeze}}
1156 \let\caption@warmup\relax
1157 \caption@IfPackageLoaded{float}[2001/11/08 v1.3d]{%
1158 \@ifpackageloaded{floatrow}{%
1159 \caption@ifpackageloaded{floatrow}[2007/08/24 v0.2a]{}{}%
1160 }{%
1161 \let\caption@ORI@float@setevery\@float@setevery
1162 \def\@float@setevery#1{%
1163 \float@ifcaption{#1}{%
1164 \caption@setposition{\@fs@iftopcapt t\else b\fi}%
1165 \renewcommand\caption@setfloatcapt[1]{%
1166 \let\@makecaption\caption@@make
1167 \global\setbox\@floatcapt\vbox{%
1168 \color@begingroup ##1\color@endgroup}}%
1169 \float@getstyle\float@style{#1}%
1170 \caption@setstyle*\float@style
1171 \caption@setoptions\float@style
1172 }{}%
1173 \caption@freezeHref % will be defrosted in \float@makebox
1174 \caption@ORI@float@setevery{#1}}%
1175 \g@addto@macro\caption@typehook{%
1176 \expandafter\ifx\csname #1name\endcsname\relax
1177 \expandafter\let\csname #1name\expandafter\endcsname
1178 \csname fname@#1\endcsname
1179 \fi}%
1180 \g@addto@macro\fs@plaintop{\def\@fs@mid{\vspace\abovecaptionskip\relax}}%
1181 \g@addto@macro\fs@boxed{\def\@fs@mid{\kern\abovecaptionskip\relax}}%
1182 \providecommand*\float@getstyle[2]{%
1183 \edef#1{%
1184 \noexpand\expandafter\noexpand\@gobblefour\noexpand\string
1185 \expandafter\expandafter\expandafter\noexpand
1186 \csname fst@#2\endcsname}%
1187 \edef#1{#1}%
1188 \caption@Debug{floatstyle{#2} = `#1'}}%
1189 \providecommand*\float@ifcaption[1]{%
1190 \expandafter\ifx\csname @float@c@#1\endcsname\float@caption
1191 \expandafter\@firstoftwo
1192 \else
1193 \expandafter\@secondoftwo
1194 \fi}%
1195 }}{%
1196 \providecommand*\float@ifcaption[1]{\@secondoftwo}%
1197 }
1198 \captionsetup[boxed]{skip=2pt} % do not issue a warning when not used
1199 \caption@ifbool{ruled}{%
1200 \captionsetup[ruled]{margin=0pt,minmargin=0,slc=0}%
1201 }{%
1202 \DeclareCaptionStyle{ruled}{labelfont=bf,labelsep=space,strut=0}%
1203 }
1204 \caption@undefbool{ruled}
1205 \caption@IfPackageLoaded{floatflt}[1996/02/27 v1.3]{%
1206 \let\caption@ORI@floatingfigure\floatingfigure
1207 \def\floatingfigure{%
1208 \caption@floatflt{figure}%
1209 \caption@ORI@floatingfigure}%
1210 \let\caption@ORI@floatingtable\floatingtable
1211 \def\floatingtable{%
1212 \caption@floatflt{table}%
1213 \caption@ORI@floatingtable}%
1214 \newcommand*\caption@floatflt[1]{%
1215 \caption@settype{#1}%
1216 \caption@clearmargin
1217 \caption@setfullparboxrestore
1218 \caption@setoptions{floating#1}}%
1219 }{}
1220 \caption@IfPackageLoaded{fltpage}[1998/10/29 v.0.3]{%
1221 \caption@setbool{needfreeze}{1}%
1222 \renewcommand\FP@positionLabel{%
1223 FP\FP@captype-\number\value{FP@\FP@captype C}-pos}%
1224 \renewcommand\FP@helpNote[2]{%
1225 \begingroup % save \caption@thepage
1226 \caption@pageref{#2}%
1227 \typeout{FP#1 is inserted on page \caption@thepage!}%
1228 \endgroup}%
1229 \renewcommand*\FP@floatBegin[1]{%
1230 \def\FP@captype{#1}%
1231 \begin{lrbox}{\FP@floatCorpusBOX}%
1232 \caption@settype*{#1}%
1233 \caption@freeze
1234 \global\let\FP@Label\@empty
1235 \caption@ifFPrefcap
1236 {}%
1237 {\def\caption@freeze@label##1##2{%
1238 \g@addto@macro\FP@Label{\FP@label##1{##2}}}}%
1239 \ignorespaces}%
1240 \renewcommand*\FP@floatEnd{%
1241 \end{lrbox}%
1242 \stepcounter{FP@\FP@captype C}%
1243 \caption@label\FP@positionLabel
1244 \FP@helpNote\FP@captype\FP@positionLabel
1245 \edef\FP@RestoreCounter{%
1246 \noexpand\setcounter{\FP@captype}{\the\value\FP@captype}%
1247 \noexpand\setcounter{ContinuedFloat}{\the\value{ContinuedFloat}}}%
1248 \FP@float
1249 {\FP@positionLabel}% location label test
1250 {\begin\FP@captype[p!]%
1251 \usebox\FP@floatCorpusBOX
1252 \let\caption@SClentry\@empty
1253 \def\caption{\caption@dblarg{\@caption\@captype}}%
1254 \long\def\@caption##1[##2]##3{\def\caption@SClentry{##2}}%
1255 \let\FP@label\label
1256 \let\label\caption@gobble
1257 \caption@defrost
1258 \caption@ifFPlistcap
1259 {\caption@refstepcounter\@captype
1260 \expandafter\caption@makecurrent\expandafter\@captype
1261 \expandafter{\caption@SClentry}}%
1262 {\ifx\caption@SClentry\@empty \else
1263 \expandafter\captionlistentry\expandafter{\caption@SClentry}%
1264 \fi}%
1265 \caption@makeanchor\relax
1266 \FP@Label
1267 \end\FP@captype}%
1268 {\FP@RestoreCounter
1269 \@ifundefined{theH\FP@captype}{}{%
1270 \expandafter\l@addto@macro\csname theH\FP@captype\endcsname{.FP}}}%
1271 {\begin\FP@captype[b!]%
1272 \let\FP@savedSetfnumCommand\caption@setfnum
1273 \def\caption@setfnum##1{%
1274 \FP@savedSetfnumCommand{##1}%
1275 \ifx\FP@guide\@empty \else
1276 \expandafter\l@addto@macro\csname fnum@##1\endcsname{\ {\FP@guide}}%
1277 \fi}%
1278 \setlength\abovecaptionskip{2pt plus 2pt minus 1pt}% length above caption
1279 \setlength\belowcaptionskip{2pt plus 2pt minus 1pt}% length below caption
1280 \caption@setoptions{FP\@captype}%
1281 \FP@separatorCaption
1282 \caption@ifFPlistcap{}{\let\caption@addcontentsline\@gobbletwo}%
1283 \caption@defrost
1284 \end\FP@captype}%
1285 }%
1286 }{%
1287 \let\caption@ifFPlistcap\@undefined
1288 \let\caption@ifFPrefcap\@undefined
1289 }
1290 \caption@IfPackageLoaded{hyperref}[2003/11/30 v6.74m]{%
1291 % Test if hyperref has stopped early
1292 \caption@ifundefined\IfHyperBoolean{%
1293 \caption@set@bool\caption@ifhyp@stoppedearly0%
1294 \caption@ifundefined\H@refstepcounter
1295 {\caption@set@bool\caption@ifhyp@stoppedearly1}{%
1296 \caption@ifundefined\hyper@makecurrent
1297 {\caption@set@bool\caption@ifhyp@stoppedearly1}{%
1298 \caption@ifundefined\measuring@true
1299 {\caption@set@bool\caption@ifhyp@stoppedearly1}{}}}%
1300 }{%
1301 \def\caption@ifhyp@stoppedearly{\IfHyperBoolean{stoppedearly}}%
1302 }%
1303 \caption@ifhyp@stoppedearly{% hyperref has stopped early
1304 \caption@InfoNoLine{%
1305 Hyperref support is turned off\MessageBreak
1306 because hyperref has stopped early}%
1307 }{%
1308 \g@addto@macro\caption@prepareslc{\measuring@true}%
1309 \renewcommand*\caption@@refstepcounter{\H@refstepcounter}%
1310 \renewcommand*\caption@makecurrent[2]{%
1311 \caption@makecurrentHref{#1}%
1312 \caption@Debug{hyperref current=\@currentHref}%
1313 \caption@gettitle{#2}}%
1314 \newcommand*\caption@makecurrentHref{\hyper@makecurrent}%
1315 \renewcommand\caption@makeanchor[1]{%
1316 \caption@Debug{hyperref anchor: \@currentHref}%
1317 % If we cannot have nesting, the anchor is empty.
1318 \ifHy@nesting
1319 \expandafter\hyper@@anchor\expandafter{\@currentHref}{#1}%
1320 \else
1321 \Hy@raisedlink{%
1322 \expandafter\hyper@@anchor\expandafter{\@currentHref}{\relax}%
1323 }#1%
1324 \fi}%
1325 \g@addto@macro\caption@prepareslc{\let\caption@makeanchor\@firstofone}%
1326 \newif\if@capstart
1327 \def\caption@start{\caption@ifhypcap\caption@start@\relax}%
1328 \def\caption@start@{%
1329 \caption@makestart\@captype
1330 \caption@startanchor\@currentHref
1331 \global\@capstarttrue
1332 \let\hc@currentHref\@currentHref
1333 \def\caption@makecurrentHref##1{%
1334 \global\@capstartfalse
1335 \global\let\@currentHref\hc@currentHref}%
1336 \let\caption@makeanchor\@firstofone
1337 }%
1338 \newcommand*\caption@makestart[1]{%
1339 \begingroup
1340 \Hy@hypertexnamesfalse
1341 \hyper@makecurrent{#1.caption}%
1342 \endgroup
1343 \caption@Debug{hypcap start=\@currentHref}}%
1344 \newcommand*\caption@startanchor[1]{%
1345 \ifvmode\begingroup
1346 \caption@Debug{hypcap anchor: #1 (vertical mode)}%
1347 \@tempdima\prevdepth
1348 \nointerlineskip
1349 \vspace*{-\caption@hypcapspace}%
1350 \caption@anchor{#1}%
1351 \vspace*{\caption@hypcapspace}%
1352 \prevdepth\@tempdima
1353 \endgroup\else
1354 \caption@Debug{hypcap anchor: #1 (horizontal mode)}%
1355 \caption@anchor{#1}%
1356 \fi}%
1357 \newcommand*\caption@anchor[1]{%
1358 \ifmeasuring@ \else
1359 \caption@raisedlink{\hyper@anchorstart{#1}\hyper@anchorend}%
1360 \fi}%
1361 \ifx\HyperRaiseLinkLength\@tempdima
1362 \def\caption@raisedlink#1{\ifvmode#1\else\Hy@raisedlink{#1}\fi}%
1363 \else
1364 \let\caption@raisedlink\Hy@raisedlink
1365 \fi
1366 \def\caption@@start{%
1367 \caption@ifundefined\hc@currentHref{%
1368 \caption@Warning{%
1369 The option `hypcap=true' will be ignored for this\MessageBreak
1370 particular \string\caption}}{}}%
1371 \def\caption@freezeHref{%
1372 \let\caption@ORI@start\caption@start
1373 \def\caption@start{\let\caption@start\caption@ORI@start}%
1374 \global\let\caption@currentHref\@undefined
1375 \def\caption@@start{\global\let\caption@currentHref\@currentHref}%
1376 \let\caption@ORI@setfloatcapt\caption@setfloatcapt
1377 \renewcommand*\caption@setfloatcapt{%
1378 \ifx\caption@currentHref\@undefined \else
1379 \let\caption@makeanchor\@firstofone
1380 \fi
1381 \caption@ORI@setfloatcapt}}%
1382 \def\caption@defrostHref{%
1383 \ifx\caption@currentHref\@undefined \else
1384 \caption@startanchor\caption@currentHref
1385 \global\let\caption@currentHref\@undefined
1386 \fi}%
1387 \caption@ifundefined\HyOrg@float@makebox{}{%
1388 \caption@Debug{%
1389 Redefining \noexpand\float@makebox (again)\@gobble}%
1390 \let\caption@ORI@float@makebox\float@makebox % save for compatibility mode
1391 \renewcommand\float@makebox[1]{%
1392 \HyOrg@float@makebox{#1\relax \caption@defrostHref}}%
1393 }%
1394 }}{}
1395 \caption@IfPackageLoaded{hypcap}{% v1.0
1396 \ifx\caption@start\relax \else % hyperref hasn't stopped early
1397 \let\caption@ORI@capstart\capstart % save for compatibility mode
1398 \caption@ifundefined\capstarttrue % check for v1.10 of hypcap package
1399 {\def\capstart{\caption@start@}}%
1400 {\def\capstart{\ifcapstart\caption@start@\fi}}%
1401 \let\caption@start\relax
1402 \let\caption@@start\relax
1403 \caption@set@bool\caption@ifhypcap 1%
1404 \renewcommand*\caption@hypcapspace{\hypcapspace}%
1405 \fi}{}
1406 \caption@IfPackageLoaded{listings}[2004/02/13 v1.2]{%
1407 \let\caption@ORI@lst@MakeCaption\lst@MakeCaption
1408 \def\lst@MakeCaption#1{% #1 is `t' or `b'
1409 \begingroup
1410 \ifdim\hsize>\linewidth
1411 \hsize\linewidth
1412 \fi
1413 \caption@setposition{#1}%
1414 \caption@iftop{%
1415 \@tempdima\belowcaptionskip
1416 \belowcaptionskip\abovecaptionskip
1417 \abovecaptionskip\@tempdima}{}%
1418 \caption@setup{rule=0}%
1419 \caption@setoptions{lstlisting}%
1420 \caption@setautoposition{#1}%
1421 \caption@begin{lstlisting}%
1422 \caption@ORI@lst@MakeCaption{#1}%
1423 \caption@end
1424 \endgroup}%
1425 \def\lst@makecaption{\caption@starfalse\@makecaption}%
1426 \def\lst@maketitle{\caption@startrue\@makecaption\@empty}%
1427 \providecommand*\ext@lstlisting{lol}%
1428 }{}
1429 \providecommand*\LTcaptype{table}
1430 \caption@IfPackageLoaded{longtable}[1995/05/24 v3.14]{%
1431 \RequirePackage{ltcaption}[=2007/09/01]%
1432 \let\LT@@makecaption\@undefined
1433 \caption@AtBeginDocument{%
1434 \let\caption@ORI@LT@array\LT@array
1435 \renewcommand*\LT@array{%
1436 \global\let\caption@opt@@longtable\@undefined
1437 \def\captionsetup{%
1438 \noalign\bgroup
1439 \@ifstar\@captionsetup\@captionsetup}% gobble *
1440 \def\@captionsetup##1{\LT@captionsetup{##1}\egroup}%
1441 \def\LT@captionsetup##1{%
1442 \captionsetup@startrue\caption@setup@options[@longtable]{##1}%
1443 \global\let\caption@opt@@longtable\caption@opt@@longtable}%
1444 \def\@captionabovetrue{\LT@captionsetup{position=t}}%
1445 \def\@captionabovefalse{\LT@captionsetup{position=b}}%
1446 \def\captionlistentry{%
1447 \noalign\bgroup
1448 \@ifstar{\egroup\LT@captionlistentry}% gobble *
1449 {\egroup\LT@captionlistentry}}%
1450 \def\LT@captionlistentry##1{%
1451 \caption@listentry\@firstoftwo[\LTcaptype]{##1}}%
1452 %% \let\Hy@LT@currentHlabel\@currentHlabel
1453 %% \let\@currentHlabel\Hy@LT@currentHlabel
1454 \def\ContinuedFloat{\noalign{%
1455 \caption@Error{\noexpand\ContinuedFloat outside float}}}%
1456 \caption@ORI@LT@array}}%
1457 \long\def\LT@c@ption#1[#2]#3{%
1458 \LT@makecaption#1{\csname fnum@\LTcaptype\endcsname}{#3}%
1459 \LT@captionlistentry{#2}}%
1460 \renewcommand\LT@makecaption[3]{%
1461 \caption@LT@make{%
1462 \caption@settype*\LTcaptype
1463 \ifdim\LTcapwidth=4in \else
1464 \setcaptionwidth\LTcapwidth
1465 \fi
1466 \caption@setoptions{longtable}%
1467 \caption@setoptions{@longtable}%
1468 \caption@setautoposition{\ifcase\LT@rows t\else b\fi}%
1469 \caption@startrue#1\caption@starfalse
1470 \caption@resetContinuedFloat\LTcaptype
1471 \caption@begin\LTcaptype
1472 \caption@normalsize
1473 \vskip-\ht\strutbox
1474 \caption@iftop{\vskip\belowcaptionskip}{\vskip\abovecaptionskip}%
1475 \caption@@make{#2}{#3}\endgraf
1476 \caption@iftop{\vskip\abovecaptionskip}{\vskip\belowcaptionskip}%
1477 \caption@end}}%
1478 }{}
1479 \caption@IfPackageLoaded{picinpar}{%
1480 \long\def\figwindow[#1,#2,#3,#4] {%
1481 \caption@window{figure}%
1482 \caption@setoptions{figwindow}%
1483 \begin{window}[#1,#2,{#3},\caption@wincaption{#4}] }%
1484 \long\def\tabwindow[#1,#2,#3,#4] {%
1485 \caption@window{table}%
1486 \caption@setoptions{tabwindow}%
1487 \begin{window}[#1,#2,{#3},\caption@wincaption{#4}] }%
1488 \newcommand*\caption@window[1]{%
1489 \let\@makecaption\caption@@make
1490 \caption@setautoposition b%
1491 \caption@settype{#1}%
1492 \caption@clearmargin
1493 \caption@setfullparboxrestore}%
1494 \newcommand\caption@wincaption[1]{%
1495 \ifdim\picwd=\z@
1496 \let\caption@makecurrent\@gobbletwo
1497 \let\caption@@start\relax
1498 \caption@prepareslc
1499 \fi
1500 \edef\@tempa{\expandafter\noexpand\@car#1\@nil}%
1501 \if\@tempa*%
1502 \let\@tempa\@firstofone
1503 \else\if\@tempa[%]
1504 \let\@tempa\@firstofone
1505 \else
1506 \let\@tempa\@empty
1507 \fi\fi
1508 \expandafter\caption\@tempa{#1}}%
1509 }{}
1510 \newcommand*\piccaptiontype[1]{\def\@piccaptype{#1}}
1511 \caption@IfPackageLoaded{picins}{%
1512 \caption@ifundefined\@piccaptype{%
1513 \caption@iftype{%
1514 \let\@piccaptype\@captype
1515 }{%
1516 \def\@piccaptype{figure}%
1517 }%
1518 }{}%
1519 \let\@captype\@undefined
1520 \def\piccaption{\caption@star\relax{\caption@dblarg\@piccaption}}%
1521 \let\caption@ORI@make@piccaption\make@piccaption
1522 \def\make@piccaption{%
1523 \let\caption@ORI\caption
1524 \long\def\caption[##1]##2{%
1525 \caption@freezeHref % will be defrosted in \ivparpic
1526 \caption@settype\@piccaptype
1527 \caption@clearmargin
1528 \caption@setfullparboxrestore
1529 \caption@setoptions{parpic}%
1530 \caption@setautoposition b%
1531 \expandafter\expandafter\expandafter\caption@ORI
1532 \expandafter\expandafter\expandafter[%
1533 \expandafter\expandafter\expandafter{%
1534 \expandafter##1\expandafter}\expandafter]\expandafter{##2}}%
1535 \caption@ORI@make@piccaption
1536 \let\caption\caption@ORI}%
1537
1538 \let\caption@ORI@ivparpic\ivparpic
1539 \def\ivparpic(#1,#2)(#3,#4)[#5][#6]#7{%
1540 \let\caption@ORI@noindent\noindent
1541 \def\noindent{%
1542 \caption@defrostHref
1543 \let\noindent\caption@ORI@noindent
1544 \noindent}%
1545 \caption@ORI@ivparpic(#1,#2)(#3,#4)[#5][#6]{#7}%
1546 \let\noindent\caption@ORI@noindent}%
1547 }{%
1548 \let\piccaptiontype\@undefined
1549 }
1550 \caption@IfPackageLoaded{rotating}[1995/08/22 v2.10]{%
1551 \def\rotcaption{\let\@makecaption\@makerotcaption\caption}%
1552 \def\rotcaptionof{%
1553 \caption@teststar\caption@of{\rotcaption*}\rotcaption}%
1554 \long\def\@makerotcaption#1#2{%
1555 \ifdim\captionwidth=\z@
1556 \setcaptionwidth{.8\textheight}%
1557 \caption@slc{#1}{#2}{.8\vsize}{%
1558 \let\caption@makerot\caption@@make
1559 \caption@clearmargin
1560 \let\caption@parbox\@secondoftwo}%
1561 \caption@set@bool\caption@ifslc0% been there, done that
1562 \fi
1563 \rotatebox{90}{\caption@makerot{#1}{#2}}%
1564 \nobreak\hspace{12pt}}%
1565 \newcommand\caption@makerot[2]{%
1566 \begin{minipage}\captionwidth\caption@@make{#1}{#2}\end{minipage}}%
1567 }{}
1568 \caption@IfPackageLoaded{sidecap}[2003/06/06 v1.6f]{%
1569 \caption@setbool{needfreeze}{1}%
1570 \let\caption@ORI@SC@zfloat\SC@zfloat
1571 \def\SC@zfloat#1#2#3[#4]{%
1572 \caption@ORI@SC@zfloat{#1}{#2}{#3}[#4]%
1573 \SC@RestoreCommands
1574 \caption@settype*{#2}%
1575 \caption@freeze
1576 \let\SC@label\label
1577 \ignorespaces}%
1578 \providecommand*\SC@RestoreCommands{%
1579 \let\caption=\SC@orig@caption \let\label=\SC@orig@label}%
1580 \let\caption@ORI@endSC@FLOAT\endSC@FLOAT
1581 \def\endSC@FLOAT{%
1582 \let\caption@ORI@settype\caption@settype
1583 \def\caption@settype##1{% will be done in \@xfloat
1584 \caption@ORI@settype*{##1}% do not change \@currentlabel
1585 \caption@setSC@justify
1586 %%% \caption@setoptions{SCfloat}%
1587 \caption@setoptions{SC\@captype}%
1588 \caption@start}%
1589 \def\caption@setSC@justify{%
1590 \caption@clearmargin
1591 \ifx\SC@justify\@empty \else
1592 \let\caption@hj\SC@justify
1593 \let\SC@justify\@empty
1594 \fi}%
1595 \let\caption\SC@orig@caption
1596 \def\SC@orig@caption[##1]##2{\caption@defrost}%
1597 \caption@setSC@justify % for compatibility mode
1598 \caption@ORI@endSC@FLOAT}%
1599 }{}
1600 \caption@IfPackageLoaded{subfigure}[2002/01/23 v2.1]{%
1601 \def\sf@ifpositiontop{%
1602 \ifx\@captype\@undefined
1603 \expandafter\@gobbletwo
1604 \else\ifx\@captype\relax
1605 \expandafter\expandafter\expandafter\@gobbletwo
1606 \else
1607 \expandafter\expandafter\expandafter\sf@if@position@top
1608 \fi\fi}
1609 \def\sf@if@position@top{%
1610 \@ifundefined{if\@captype topcap}%
1611 {\@gobbletwo}%
1612 {\@nameuse{if\@captype topcap}%
1613 \expandafter\@firstoftwo
1614 \else
1615 \expandafter\@secondoftwo
1616 \fi}}
1617 }{}
1618 \caption@IfPackageLoaded{supertabular}[2002/07/19 v4.1e]{%
1619 \renewcommand*\tablecaption{%
1620 \caption@star
1621 {\refstepcounter{table}}%
1622 {\caption@dblarg{\@xtablecaption}}}%
1623 \let\caption@ORI@xtablecaption\@xtablecaption
1624 \long\def\@xtablecaption[#1]#2{%
1625 \caption@gettitle{#2}%
1626 \caption@ORI@xtablecaption[#1]{#2}}%
1627 \long\def\ST@caption#1[#2]#3{\par%
1628 \caption@settype*{#1}%
1629 \caption@setoptions{supertabular}%
1630 \def\caption@fixposition{%
1631 \caption@setposition{\if@topcaption t\else b\fi}}%
1632 \caption@beginex{#1}{#2}{#3}%
1633 \caption@boxrestore
1634 \caption@normalsize
1635 \@makecaption{\csname fnum@#1\endcsname}{\ignorespaces #3}\par
1636 \caption@end}%
1637 }{}
1638 \caption@IfPackageLoaded{xtab}[2000/04/09 v2.3]{%
1639 \renewcommand*\tablecaption{%
1640 \caption@star
1641 {\refstepcounter{table}}%
1642 {\caption@dblarg{\@xtablecaption}}}%
1643 \let\caption@ORI@xtablecaption\@xtablecaption
1644 \long\def\@xtablecaption[#1]#2{%
1645 \caption@gettitle{#2}%
1646 \caption@ORI@xtablecaption[#1]{#2}}%
1647 \long\def\ST@caption#1[#2]#3{\par%
1648 \caption@settype*{#1}%
1649 \caption@setoptions{xtabular}%
1650 \def\caption@fixposition{%
1651 \caption@setposition{\if@topcaption t\else b\fi}}%
1652 \@initisotab
1653 \caption@beginex{#1}{#2}{#3}%
1654 \caption@boxrestore
1655 \caption@normalsize
1656 \@makecaption{\csname fnum@#1\endcsname}{\ignorespaces #3}\par
1657 \caption@end
1658 \global\advance\ST@pageleft -\PWSTcapht
1659 \ST@trace\tw@{Added caption. Space left for xtabular: \the\ST@pageleft}}%
1660 }{}
1661 \caption@IfPackageLoaded{threeparttable}[2003/06/13 v3.0]{%
1662 \let\caption@ORI@threeparttable\threeparttable
1663 \renewcommand*\threeparttable{%
1664 \caption@settype{table}%
1665 \caption@setposition a% ?
1666 \caption@clearmargin
1667 \caption@setoptions{threeparttable}%
1668 \caption@ORI@threeparttable}%
1669 \let\caption@ORI@measuredfigure\measuredfigure
1670 \renewcommand*\measuredfigure{%
1671 \caption@settype{figure}%
1672 \caption@setposition a% ?
1673 \caption@clearmargin
1674 \caption@setoptions{measuredfigure}%
1675 \caption@ORI@measuredfigure}%
1676 \def\TPT@caption#1[#2]#3{%
1677 \gdef\TPT@docapt{%
1678 \global\let\TPT@docapt\@undefined
1679 \caption@setautoposition\caption@TPT@position
1680 \TPT@LA@caption{#1}[{#2}]{#3}}%
1681 \ifx\TPT@hsize\@empty
1682 \let\label\TPT@gatherlabel % Bug: does not work for measuredfigures
1683 \gdef\caption@TPT@position{t}%
1684 \g@addto@macro\TPT@docapt\caption@TPT@eatvskip
1685 \else
1686 \def\caption@TPT@position{b}%
1687 \TPT@docapt
1688 \fi
1689 \ignorespaces}%
1690 %\newcommand*\caption@TPT@eatvskip{\vskip-.2\baselineskip}%
1691 \def\caption@TPT@eatvskip#1\vskip{#1\@tempdima=}%
1692 }{}
1693 \caption@IfPackageLoaded{wrapfig}[2003/01/31 v3.6]{%
1694 \renewcommand*\wrapfloat[1]{%
1695 \def\@captype{#1}%
1696 \@ifundefined{fst@#1}{}{%
1697 \@nameuse{fst@#1}%
1698 \def\WF@floatstyhook{\let\@currbox\WF@box
1699 \global\setbox\WF@box\float@makebox{\wd\WF@box}}}%
1700 \@ifnextchar[\WF@wr{\WF@wr[]}}
1701 \def\WF@rapt[#1]#2{% final two args: #1 = overhang, #2 = width,
1702 \gdef\WF@ovh{#1}% hold overhang for later, when \width is known
1703 \global\setbox\WF@box\vtop\bgroup \setlength\hsize{#2}%
1704 \expandafter\WF@captionstyhook\expandafter{\@captype}% <= new
1705 \ifdim\hsize>\z@ \@parboxrestore \else
1706 \setbox\z@\hbox\bgroup \let\wf@@caption\caption \let\caption\wf@caption
1707 \ignorespaces \fi}%
1708 \def\WF@captionstyhook#1{%
1709 \let\@captype\@undefined
1710 \@ifundefined{fst@#1}{}{\@float@setevery{#1}}%
1711 \caption@settype{#1}%
1712 \caption@clearmargin
1713 %%% \caption@setoptions{wrapfloat}%
1714 \caption@setoptions{wrap#1}}%
1715 }{}
1716 \endinput
1717 %%
1718 %% End of file `caption_2011-11-10.sty'.