From 9d5158d37d74f6401908f8be395bc955664b3f39 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Tue, 22 Feb 2022 21:07:59 +0000 Subject: hvfloat (22feb22) git-svn-id: svn://tug.org/texlive/trunk@62141 c570f23f-e606-0410-a88d-b1316a301751 --- .../texmf-dist/tex/latex/hvfloat/hvfloat-fps.sty | 2 +- Master/texmf-dist/tex/latex/hvfloat/hvfloat.sty | 72 ++++++++++++++-------- 2 files changed, 47 insertions(+), 27 deletions(-) (limited to 'Master/texmf-dist/tex/latex') diff --git a/Master/texmf-dist/tex/latex/hvfloat/hvfloat-fps.sty b/Master/texmf-dist/tex/latex/hvfloat/hvfloat-fps.sty index 0090e80f5f0..a86244b9e54 100644 --- a/Master/texmf-dist/tex/latex/hvfloat/hvfloat-fps.sty +++ b/Master/texmf-dist/tex/latex/hvfloat/hvfloat-fps.sty @@ -1,4 +1,4 @@ -%% $Id: hvfloat-fps.sty 120 2021-06-20 13:31:02Z herbert $ +%% $Id: hvfloat-fps.sty 121 2021-06-20 13:36:11Z herbert $ %% \NeedsTeXFormat{LaTeX2e} %% diff --git a/Master/texmf-dist/tex/latex/hvfloat/hvfloat.sty b/Master/texmf-dist/tex/latex/hvfloat/hvfloat.sty index e0a378d28f6..739d7599940 100644 --- a/Master/texmf-dist/tex/latex/hvfloat/hvfloat.sty +++ b/Master/texmf-dist/tex/latex/hvfloat/hvfloat.sty @@ -1,4 +1,4 @@ -%% $Id: hvfloat.sty 257 2021-09-23 11:44:35Z herbert $ +%% $Id: hvfloat.sty 392 2022-01-09 10:20:33Z herbert $ %% %% %% IMPORTANT NOTICE: @@ -15,8 +15,8 @@ %% `hvfloat' offers rotating of captions and objects for floats %% \NeedsTeXFormat{LaTeX2e} -\def\fileversion{2.34} -\def\filedate{2021/09/23} +\def\fileversion{2.36} +\def\filedate{2022/02/22} %\message{`hvfloat' v\fileversion, \filedate\space (Herbert Voss)} \ProvidesPackage{hvfloat}[\filedate\space v\fileversion\space special floating objects (hv)] \let\hvFloatFileVersion\fileversion @@ -138,17 +138,17 @@ \def\hvSet@capVPos{center}% it is relativ to the object } -\define@choicekey*+{hvSet}{allHPos}[\val\nr]{left,center,right}[center]{% - \def\hvSet@allHPos{#1}% +\define@choicekey*+{hvSet}{capHPos}[\val\nr]{left,center,right}[center]{% + \def\hvSet@capHPos{#1}% \ifcase\nr\relax - \gdef\hv@@allHPos{l}% + \gdef\hv@@caoHPos{l}% \or - \gdef\hv@@allHPos{c}% + \gdef\hv@@capHPos{c}% \else - \gdef\hv@@allHPos{r}% + \gdef\hv@@capHPos{r}% \fi -}{\PackageWarning{hvfloat}{erroneous input (#1) for allHPos ignored. Using center.}% - \def\hvSet@capVPos{center}% it is relativ to the object +}{\PackageWarning{hvfloat}{erroneous input (#1) for capHPos ignored. Using center.}% + \def\hvSet@capHPos{center}% it is relativ to the object } \define@choicekey*+{hvSet}{objectPos}[\val\nr]{left,center,right,inner,outer}[center]{% @@ -238,7 +238,7 @@ \newcommand\setDefaults{% \hv@set{% floatPos=, rotAngle=0, capWidth=n, capAngle=0, objectAngle=0, - capPos=bottom, capVPos=center, objectPos=center, allHPos=center, + capPos=bottom, capVPos=center, objectPos=center, capHPos=center, floatCapSep=5pt, useOBox=false, onlyText=false, wide=false, fullpage=false, FULLPAGE=false, doubleFULLPAGE=false, doublePage=false, doublePAGE=false, @@ -659,6 +659,7 @@ \ifnum\hvSet@capAngle=0 % need rotation? \savebox\hvCaptionBox{% NO rotation \minipage[b]{\hvCapWidth}%% minipage, to get hyphenation +% \ifx\relax\hv@caption@format\relax\else\expandafter\captionsetup\expandafter{\hv@caption@format}\fi \ifhv@nonFloat \ifhv@onlyText \hv@longCap @@ -692,7 +693,7 @@ \savebox\hvCaptionBox{% Rotation \rotatebox{\hvSet@capAngle}{% \minipage[b]{\hvCapWidth}%% minipage, to get hyphenation -% \ifx\relax\hv@caption@format\relax\else\expandafter\captionsetup\expandafter{\hv@caption@format}\fi +% \ifx\relax\hv@caption@format\relax\else\expandafter\captionsetup\expandafter{\hv@caption@format}\fi \ifhv@nonFloat \ifhv@onlyText \hv@longCap @@ -777,6 +778,7 @@ \else \ifx\hvSet@capPos\hv@Outer \ifoddpageoroneside\hv@@capPos=2\else\hv@@capPos=0\fi + % even page (left=0) | odd page (oneside) (right=2) \else \ifx\hvSet@capPos\hv@Before \hv@@capPos=0% same as cappos=right @@ -792,6 +794,7 @@ \fi \fi %%%% +%\typeout{>>>>>>>>>Pos: \the\hv@@capPos}% \savebox{\@tempboxa}{% ***** @tempbox start \expandafter\ifcase\the\hv@@capPos% 0 is LEFT START \ifcase \ifx\hvSet@capVPos\hv@Center @@ -815,7 +818,15 @@ \else \begin{minipage}{\wd\hvObjectBox}% \fi - \centering + \ifx\hvSet@capHPos\hv@Left% horizontal justification + \raggedright + \else + \ifx\hvSet@capHPos\hv@Center + \centering + \else + \raggedleft + \fi + \fi \ifhv@fbox \fbox{\usebox{\hvCaptionBox}}\\[0.5\hvBelowCaptionSkip]% \fbox{\usebox{\hvObjectBox}}% @@ -846,7 +857,15 @@ \else \begin{minipage}{\wd\hvObjectBox}% \fi - \centering + \ifx\hvSet@capHPos\hv@Left% horizontal justification + \raggedright + \else + \ifx\hvSet@capHPos\hv@Center + \centering + \else + \raggedleft + \fi + \fi \ifhv@fbox \fbox{\usebox{\hvObjectBox}}\\[0.5\hvAboveCaptionSkip]% \fbox{\usebox{\hvCaptionBox}}% @@ -1072,9 +1091,8 @@ \global\setlength\hv@leftPageObjectWidth{\dimexpr\paperwidth-1in-\evensidemargin-\hvSet@bindCorrection}% \global\setlength\hv@tempWidthA{\the\dimexpr1in+\oddsidemargin-\hvSet@bindCorrection}% \xdef\hv@caption@format@temp{\hv@caption@format}% it gets lost otherwise for next afterpage - \setlength\@dblfpbot{0\p@ \@plus 1fil}% + \setlength\@dblfpbot{0\p@ \@plus 1fil}% \global\hv@switchTypefalse -% \endgroup% started at main macro \hvFloat \setcounter{hv@tempCNTfigA}{\value{figure}}% \setcounter{hv@tempCNTfigB}{\value{figure}}% \setcounter{hv@tempCNTtabA}{\value{table}}% @@ -1194,7 +1212,9 @@ \hfuzz=\maxdimen \expandafter\hvFloatSet\expandafter{\hv@save@setting}% \global\savebox\hvObjectBox{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}% + \global\setlength\hv@tempWidthA{\the\dimexpr1in+\oddsidemargin-\hvSet@bindCorrection}% FÜR DTK \hspace*{-\hv@tempWidthA}% + \global\setlength\hv@leftPageObjectWidth{\the\dimexpr\paperwidth-1in-\evensidemargin-\hvSet@bindCorrection}% FÜR FTK \savebox\hv@rightBox{\clipbox*{\hv@leftPageObjectWidth{} -\depth{} \width{} \height{}}{\usebox\hvObjectBox}}% \global\setlength\hv@tempWidthB{\dimexpr\textwidth-\wd\hv@rightBox-\hvSet@bindCorrection+1in+\oddsidemargin-\hv@floatCapSep\relax}% \hv@typeout{Height of right box: \the\ht\hv@rightBox}% @@ -1509,7 +1529,7 @@ \afterpage{% \hfuzz=\maxdimen \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}% - \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip+2\lineskip}% no interlineskip + \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip-\parskip+1.5\lineskip}% no interlineskip \hspace*{\the\dimexpr-\evensidemargin-\parindent-1in}% \thispagestyle{empty}% \ifx\hv@floatType\hv@figure @@ -1523,7 +1543,7 @@ \if@twocolumn\newpage\null\newpage\fi \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}% \thispagestyle{empty}% - \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip+2\lineskip}% -0.5\paperheight+0.5\ht\hvObjectBox + \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip-\parskip+1.5\lineskip}% -0.5\paperheight+0.5\ht\hvObjectBox \hspace*{\hv@tempWidthA}% \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}% \clipbox*{\the\hv@leftPageObjectWidth{} \dp\hvObjectBox{} \wd\hvObjectBox{} \ht\hvObjectBox}{\usebox\hvObjectBox}% @@ -1543,7 +1563,7 @@ \afterpage{% \hfuzz=\maxdimen \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}% - \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip+2\lineskip}% no interlineskip + \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip-\parskip+1.5\lineskip}% no interlineskip \hspace*{\the\dimexpr-\evensidemargin-\parindent-1in}% \thispagestyle{empty}% \clipbox*{0 \the\dp\hvObjectBox{} \the\hv@leftPageObjectWidth{} \the\ht\hvObjectBox}{\usebox\hvObjectBox}% @@ -1557,7 +1577,7 @@ \if@twocolumn\null\newpage\fi \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}% \thispagestyle{empty}% - \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip+2\lineskip}% -0.5\paperheight+0.5\ht\hvObjectBox + \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip-\parskip+1.5\lineskip}% -0.5\paperheight+0.5\ht\hvObjectBox \hspace*{\hv@tempWidthA}% \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}% \clipbox*{\the\hv@leftPageObjectWidth{} \dp\hvObjectBox{} \wd\hvObjectBox{} \ht\hvObjectBox}{\usebox\hvObjectBox}% @@ -1588,7 +1608,7 @@ \def\do@hvFloat@doubleFULLPAGE@CaptionAfterTwoCol{% \afterpage{% \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}% - \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip+2\lineskip}% no interlineskip + \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip-\parskip+1.5\lineskip}% no interlineskip \hspace*{\the\dimexpr-\evensidemargin-\parindent-1in}% \thispagestyle{empty}% \ifx\hv@floatType\hv@figure @@ -1601,7 +1621,7 @@ \newpage\if@twocolumn\null\newpage\fi \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}% \thispagestyle{empty}% - \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip+2\lineskip}% -0.5\paperheight+0.5\ht\hvObjectBox + \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip-\parskip+1.5\lineskip}% -0.5\paperheight+0.5\ht\hvObjectBox \hspace*{\hv@tempWidthA}% \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}% \clipbox*{\the\hv@leftPageObjectWidth{} \dp\hvObjectBox{} \wd\hvObjectBox{} \ht\hvObjectBox}{\usebox\hvObjectBox}% @@ -1632,11 +1652,11 @@ \def\do@hvFloat@doubleFULLPAGE@CaptionOther#1{% \afterpage{% - \hfuzz=\maxdimen + \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip-\parskip+1.5\lineskip}% -0.5\paperheight+0.5\ht\hvObjectBox + \hspace*{\the\dimexpr-\evensidemargin-\parindent-1in}% \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}% \thispagestyle{empty}% - \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip+2\lineskip}% -0.5\paperheight+0.5\ht\hvObjectBox - \hspace*{\the\dimexpr-\evensidemargin-\parindent-1in}% + \hfuzz=\maxdimen \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}% \clipbox*{0 \depth{} \hv@leftPageObjectWidth{} \height}{\usebox\hvObjectBox}% \ifx\hv@floatType\hv@figure @@ -1649,7 +1669,7 @@ \if@twocolumn\newpage\if@firstcolumn\else\null\newpage\fi\fi \global\savebox{\hvObjectBox}{\ifhv@useOBox\usebox{\hvOBox}\else\hv@floatObject\fi}% \thispagestyle{empty}% - \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip+2\lineskip}% -0.5\paperheight+0.5\ht\hvObjectBox + \vspace*{\the\dimexpr-1in-\voffset-\topmargin-\headheight-\headsep-\baselineskip-\parskip+1.5\lineskip}% -0.5\paperheight+0.5\ht\hvObjectBox \hspace*{\hv@tempWidthA}% \clipbox*{\hv@leftPageObjectWidth{} \dp\hvObjectBox{} \wd\hvObjectBox{} \ht\hvObjectBox}{\usebox\hvObjectBox}% \ifx\hv@floatType\hv@figure -- cgit v1.2.3