Current File : //usr/share/texlive/texmf-dist/tex/latex/oberdiek/pdfcolparcolumns.sty |
%%
%% This is file `pdfcolparcolumns.sty',
%% generated with the docstrip utility.
%%
%% The original source files were:
%%
%% pdfcolparcolumns.dtx (with options: `package')
%%
%% This is a generated file.
%%
%% Project: pdfcolparcolumns
%% Version: 2019/12/29 v1.5
%%
%% Copyright (C)
%% 2007, 2008, 2010 Heiko Oberdiek
%% 2016-2019 Oberdiek Package Support Group
%%
%% This work may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either
%% version 1.3c of this license or (at your option) any later
%% version. This version of this license is in
%% https://www.latex-project.org/lppl/lppl-1-3c.txt
%% and the latest version of this license is in
%% https://www.latex-project.org/lppl.txt
%% and version 1.3 or later is part of all distributions of
%% LaTeX version 2005/12/01 or later.
%%
%% This work has the LPPL maintenance status "maintained".
%%
%% The Current Maintainers of this work are
%% Heiko Oberdiek and the Oberdiek Package Support Group
%% https://github.com/ho-tex/oberdiek/issues
%%
%%
%% This work consists of the main source file pdfcolparcolumns.dtx
%% and the derived files
%% pdfcolparcolumns.sty, pdfcolparcolumns.pdf, pdfcolparcolumns.ins,
%% pdfcolparcolumns.drv, pdfcolparcolumns-test1.tex.
%%
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{pdfcolparcolumns}%
[2019/12/29 v1.5 Color stacks for parcolumns (HO)]%
\DeclareOption*{%
\PassOptionsToPackage{\CurrentOption}{parcolumns}%
}
\ProcessOptions\relax
\RequirePackage{parcolumns}[2004/11/25]
\RequirePackage{pdfcol}[2007/09/09]
\ifpdfcolAvailable
\else
\PackageInfo{pdfcolparcolumns}{%
Loading aborted, because color stacks are not available%
}%
\expandafter\endinput
\fi
\RequirePackage{infwarerr}[2007/09/09]
\global\chardef\pcpc@MaxStack=\z@
\def\pcpc@InitStacks#1{%
\ifnum#1>\pcpc@MaxStack
\begingroup
\count@\pcpc@MaxStack
\loop
\advance\count@\@ne
\pdfcolInitStack{pcpc@\the\count@}%
\ifnum#1>\count@
\repeat
\global\chardef\pcpc@MaxStack=\count@
\endgroup
\fi
}
\def\pcpc@SwitchStack#1{%
\pdfcolSwitchStack{pcpc@\number#1}%
}
\def\pcpc@SetCurrent#1{%
\pdfcolSetCurrent{pcpc@\number#1}%
}
\g@addto@macro\pc@alloccolumns{%
\pcpc@InitStacks\pc@columncount
}
\g@addto@macro\pc@setcolumnwidth{%
\pcpc@SwitchStack\pc@columnctr
}
\begingroup
\def\x{%
\global\let\@tempa\relax
\count@\z@
\hb@xt@\linewidth{%
\vfuzz30ex %
\vbadness\@M
\splittopskip\z@skip
\loop
\ifnum\count@<\pc@columncount
\advance\count@\@ne
\expandafter\ifvoid\csname pc@column@\number\count@\endcsname
\hskip\csname pc@column@width@\number\count@\endcsname
\else
\expandafter\setbox\expandafter\@tempboxa\expandafter
\vsplit\csname pc@column@\number\count@\endcsname
to \dp\strutbox
\vbox{%
\unvbox\@tempboxa
}%
\fi
\expandafter\ifvoid\csname pc@column@\number\count@\endcsname
\else
\global\let\@tempa\pc@placeboxes
\fi
\ifnum\count@<\pc@columncount
\strut
\hfill
\ifpc@rulebetween
\vrule
\hfill
\fi
\fi
\repeat
}%
\@tempa
}%
\ifx\x\pc@placeboxes
\else
\@PackageWarningNoLine{pdfcolparcolumns}{%
Command \string\pc@placeboxes\space has changed.\MessageBreak
Supported versions of package `parcolumns':\MessageBreak
\space\space 2004/08/05.\MessageBreak
The redefinition of \string\pc@placeboxes\space may not%
\MessageBreak
behave correctly depending on the changes%
}%
\fi
\endgroup
\renewcommand*{\pc@placeboxes}{%
\global\let\@tempa\relax
\count@\z@
\hb@xt@\linewidth{%
\vfuzz30ex %
\vbadness\@M
\splittopskip\z@skip
\loop
\ifnum\count@<\pc@columncount
\advance\count@\@ne
\expandafter\ifvoid\csname pc@column@\number\count@\endcsname
\hskip\csname pc@column@width@\number\count@\endcsname
\else
\expandafter\setbox\expandafter\@tempboxa\expandafter
\vsplit\csname pc@column@\number\count@\endcsname
to \dp\strutbox
\vbox{%
\pcpc@SetCurrent\count@
\unvbox\@tempboxa
}%
\fi
\expandafter\ifvoid\csname pc@column@\number\count@\endcsname
\else
\global\let\@tempa\pc@placeboxes
\fi
\ifnum\count@<\pc@columncount
\strut
\hfill
\ifpc@rulebetween
\begingroup
\pcpc@RuleBetweenColor
\vrule
\endgroup
\hfill
\fi
\fi
\repeat
}%
\@tempa
}
\def\pcpc@RuleBetweenColorDefault{%
\normalcolor
}
\let\pcpc@RuleBetweenColor\pcpc@RuleBetweenColorDefault
\define@key{parcolumns}{rulebetweencolor}{%
\edef\pcpc@temp{#1}%
\ifx\pcpc@temp\@empty
\let\pcpc@RuleBetweenColor\pcpc@RuleBetweenColorDefault
\else
\edef\pcpc@temp{%
\noexpand\@ifnextchar[{%
\def\noexpand\pcpc@RuleBetweenColor{%
\noexpand\color\pcpc@temp
}%
\noexpand\pcpc@GobbleNil
}{%
\def\noexpand\pcpc@RuleBetweenColor{%
\noexpand\color{\pcpc@temp}%
}%
\noexpand\pcpc@GobbleNil
}%
\pcpc@temp\noexpand\@nil
}%
\pcpc@temp
\fi
}
\long\def\pcpc@GobbleNil#1\@nil{}
%% \section{Installation}
\endinput
%%
%% End of file `pdfcolparcolumns.sty'.