From e9a9d7ef171d4f2a125839da7a046f40f200fc0e Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Sun, 3 Jun 2018 21:23:43 +0000 Subject: caption git-svn-id: svn://tug.org/texlive/trunk@47917 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/tex/latex/caption/bicaption.sty | 4 +- Master/texmf-dist/tex/latex/caption/caption.sty | 17 ++-- Master/texmf-dist/tex/latex/caption/caption2.sty | 4 +- Master/texmf-dist/tex/latex/caption/caption3.sty | 96 ++++++++++++++++++++-- Master/texmf-dist/tex/latex/caption/ltcaption.sty | 4 +- Master/texmf-dist/tex/latex/caption/newfloat.sty | 32 ++++---- Master/texmf-dist/tex/latex/caption/subcaption.sty | 10 +-- Master/texmf-dist/tex/latex/caption/totalcount.sty | 8 +- 8 files changed, 127 insertions(+), 48 deletions(-) (limited to 'Master/texmf-dist/tex/latex/caption') diff --git a/Master/texmf-dist/tex/latex/caption/bicaption.sty b/Master/texmf-dist/tex/latex/caption/bicaption.sty index c7df5e861d7..7e1fd7ebf47 100644 --- a/Master/texmf-dist/tex/latex/caption/bicaption.sty +++ b/Master/texmf-dist/tex/latex/caption/bicaption.sty @@ -6,9 +6,9 @@ %% %% bicaption.dtx (with options: `package') %% -%% Copyright (C) 1994-2016 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm) +%% Copyright (C) 1994-2018 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm) %% -%% https://github.com/axelsommerfeldt/latex-caption +%% https://github.com/axelsommerfeldt/caption %% %% -------------------------------------------------------------------------- %% diff --git a/Master/texmf-dist/tex/latex/caption/caption.sty b/Master/texmf-dist/tex/latex/caption/caption.sty index 139599456ae..5c4f64dc22a 100644 --- a/Master/texmf-dist/tex/latex/caption/caption.sty +++ b/Master/texmf-dist/tex/latex/caption/caption.sty @@ -6,9 +6,9 @@ %% %% caption.dtx (with options: `package') %% -%% Copyright (C) 1994-2016 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm) +%% Copyright (C) 1994-2018 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm) %% -%% https://github.com/axelsommerfeldt/latex-caption +%% https://github.com/axelsommerfeldt/caption %% %% -------------------------------------------------------------------------- %% @@ -37,8 +37,8 @@ %% caption-deu.tex, caption-eng.tex, and caption-rus.tex. %% \NeedsTeXFormat{LaTeX2e}[1994/12/01] -\ProvidesPackage{caption}[2017/03/19 v3.3-145 Customizing captions (AR)] -\RequirePackage{caption3}[2016/02/01] % needs v1.7-130 or newer +\ProvidesPackage{caption}[2018/05/01 v3.3-147 Customizing captions (AR)] +\RequirePackage{caption3}[2018/05/01] % needs v1.8 or newer \caption@ifbool{documentclass}{}{% \caption@WarningNoLine{% Unsupported document class (or package) detected,\MessageBreak @@ -1484,9 +1484,12 @@ \let\caption@ORI@lst@MakeCaption\lst@MakeCaption \def\lst@MakeCaption#1{% #1 is `t' or `b' \begingroup - \ifdim\hsize>\linewidth - \hsize\linewidth - \fi + \@tempdima\linewidth + \advance\@tempdima\lst@xleftmargin + \advance\@tempdima\lst@xrightmargin + \ifdim\hsize>\@tempdima + \hsize\@tempdima + \fi \caption@setposition{#1}% \caption@iftop{% \@tempdima\belowcaptionskip diff --git a/Master/texmf-dist/tex/latex/caption/caption2.sty b/Master/texmf-dist/tex/latex/caption/caption2.sty index 37e7fbc6300..61374617e34 100644 --- a/Master/texmf-dist/tex/latex/caption/caption2.sty +++ b/Master/texmf-dist/tex/latex/caption/caption2.sty @@ -6,9 +6,9 @@ %% %% caption2.dtx (with options: `package') %% -%% Copyright (C) 1994-2016 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm) +%% Copyright (C) 1994-2018 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm) %% -%% https://github.com/axelsommerfeldt/latex-caption +%% https://github.com/axelsommerfeldt/caption %% %% -------------------------------------------------------------------------- %% diff --git a/Master/texmf-dist/tex/latex/caption/caption3.sty b/Master/texmf-dist/tex/latex/caption/caption3.sty index a36da9db442..3f51ac858c6 100644 --- a/Master/texmf-dist/tex/latex/caption/caption3.sty +++ b/Master/texmf-dist/tex/latex/caption/caption3.sty @@ -8,7 +8,7 @@ %% %% Copyright (C) 1994-2018 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm) %% -%% https://github.com/axelsommerfeldt/latex-caption +%% https://github.com/axelsommerfeldt/caption %% %% -------------------------------------------------------------------------- %% @@ -37,7 +37,7 @@ %% caption-deu.tex, caption-eng.tex, and caption-rus.tex. %% \NeedsTeXFormat{LaTeX2e}[1994/12/01] -\ProvidesPackage{caption3}[2018/04/15 v1.7-167 caption3 kernel (AR)] +\ProvidesPackage{caption3}[2018/05/27 v1.8a caption3 kernel (AR)] \providecommand\caption@FixArabTeX{% \def\caption@tempa##1{}% \ifx\caption@tempa\@gobble @@ -313,7 +313,7 @@ \expandafter\caption@ifempty@list\csname caption@opt@#2\endcsname {\caption@removefromoptlist{#2}}{}% \caption@tempa{\caption@Warning{% - Option `#1' was not in list `#2'\MessageBreak}}} + Option `#1' was not in list `#2'}}} \newcommand*\showcaptionsetup[2][\@firstofone]{% \@bsphack \GenericWarning{}{% @@ -655,6 +655,7 @@ \DeclareCaptionLabelFormat{parens}{\bothIfFirst{#1}{\nobreakspace}(#2)} \DeclareCaptionLabelFormat{brace}{\bothIfFirst{#1}{\nobreakspace}#2)} \DeclareCaptionLabelFormat{autodot}{\bothIfFirst{#1}{\nobreakspace}#2\autodot} +\DeclareCaptionLabelFormat{unnumbered}{#1} \def\caption@lfmt@default{\caption@lfmt@simple} \newcommand\DeclareCaptionLabelSeparator{% \caption@teststar\caption@declarelabelseparator\@gobble\@firstofone} @@ -789,12 +790,70 @@ \DeclareCaptionFont{rm}{\rmfamily} \DeclareCaptionFont{sf}{\sffamily} \DeclareCaptionFont{tt}{\ttfamily} +\DeclareCaptionFont{tiny}{\tiny} \DeclareCaptionFont{scriptsize}{\scriptsize} \DeclareCaptionFont{footnotesize}{\footnotesize} \DeclareCaptionFont{small}{\small} \DeclareCaptionFont{normalsize}{\normalsize} \DeclareCaptionFont{large}{\large} \DeclareCaptionFont{Large}{\Large} +\DeclareCaptionFont{LARGE}{\LARGE} +\DeclareCaptionFont{huge}{\huge} +\DeclareCaptionFont{Huge}{\Huge} +\newcommand\caption@smaller{% + \ifx\@currsize\tiny + \relax + \else\ifx\@currsize\scriptsize + \tiny + \else\ifx\@currsize\footnotesize + \scriptsize + \else\ifx\@currsize\small + \footnotesize + \else\ifx\@currsize\normalsize + \small + \else\ifx\@currsize\large + \normalsize + \else\ifx\@currsize\Large + \large + \else\ifx\@currsize\LARGE + \Large + \else\ifx\@currsize\huge + \LARGE + \else\ifx\@currsize\Huge + \huge + \else + \caption@Warning{% + Cannot determine current font size.\MessageBreak + Try setting it with `size=' explicitly}% + \fi\fi\fi\fi\fi\fi\fi\fi\fi\fi} +\DeclareCaptionFont{smaller}{\caption@smaller} +\newcommand\caption@larger{% + \ifx\@currsize\tiny + \scriptsize + \else\ifx\@currsize\scriptsize + \footnotesize + \else\ifx\@currsize\footnotesize + \small + \else\ifx\@currsize\small + \normalsize + \else\ifx\@currsize\normalsize + \large + \else\ifx\@currsize\large + \Large + \else\ifx\@currsize\Large + \LARGE + \else\ifx\@currsize\LARGE + \huge + \else\ifx\@currsize\huge + \Huge + \else\ifx\@currsize\Huge + \relax + \else + \caption@Warning{% + Cannot determine current font size.\MessageBreak + Try setting it with `size=' explicitly}% + \fi\fi\fi\fi\fi\fi\fi\fi\fi\fi} +\DeclareCaptionFont{larger}{\caption@larger} \DeclareCaptionFont{sansmath}{\sansmath} \DeclareCaptionFont{singlespacing}{% \caption@ifundefined\setspace@singlespace{}{% @@ -1124,11 +1183,15 @@ \endgroup\expandafter\@secondoftwo \fi} \DeclareCaptionLabelFormat{default}{% - \caption@ifbeamertemplate{numbered}{% - \caption@lfmt@simple{#1}{#2}}{#1}} + \caption@ifbeamertemplate{numbered}% + \caption@lfmt@simple + \caption@lfmt@unnumbered + {#1}{#2}} \DeclareCaptionLabelFormat{default@magyar}{% - \caption@ifbeamertemplate{numbered}{% - \caption@lfmt@simple@magyar{#1}{#2}}{#1}} + \caption@ifbeamertemplate{numbered}% + \caption@lfmt@simple@magyar + \caption@lfmt@unnumbered + {#1}{#2}} \@ifundefined{@@magyar@captionfix}\AtBeginDocument\@firstofone{% \@ifundefined{@@magyar@captionfix}{}{% \g@addto@macro\@@magyar@captionfix{% @@ -1143,8 +1206,10 @@ \usebeamerfont*{caption}% \usebeamercolor[fg]{caption}} \DeclareCaptionDefaultFont{labelfont}{% + \setbeamercolor*{caption}{}% avoid setting "caption" color additionally \usebeamercolor[fg]{caption name}% - \usebeamerfont*{caption name}} + \setbeamerfont*{caption}{}% avoid setting "caption" font additionally + \usebeamerfont{caption name}} \DeclareCaptionDefaultJustification{\raggedright} \DeclareOption{beamerclass}{% \renewcommand\caption@ifslc{% @@ -1467,14 +1532,20 @@ \newcommand*\caption@singleline{% \caption@xsetup\caption@opt@singleline \let\caption@fmt\caption@slfmt} -\newcommand*\caption@prepareslc{% +\@ifundefined{caption@prepareslc}\def\g@addto@macro\caption@prepareslc{% \let\label\caption@gobble + \let\hypertarget\@gobbletwo \let\caption@footnotemark@ORI\footnotemark \def\footnote{\caption@withoptargs\caption@footnote}% \def\footnotemark{\caption@withoptargs\caption@footnotemark}% \let\@footnotetext\caption@gobble + \let\caption@endnotemark@ORI\endnotemark + \def\endnote{\caption@withoptargs\caption@endnote}% + \def\endnotemark{\caption@withoptargs\caption@endnotemark}% \let\@endnotetext\caption@gobble \let\pagenote\caption@gobble + \let\acused\@gobble + \let\AC@placelabel\@gobble \let\glsunset\@gobble } \newcommand\caption@footnote[2]{% @@ -1484,6 +1555,13 @@ \let\stepcounter\caption@l@stepcounter \caption@footnotemark@ORI#1% \endgroup} +\newcommand\caption@endnote[2]{% + \caption@endnotemark{#1}} +\newcommand\caption@endnotemark[1]{% + \begingroup + \let\stepcounter\caption@l@stepcounter + \caption@endnotemark@ORI#1 + \endgroup} \newcommand*\caption@l@stepcounter[1]{% \advance\csname c@#1\endcsname\@ne\relax} \newcommand*\caption@applyfont{% diff --git a/Master/texmf-dist/tex/latex/caption/ltcaption.sty b/Master/texmf-dist/tex/latex/caption/ltcaption.sty index 089ae61246f..deafb078f46 100644 --- a/Master/texmf-dist/tex/latex/caption/ltcaption.sty +++ b/Master/texmf-dist/tex/latex/caption/ltcaption.sty @@ -6,9 +6,9 @@ %% %% ltcaption.dtx (with options: `package') %% -%% Copyright (C) 1994-2016 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm) +%% Copyright (C) 1994-2018 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm) %% -%% https://github.com/axelsommerfeldt/latex-caption +%% https://github.com/axelsommerfeldt/caption %% %% -------------------------------------------------------------------------- %% diff --git a/Master/texmf-dist/tex/latex/caption/newfloat.sty b/Master/texmf-dist/tex/latex/caption/newfloat.sty index 5bbbabb73c0..94f79676aa5 100644 --- a/Master/texmf-dist/tex/latex/caption/newfloat.sty +++ b/Master/texmf-dist/tex/latex/caption/newfloat.sty @@ -6,9 +6,9 @@ %% %% newfloat.dtx (with options: `package') %% -%% Copyright (C) 1994-2016 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm) +%% Copyright (C) 1994-2018 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm) %% -%% https://github.com/axelsommerfeldt/latex-caption +%% https://github.com/axelsommerfeldt/caption %% %% -------------------------------------------------------------------------- %% @@ -37,7 +37,7 @@ %% caption-deu.tex, caption-eng.tex, and caption-rus.tex. %% \NeedsTeXFormat{LaTeX2e}[1994/12/01] -\ProvidesPackage{newfloat}[2015/09/17 v1.1-109 Defining new floating environments (AR)] +\ProvidesPackage{newfloat}[2018/03/04 v1.1a Defining new floating environments (AR)] \newcommand*\newfloat@Info[1]{% \PackageInfo{newfloat}{#1}} \newcommand*\newfloat@InfoNoLine[1]{% @@ -64,20 +64,18 @@ \def\@DeclareFloatingEnvironment[#1]#2{% \newfloat@Info{New float `#2' with options `#1'}% \newfloat@ifundefined{c@#2}{\newcounter{#2}}% - \ifdefined\c@float@type % from float package - \expandafter\edef\csname ftype@#2\endcsname{\the\value{float@type}}% - \addtocounter{float@type}{\value{float@type}}% - \else\ifdefined\c@newflo@tctr % from memoir document class - \expandafter\edef\csname ftype@#2\endcsname{\the\c@newflo@tctr}% - \advance\c@newflo@tctr \c@newflo@tctr - \else - \ifdefined\newfloat@ftype \else - \newcount\newfloat@ftype - \newfloat@ftype=8\relax - \fi - \expandafter\xdef\csname ftype@#2\endcsname{\the\newfloat@ftype}% - \advance\newfloat@ftype\newfloat@ftype - \fi\fi + \@ifundefined{c@float@type}% from float package + {\@ifundefined{c@newflo@tctr}% from memoir document class + {\ifdefined\newfloat@ftype \else + \newcount\newfloat@ftype + \newfloat@ftype=8\relax + \fi + \expandafter\xdef\csname ftype@#2\endcsname{\the\newfloat@ftype}% + \advance\newfloat@ftype\newfloat@ftype}% + {\expandafter\edef\csname ftype@#2\endcsname{\the\c@newflo@tctr}% + \advance\c@newflo@tctr \c@newflo@tctr}}% + {\expandafter\edef\csname ftype@#2\endcsname{\the\value{float@type}}% + \addtocounter{float@type}{\value{float@type}}}% \newfloat@Info{float type `#2'=\@nameuse{ftype@#2}}% \newfloat@def{fnum@#2}% {\@nameuse{#2name}\nobreakspace\@nameuse{the#2}\@nameuse{autodot}}% diff --git a/Master/texmf-dist/tex/latex/caption/subcaption.sty b/Master/texmf-dist/tex/latex/caption/subcaption.sty index 37674ef5063..690aa44b6e6 100644 --- a/Master/texmf-dist/tex/latex/caption/subcaption.sty +++ b/Master/texmf-dist/tex/latex/caption/subcaption.sty @@ -6,9 +6,9 @@ %% %% subcaption.dtx (with options: `package') %% -%% Copyright (C) 1994-2016 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm) +%% Copyright (C) 1994-2018 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm) %% -%% https://github.com/axelsommerfeldt/latex-caption +%% https://github.com/axelsommerfeldt/caption %% %% -------------------------------------------------------------------------- %% @@ -37,8 +37,8 @@ %% caption-deu.tex, caption-eng.tex, and caption-rus.tex. %% \NeedsTeXFormat{LaTeX2e}[1994/12/01] -\ProvidesPackage{subcaption}[2016/05/22 v1.1-161 Sub-captions (AR)] -\RequirePackage{caption}[2012/03/25] % needs v3.3 or newer +\ProvidesPackage{subcaption}[2018/05/01 v1.1-162 Sub-captions (AR)] +\RequirePackage{caption}[2018/05/01] % needs v3.3-147 or newer \newcommand\subcaption@CheckCompatibility{% \@ifpackageloaded{subfigure}{% \PackageError{subcaption}% @@ -69,7 +69,7 @@ } \caption@SetupOptions{subcaption}{\captionsetup[sub]{#2}}% \caption@ExecuteOptions{subcaption}{% - font+=small,labelformat=parens,labelsep=space,skip=6pt,list=0,hypcap=0} + font+=smaller,labelformat=parens,labelsep=space,skip=6pt,list=0,hypcap=0} \caption@ProcessOptions*{subcaption} \caption@ForEachType{\DeclareCaptionSubType{#1}} \caption@ifundefined\newsubfloat{}{% diff --git a/Master/texmf-dist/tex/latex/caption/totalcount.sty b/Master/texmf-dist/tex/latex/caption/totalcount.sty index 5a429eabc0d..75c29af3cf6 100644 --- a/Master/texmf-dist/tex/latex/caption/totalcount.sty +++ b/Master/texmf-dist/tex/latex/caption/totalcount.sty @@ -6,9 +6,9 @@ %% %% totalcount.dtx (with options: `package') %% -%% Copyright (C) 1994-2016 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm) +%% Copyright (C) 1994-2018 Axel Sommerfeldt (axel.sommerfeldt@f-m.fm) %% -%% https://github.com/axelsommerfeldt/latex-caption +%% https://github.com/axelsommerfeldt/caption %% %% -------------------------------------------------------------------------- %% @@ -37,7 +37,7 @@ %% caption-deu.tex, caption-eng.tex, and caption-rus.tex. %% \NeedsTeXFormat{LaTeX2e}[1994/12/01] -\ProvidesPackage{totalcount}[2013/05/12 v1.0-92 Total values of counters (AR)] +\ProvidesPackage{totalcount}[2018/01/21 v1.0a Total values of counters (AR)] \newcommand*\DeclareTotalCounter[1]{% \newcounter{totalcount@#1}% \@namedef{total#1s}{\nfss@text{\reset@font\bfseries ??}}% @@ -67,7 +67,7 @@ \@ifundefined{c@totalcount@#1}% {}% {\global\@namedef{total#1s}{#2\totalcount@xspace}% - \ifnum#2=0\relax \else + \ifnum#2<1\relax \else \global\@nameuse{total#1strue}% \fi}} \AtBeginDocument{\AtEndDocument{% -- cgit v1.2.3