%% %% This is file `ctable.sty', %% generated with the docstrip utility. %% %% The original source files were: %% %% ctable.dtx (with options: `package') %% %% This is a generated file. %% %% Copyright (C) 2005 by Wybo Dekker %% %% This file may be distributed and/or modified under the conditions of %% the LaTeX Project Public License, either version 1.2 of this license %% or (at your option) any later version. The latest version of this %% license is in: %% %% http://www.latex-project.org/lppl.txt %% %% and version 1.2 or later is part of all distributions of LaTeX version %% 1999/12/01 or later. %% \NeedsTeXFormat{LaTeX2e}[1999/12/01] \ProvidesPackage{ctable} [2009/09/17 v1.15 ctable package] \RequirePackage{color,xkeyval,array,tabularx,booktabs,rotating} \def\NN{\tabularnewline} \def\FL{\toprule} \def\ML{\NN\midrule} \def\LL{\NN\bottomrule} \def\@ctblfgcolor#1 #2 #3={\definecolor{@ctblframefg}{rgb}{#1,#2,#3}} \def\@ctblbgcolor#1 #2 #3={\definecolor{@ctblframebg}{rgb}{#1,#2,#3}} \def\@ctbltextsuperscript#1{\ifx\@ctblnosuper\empty\@textsuperscript{#1}\else{\footnotesize#1}\fi} \def\@ctbldoinside{\relax} \newdimen\@ctblframesep \newdimen\@ctblframerule \newdimen\@ctblwidth \newdimen\@ctblcaptionskip \newdimen\@ctblmaxwidth \newdimen\@ctblmincapwidth \newdimen\@ctblw % the final width \newdimen\@ctblfloatwidth \newdimen\@ctbloldsep \newdimen\@ctbloldrule \newbox\ctbl@t % tabular saved and measured here \define@key{ctbl}{caption}{\def\@ctblcaption{#1}} \define@key{ctbl}{cap}{\def\@ctblcap{#1}} \define@key{ctbl}{label}{\def\@ctbllabel{#1}} \define@key{ctbl}{continued}[(continued)]{\def\@ctblcontinued{#1}} \define@key{ctbl}{pos}{\def\@ctblpos{#1}\def\@ctblbegin{\@ctblbeg[#1]}} \define@key{ctbl}{width}{\@ctblwidth=#1} \define@key{ctbl}{maxwidth}{\@ctblmaxwidth=#1} \define@key{ctbl}{mincapwidth}{\@ctblmincapwidth=#1} \define@key{ctbl}{botcap}[]{\def\@ctblbotcap{1}} \define@key{ctbl}{sideways}[]{\def\@ctblsideways{sideways}} \define@key{ctbl}{rotate}[]{\def\@ctblsideways{sideways} \PackageWarning{ctable}{ using obsolete option 'rotate', use 'sideways' instead} } \define@key{ctbl}{figure}[]{\def\@ctbltaborfig{figure}} \define@key{ctbl}{center}[]{\let\@ctblalign\centering} \define@key{ctbl}{right}[]{\let\@ctblalign\raggedleft} \define@key{ctbl}{left}[]{\let\@ctblalign\raggedright} \define@key{ctbl}{star}[]{\def\@ctblstarred {*}} \define@key{ctbl}{framerule}{\@ctblframerule=#1} \define@key{ctbl}{framesep}{\@ctblframesep=#1} \define@key{ctbl}{framefg}{\@ctblfgcolor#1=} \define@key{ctbl}{framebg}{\@ctblbgcolor#1=} \define@key{ctbl}{captionskip}{\@ctblcaptionskip=#1} \define@key{ctbl}{nosuper}[]{\def\@ctblnosuper{1}} \define@key{ctbl}{notespar}[]{\def\@ctblnotespar{1}} \define@key{ctbl}{doinside}{\def\@ctbldoinside{#1}} \def\@ctblCaption{ \ifx\@ctblcap\undefined\let\@ctblcap\@ctblcaption\fi \ifx\@ctblcaption\empty\else \caption[\@ctblcap]{\ifx\@ctbllabel\empty\else\label{\@ctbllabel}\fi\@ctblcaption\ \@ctblcontinued\strut} \fi } \newcolumntype{Y}{X} \def\@ctblXcolumntype#1{% \let\NC@find@X\undefined \newcolumntype{X}{#1}% } \def\@ctblframe#1#2#3{% \@ctbloldsep\fboxsep\fboxsep\@ctblframesep% \@ctbloldrule\fboxrule\fboxrule\@ctblframerule% \fcolorbox{#1}{#2}{\fboxsep\@ctbloldsep\fboxrule\@ctbloldrule #3}% } \newcommand{\tnote}[2][a]{% \ifx\@ctblnotespar\empty% \hbox{\@ctbltextsuperscript{\normalfont\textit{#1}}}\NN \else% \@ctbltextsuperscript{\normalfont\textit{#1}}\,#2 \fi } \newcommand{\tmark}[1][a]{% \hbox{\textsuperscript{\normalfont\textit{#1}}}} \newcommand{\ctable}[4][]{% \def\@ctbltaborfig{table}% \let\@ctblalign\centering% \def\@ctblsideways{}% \def\@ctblcontinued{}% \def\@ctblpos {}% \def\@ctblcaption {}% \let\@ctblcap\undefined% \def\@ctbllabel {}% \def\@ctblbeg {\begin{\@ctblsideways\@ctbltaborfig\@ctblstarred}}% \def\@ctblbegin {\@ctblbeg}% \def\@ctblend {\end{\@ctblsideways\@ctbltaborfig\@ctblstarred}}% \def\@ctblbotcap {}% \def\@ctblstarred {}% \def\@ctblnosuper{} \def\@ctblnotespar{}% \definecolor{@ctblframefg}{rgb}{0,0,0}% \definecolor{@ctblframebg}{rgb}{1,1,1}% \@ctblframerule0pt \@ctblcaptionskip=0ex \@ctblframesep0pt \@ctblwidth=0pt \@ctblmaxwidth=0pt \@ctblmincapwidth=0pt \setkeys{ctbl}{#1}% \ifdim\@ctblwidth=0pt\else \ifdim\@ctblmaxwidth=0pt\else \PackageError{ctable}{ You may not use the width and maxwidth options together}{ Use either width or maxwidth} \fi \fi \ifx\@ctblpos\empty\else \ifx\@ctblsideways\empty\else \PackageError{ctable}{ You may not use the pos and sideways options together}{ Rotated tables and figures are always typeset on a separate page} \fi \fi \ifx\@ctblcaption\empty \ifx\@ctbllabel\empty\else \PackageError{ctable}{ You may not label a captionless table}{ Such a label can't be referenced} \fi \fi \sbox\ctbl@t{% \@ctblXcolumntype{l}% temporarily make type X = l \@ctblframe{@ctblframefg}{@ctblframebg}{% \@ctbldoinside \begin{tabular}{#2} #4% \end{tabular}% }% }% \newif\if@ctblusex\@ctblusexfalse \ifdim\@ctblmaxwidth=0pt \ifdim\@ctblwidth=0pt \else \@ctblusextrue \fi \else \ifdim\wd\ctbl@t>\@ctblmaxwidth \@ctblusextrue \fi \fi \if@ctblusex \sbox\ctbl@t{% \@ctblXcolumntype{Y}% restore X \@ctblframe{@ctblframefg}{@ctblframebg}{% \@ctbldoinside \begin{tabularx}{\ifdim\@ctblwidth>0pt\@ctblwidth\else\@ctblmaxwidth\fi}{#2} #4% \end{tabularx}% }% }% \fi \@ctblw=\wd\ctbl@t \@ctblfloatwidth=\ifdim\@ctblmincapwidth>\@ctblw \@ctblmincapwidth \else \@ctblw \fi \@ctblbegin \ifx\@ctblcontinued\empty\else\addtocounter{\@ctbltaborfig}{-1}\fi \@ctblalign \begin{minipage}{\@ctblfloatwidth}\parindent0pt \ifx\@ctblbotcap\empty\@ctblCaption\vskip\@ctblcaptionskip\fi \centering{\usebox\ctbl@t} % insert the tabular \def\@ctblfootnotes{#3}% \ifx#3\empty\else{% append footnotes, if any \footnotesize \ifx\@ctblnotespar\empty% \\ \begin{tabularx}{\hsize}{r@{\,}>{\raggedright}X} #3% \end{tabularx}% \else% \\[.2ex] \begin{minipage}{\hsize}\raggedright% #3% \end{minipage}% \fi } \fi \ifx\@ctblbotcap\empty\else\vskip\@ctblcaptionskip\@ctblCaption\fi \end{minipage} \@ctblend } \endinput %% %% End of file `ctable.sty'.