From 013bf3bc293cf08e4b4167cb42180bc355f399c0 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Mon, 13 Apr 2015 13:48:08 +0000 Subject: latex2e 2015/01/01 git-svn-id: svn://tug.org/texlive/trunk@36834 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/tex/latex/base/fltrace.sty | 484 +++++++++++++++++++++++++-- 1 file changed, 450 insertions(+), 34 deletions(-) (limited to 'Master/texmf-dist/tex/latex/base/fltrace.sty') diff --git a/Master/texmf-dist/tex/latex/base/fltrace.sty b/Master/texmf-dist/tex/latex/base/fltrace.sty index 5cf1b2d5334..968e1bc7b3c 100644 --- a/Master/texmf-dist/tex/latex/base/fltrace.sty +++ b/Master/texmf-dist/tex/latex/base/fltrace.sty @@ -8,7 +8,12 @@ %% %% This is a generated file. %% -%% Copyright 1993-2014 +%% The source is maintained by the LaTeX Project team and bug +%% reports for it can be opened at http://latex-project.org/bugs.html +%% (but please observe conditions on bug reports sent to that address!) +%% +%% +%% Copyright 1993-2015 %% The LaTeX3 Project and any individual authors listed elsewhere %% in this file. %% @@ -38,7 +43,7 @@ %% extension .ins) which are part of the distribution. %%% From File: ltoutput.dtx \ProvidesPackage{fltrace} - [2014/04/24 v1.2n + [2015/03/12 v1.2m Tracing LaTeX floats algorithm (FMi)] \def\onecolumn{% \clearpage @@ -174,6 +179,12 @@ \advance \@pageht \skip\footins \advance \@pageht \dp\footins \fi + \ifvbox \@kludgeins + \ifdim \wd\@kludgeins=\z@ + \advance \@pageht \ht\@kludgeins + \fl@trace {Extra size added: \the \ht\@kludgeins}% + \fi + \fi \@reinserts \@addtocurcol \else @@ -191,6 +202,18 @@ \fi \fi } +\def\@testwrongwidth #1{% + \ifdim\dp#1=\f@depth + \fl@trace{\string#1 + \ifdim\f@depth=\z@ single \else double \fi + column float -- ok}% + \else + \global\@testtrue + \fl@trace{\string#1 + \ifdim\f@depth=\z@ double \else single \fi + column float -- wrong}% + \fi}% +\let\f@depth\z@ \def \@opcol {% \if@twocolumn \@outputdblcol @@ -255,7 +278,26 @@ \endgroup \fi } +\IncludeInRelease{2015/01/01}% + {\@startdblcolumn}{float order in 2-column}% \def \@startdblcolumn {% + \@tryfcolumn \@deferlist + \if@fcolmade + \fl@trace{PAGE: double float page completed}% + \else + \begingroup + \let \reserved@b \@deferlist + \global \let \@deferlist \@empty + \let \@elt \@sdblcolelt + \reserved@b + \endgroup + \fi +}% +\EndIncludeInRelease +\IncludeInRelease{0000/00/00}% + {\@startdblcolumn}{float order in 2-column}% +\def \@startdblcolumn {% +% \global \@colht \textheight \@tryfcolumn \@dbldeferlist \if@fcolmade \fl@trace{PAGE: double float page completed}% @@ -267,7 +309,8 @@ \reserved@b \endgroup \fi -} +}% +\EndIncludeInRelease \def \@tryfcolumn #1{% \global \@fcolmadefalse \ifx #1\@empty @@ -328,7 +371,7 @@ \fl@trace{(mid+bot)list: \@midlist, \@botlist: (addtotoporbot-before)}% \if@test - \fl@trace{type already on list: mid or bot---sent to addtobot}% + \fl@trace{type already on list: mid or bot---sent to addtobot}% \else \@flupdates \@topnum \@toproom \@toplist \fl@trace{colroom (after-top) = \the \@colroom}% @@ -352,6 +395,8 @@ \@addtobot \fi } +\IncludeInRelease{2015/01/01}% + {\@addtocurcol}{float order in 2-column}% \def \@addtocurcol {% \fl@trace{***Start addtocurcol}% \@insertfalse @@ -380,6 +425,7 @@ \@flsetnum \@colnum \ifnum \@colnum>\z@ \@bitor\@currtype\@deferlist + \@testwrongwidth\@currbox \fl@trace{deferlist: \@deferlist: (addtocurcol-before)}% \if@test \fl@trace{type already on list: defer (addtocurcol)}% @@ -399,10 +445,10 @@ \global \advance \@textfloatsheight \ht\@currbox \global \advance \@textfloatsheight 2\intextsep \@cons \@midlist \@currbox - \fl@trace{***Success: here}% - \fl@trace{textfloatsheight (after-here) = - \the \@textfloatsheight}% - \fl@trace{colnum (after-here) = \the \@colnum}% + \fl@trace{***Success: here}% + \fl@trace{textfloatsheight (after-here) = + \the \@textfloatsheight}% + \fl@trace{colnum (after-here) = \the \@colnum}% \if@nobreak \nobreak \@nobreakfalse @@ -449,7 +495,132 @@ \@cons\@deferlist\@currbox \fl@trace{deferlist: \@deferlist: (addtocurcol-after)}% \fi -} +}% +\EndIncludeInRelease +\IncludeInRelease{0000/00/00}% + {\@addtocurcol}{float order in 2-column}% +\def \@addtocurcol {% + \fl@trace{***Start addtocurcol}% + \@insertfalse + \@setfloattypecounts + \ifnum \@fpstype=8 + \fl@trace{fpstype !p only (addtocurcol): + \the \@fpstype = 8?}% + \else + \ifnum \@fpstype=24 + \fl@trace{fpstype p only (addtocurcol): + \the \@fpstype = 24?}% + \else + \@flsettextmin + \fl@trace{textfloatsheight (before) = + \the \@textfloatsheight}% + \advance \@textmin \@textfloatsheight + \@reqcolroom \@pageht + \fl@trace{textmin + textfloatsheight: + \the \@textmin}% + \fl@trace{page-so-far: \the \@reqcolroom}% + + \ifdim \@textmin>\@reqcolroom + \@reqcolroom \@textmin + \fl@trace{ORD? textmin being used}% + \fi + \advance \@reqcolroom \ht\@currbox + \fl@trace{float size = + \the \ht \@currbox (addtocurcol)}% + \fl@trace{colroom = + \the \@colroom (addtocurcol)}% + \fl@trace{reqcolroom = + \the \@reqcolroom (addtocurcol)}% + \ifdim \@colroom>\@reqcolroom + \@flsetnum \@colnum + \ifnum \@colnum>\z@ + \@bitor\@currtype\@deferlist + \fl@trace{deferlist: + \@deferlist: (addtocurcol-before)}% + \if@test + \fl@trace{type already on list: + defer (addtocurcol)}% + \else + \@bitor\@currtype\@botlist + \fl@trace{botlist: \@botlist: + (addtocurcol-before)}% + \if@test + \fl@trace{type already on list: + bot---sent to addtobot}% + \@addtobot + \else + \fl@trace{fpstype + \ifodd \@tempcnta OK \else not \fi + here: \the \@fpstype}% + \ifodd \count\@currbox + \advance \@reqcolroom \intextsep + \ifdim \@colroom>\@reqcolroom + \global \advance \@colnum \m@ne + \global \advance + \@textfloatsheight\ht\@currbox + \global \advance + \@textfloatsheight 2\intextsep + \@cons \@midlist \@currbox + \fl@trace{***Success: here}% + \fl@trace{textfloatsheight + (after-here) = + \the \@textfloatsheight}% + \fl@trace{colnum (after-here) = + \the \@colnum}% + \if@nobreak + \nobreak + \@nobreakfalse + \everypar{}% + \else + \addpenalty\interlinepenalty + \fi + \vskip \intextsep + \box\@currbox + \penalty\interlinepenalty + \vskip\intextsep + \ifnum\outputpenalty + <-\@Mii \vskip + -\parskip\fi + \outputpenalty \z@ + \@inserttrue + \else + \fl@trace{Fail---no room at 2nd test of colroom + (addtocorcol \string\intextsep)}% + \fi + \fi + \if@insert + \else + \fl@trace{not here: sent to addtotoporbot}% + \@addtotoporbot + \fi + \fi + \fi + \else + \fl@trace{Fail: colnum = \the \@colnum: + fpstype \the \@fpstype=ORD?}% + \ifnum \@fpstype<\sixt@@n + \fl@trace{ERROR: BANG float not successful + (addtocurcol)}% + \fi + \fi + \else + \fl@trace{Fail---no room: fl box ht: + \the \ht \@currbox (addtocurcol)}% + \fi + \fi + \fi + \if@insert + \else + \@resethfps + \fl@trace{put on deferlist (addtocurcol)}% + \@cons\@deferlist\@currbox + \fl@trace{deferlist: \@deferlist: + (addtocurcol-after)}% + \fi + }% +\EndIncludeInRelease +\IncludeInRelease{2015/01/01} + {\@addtonextcol}{float order in 2-column}% \def\@addtonextcol{% \begingroup \fl@trace{***Start addtonextcol}% @@ -473,6 +644,7 @@ \ifnum\@colnum>\z@ \@bitor\@currtype\@deferlist \fl@trace{deferlist: \@deferlist: (addtonextcol-before)}% + \@testwrongwidth\@currbox \if@test \fl@trace{type already on list: defer (addtonextcol)}% \else @@ -492,12 +664,81 @@ \@cons\@deferlist\@currbox \fl@trace{deferlist: \@deferlist: (addtonextcol-after)}% \fi - \fl@trace{End of addtonextcol -- locally counts:}% - \fl@trace{ col: \the \@colnum. top: \the \@topnum. bot: \the \@botnum.}% + \fl@trace{End of addtonextcol -- locally counts:}% + \fl@trace{col: \the\@colnum. top: \the \@topnum. bot: \the \@botnum.}% \endgroup - \fl@trace{End of addtonextcol -- globally counts:}% - \fl@trace{col: \the \@colnum. top: \the \@topnum. bot: \the \@botnum.}% -} + \fl@trace{End of addtonextcol -- globally counts:}% + \fl@trace{col: \the\@colnum. top: \the \@topnum. bot: \the \@botnum.}% +}% +\EndIncludeInRelease +\IncludeInRelease{0000/00/00}% + {\@addtonextcol}{float order in 2-column}% +\def\@addtonextcol{% + \begingroup + \fl@trace{***Start addtonextcol}% + \@insertfalse + \@setfloattypecounts + \ifnum \@fpstype=8 + \fl@trace{fpstype not curcol: + \the \@fpstype = 8?}% + \else + \ifnum \@fpstype=24 + \fl@trace{fpstype not curcol: + \the \@fpstype = 24?}% + \else + \@flsettextmin + \fl@trace{text-so-far: 0pt (top of col)}% + \@reqcolroom \ht\@currbox + \fl@trace{float size: + \the \@reqcolroom (addtonextcol)}% + + \advance \@reqcolroom \@textmin + \fl@trace{colroom = + \the \@colroom (addtonextcol)}% + \fl@trace{reqcolroom = + \the \@reqcolroom (addtonextcol)}% + \ifdim \@colroom>\@reqcolroom + \@flsetnum \@colnum + \ifnum\@colnum>\z@ + \@bitor\@currtype\@deferlist + \fl@trace{deferlist: \@deferlist: + (addtonextcol-before)}% + \if@test + \fl@trace{type already on list: + defer (addtonextcol)}% + \else + \fl@trace{sent to addtotoporbot + (addtonextcol)}% + \@addtotoporbot + \fi + \fi + \else + \fl@trace{Fail---no room: fl box ht: + \the \ht \@currbox (addtonextcol)}% + \fi + \fi + \fi + \if@insert + \else + \fl@trace{put back on deferlist + (addtonextcol)}% + \@cons\@deferlist\@currbox + \fl@trace{deferlist: \@deferlist: + (addtonextcol-after)}% + \fi + \fl@trace{End of addtonextcol -- + locally counts:}% + \fl@trace{col: \the \@colnum. + top: \the \@topnum. bot: \the \@botnum.}% + \endgroup + \fl@trace{End of addtonextcol -- + globally counts:}% + \fl@trace{col: \the \@colnum. + top: \the \@topnum. bot: \the \@botnum.}% +}% +\EndIncludeInRelease +\IncludeInRelease{2015/01/01}% + {\@addtodblcol}{float order in 2-column}% \def\@addtodblcol{% \begingroup \fl@trace{***Start addtodblcol}% @@ -527,8 +768,8 @@ Ht float: \the \ht \@currbox-BANG}% \ifdim \@dbltoproom>\ht\@currbox \@tempswatrue - \fl@trace{Space OK BANG: space on page = \the \@dbltoproom > - \the \ht \@currbox}% + \fl@trace{Space OK BANG: space on page = + \the \@dbltoproom > \the \ht \@currbox}% \else \fl@trace{fpstype: \the \@fpstype}% \fl@trace{Fail---no room dbltoproom-BANG?:}% @@ -544,10 +785,11 @@ \fi \fi \if@tempswa - \@bitor \@currtype \@dbldeferlist - \fl@trace{dbldeferlist: \@dbldeferlist: (before)}% + \@bitor \@currtype \@deferlist + \fl@trace{(dbl)deferlist: \@deferlist: (before)}% + \@testwrongwidth\@currbox \if@test - \fl@trace{type already on list: dbldefer}% + \fl@trace{type already on list: (dbl)defer}% \else \@tempdima -\ht\@currbox \advance\@tempdima @@ -571,6 +813,101 @@ \fi \fi \if@insert + \else + \fl@trace{put on deferlist}% + \@cons\@deferlist\@currbox + \fl@trace{(dbl)deferlist: \@deferlist: (after)}% + \fi + \fl@trace{End of addtodblcol -- locally count:}% + \fl@trace{ dbltop: \the \@dbltopnum.}% + \endgroup + \fl@trace{End of addtodblcol -- globally count:}% + \fl@trace{dbltop: \the \@dbltopnum.}% +}% +\EndIncludeInRelease +\IncludeInRelease{0000/00/00}% + {\@addtodblcol}{float order in 2-column}% +\def\@addtodblcol{% + \begingroup + \fl@trace{***Start addtodblcol}% + \@insertfalse + \@setfloattypecounts + \@getfpsbit \tw@ + \fl@trace{fpstype \ifodd \@tempcnta OK + \else not \fi dbltop: \the \@fpstype}% + \ifodd\@tempcnta + \@flsetnum \@dbltopnum + \ifnum \@dbltopnum>\z@ + \@tempswafalse + \ifdim \@dbltoproom>\ht\@currbox + \@tempswatrue + \fl@trace{Space OK: \@dbltoproom = + \the \@dbltoproom > \the \ht \@currbox + (dbltoproom)}% + \else + \fl@trace{fpstype: \the \@fpstype (addtodblcol)}% + \ifnum \@fpstype<\sixt@@n + \fl@trace{BANG float ignoring \@dbltoproom}% + \fl@trace{\@spaces \@dbltoproom = + \the \@dbltoproom. + Ht float: \the \ht \@currbox-BANG}% + \advance \@dbltoproom \@textmin + \fl@trace{Local value of texmin: \the\@textmin}% + \fl@trace{\@spaces space on page = + \the \@dbltoproom. + Ht float: \the \ht \@currbox-BANG}% + \ifdim \@dbltoproom>\ht\@currbox + \@tempswatrue + \fl@trace{Space OK BANG: space on page = + \the\@dbltoproom > \the\ht\@currbox}% + \else + \fl@trace{fpstype: \the \@fpstype}% + \fl@trace{Fail---no room dbltoproom-BANG?:}% + \fl@trace{\@spaces space on page = + \the \@dbltoproom. + Ht float: \the \ht \@currbox}% + \fi + \advance \@dbltoproom -\@textmin + \else + \fl@trace{fpstype: \the \@fpstype}% + \fl@trace{Fail---no room dbltoproom-ORD?:}% + \fl@trace{\@spaces \@dbltoproom = + \the \@dbltoproom. + Ht float: \the \ht \@currbox}% + \fi + \fi + \if@tempswa + \@bitor \@currtype \@dbldeferlist + \fl@trace{dbldeferlist: + \@dbldeferlist: (before)}% + \if@test + \fl@trace{type already on list: dbldefer}% + \else + \@tempdima -\ht\@currbox + \advance\@tempdima + -\ifx \@dbltoplist\@empty + \dbltextfloatsep + \else \dblfloatsep \fi + \global \advance \@dbltoproom \@tempdima + \global \advance \@colht \@tempdima + \global \advance \@dbltopnum \m@ne + \@cons \@dbltoplist \@currbox + \fl@trace{dbltopnum (after) = + \the \@dbltopnum}% + \fl@trace{***Success: dbltop}% + \@inserttrue + \fi + \fi + \else + \fl@trace{Fail: dbltopnum = \the \@dbltopnum: + fpstype \the \@fpstype=ORD?}% + \ifnum \@fpstype<\sixt@@n + \fl@trace{ERROR: !t float not successful + (addtodblcol)}% + \fi + \fi + \fi + \if@insert \else \fl@trace{put on dbldeferlist}% \@cons\@dbldeferlist\@currbox @@ -581,13 +918,43 @@ \endgroup \fl@trace{End of addtodblcol -- globally count:}% \fl@trace{dbltop: \the \@dbltopnum.}% -} +}% +\EndIncludeInRelease \def \fl@tracemessage #1{{\let\@elt\@empty\typeout{LaTeX2e: #1}}} \def \tracefloats{\let \fl@trace \fl@tracemessage} \def \tracefloatsoff {\let \fl@trace \@gobble} \tracefloatsoff \def \fl@traceval #1{\fl@trace{\string #1 = \the #1}} +\IncludeInRelease{2015/01/01}{\tracefloatvals}% + {trace float vals}% \def \tracefloatvals{% + \begingroup + \@dblfloatplacement + \@floatplacement + \fl@trace{***Float placement parameters:}% + \fl@traceval\@colnum + \fl@traceval\@colroom + \fl@traceval\@topnum + \fl@traceval\@toproom + \fl@traceval\@botnum + \fl@traceval\@botroom + \fl@traceval\@fpmin + \fl@trace{\string\textfraction = \textfraction}% + \fl@traceval\@dbltopnum + \fl@traceval\@dbltoproom + \fl@trace{\string\textfraction = \textfraction}% + \fl@trace{toplist: \@toplist}% + \fl@trace{botlist: \@botlist}% + \fl@trace{midlist: \@midlist}% + \fl@trace{deferlist: \@deferlist}% + \fl@trace{dbltoplist: \@dbltoplist}% + \endgroup +} +\EndIncludeInRelease +\IncludeInRelease{0000/00/00}{\tracefloatvals}% + {trace float vals}% +\def \tracefloatvals{% + \begingroup \@dblfloatplacement \@floatplacement \fl@trace{***Float placement parameters:}% @@ -608,20 +975,18 @@ \fl@trace{deferlist: \@deferlist}% \fl@trace{dbltoplist: \@dbltoplist}% \fl@trace{dbldeferlist: \@dbldeferlist}% + \endgroup } +\EndIncludeInRelease \@ifpackageloaded{flafter} - {\PackageWarning{fltrace}{Load 'fltrace' before 'flafter'\MessageBreak - Attempting to recover by reloading 'flafter'}% + {\PackageWarningNoLine{fltrace}{Load 'fltrace' before 'flafter'\MessageBreak + Attempting to recover by reloading 'flafter'}% \expandafter\let\csname ver@flafter.sty\endcsname\relax + \def\reserved@a#1{% + \expandafter\let\csname\string#1+flafter+IIR\endcsname\relax}% + \reserved@a\@addtocurcol + \reserved@a\@addtonextcol \RequirePackage{flafter}}{} -\AtBeginDocument{\@ifpackageloaded{fixltx2e}{% - \PackageError{fltrace}{'fltrace' can't be used together with - 'fixltx2e'}% - {The 'fixltx2e' package has a corrected float algorithm that - currently \MessageBreak - can't be traced using 'fltrace'. Please remove - 'fltrace' if you want\MessageBreak - to make use of the corrections in 'fixltx2e'.}\stop}{}} \def \@fpsadddefault {% \fl@trace{fps changed from: \@fps}% \edef \@fps {\@fps\csname fps@\@captype \endcsname}% @@ -691,7 +1056,8 @@ \def \@flcheckspace #1#2{% \advance \@reqcolroom \ifx #2\@empty \textfloatsep \else \floatsep \fi - \fl@trace{colroom = \the \@colroom (flcheckspace \string#1 \string#2)}% + \fl@trace{colroom = \the \@colroom + (flcheckspace \string#1 \string#2)}% \fl@trace{reqcolroom = \the \@reqcolroom (flcheckspace \string#1 \string#2)}% \ifdim \@colroom>\@reqcolroom @@ -727,10 +1093,58 @@ \@tryfcolumn #1% \endgroup \if@fcolmade - \fl@trace{PAGE: in \string\clearpage \if@twocolumn ---twocolumn\fi---}% + \fl@trace{PAGE: in \string\clearpage + \if@twocolumn ---twocolumn\fi---}% \fl@trace{----- float column/page completed from \string#1}% \fi } +\IncludeInRelease{2015/01/01}% + {\@outputdblcol}{2 column marks}% +\def\@outputdblcol{% + \if@firstcolumn + \global\@firstcolumnfalse + \global\setbox\@leftcolumn\copy\@outputbox + \fl@trace{PAGE: first column boxed}% + \splitmaxdepth\maxdimen + \vbadness\maxdimen + \setbox\@outputbox\vbox{\unvbox\@outputbox\unskip}% + \setbox\@outputbox\vsplit\@outputbox to\maxdimen + \toks@\expandafter{\topmark}% + \xdef\@firstcoltopmark{\the\toks@}% + \toks@\expandafter{\splitfirstmark}% + \xdef\@firstcolfirstmark{\the\toks@}% + \ifx\@firstcolfirstmark\@empty + \global\let\@setmarks\relax + \else + \gdef\@setmarks{% + \let\firstmark\@firstcolfirstmark + \let\topmark\@firstcoltopmark}% + \fi + \else + \global\@firstcolumntrue + \setbox\@outputbox\vbox{% + \hb@xt@\textwidth{% + \hb@xt@\columnwidth{\box\@leftcolumn \hss}% + \hfil + {\normalcolor\vrule \@width\columnseprule}% + \hfil + \hb@xt@\columnwidth{\box\@outputbox \hss}}}% + \fl@trace{PAGE: second column also boxed}% + \@combinedblfloats + \@setmarks + \@outputpage + \fl@trace{PAGE: two column page completed}% + \begingroup + \@dblfloatplacement + \@startdblcolumn + \@whilesw\if@fcolmade \fi{\@outputpage + \fl@trace{PAGE: double float page completed}% + \@startdblcolumn}% + \endgroup + \fi}% +\EndIncludeInRelease +\IncludeInRelease{0000/00/00}% + {\@outputdblcol}{2 column marks}% \def\@outputdblcol{% \if@firstcolumn \global \@firstcolumnfalse @@ -743,7 +1157,8 @@ \hb@xt@\columnwidth {% \box\@leftcolumn \hss}% \hfil - {\normalcolor\vrule \@width\columnseprule}% + {\normalcolor\vrule + \@width\columnseprule}% \hfil \hb@xt@\columnwidth {% \box\@outputbox \hss}% @@ -762,7 +1177,8 @@ \@startdblcolumn}% \endgroup \fi -} +}% +\EndIncludeInRelease \endinput %% %% End of file `fltrace.sty'. -- cgit v1.2.3