diff options
author | Karl Berry <karl@freefriends.org> | 2010-03-01 18:55:42 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2010-03-01 18:55:42 +0000 |
commit | 413d7f7e7a71e2fa7657b04c4807d5068b997120 (patch) | |
tree | c820e9ee2ef16be5b3b3150023a3661ad35fa6b3 /Master/texmf-dist/doc/latex/tabls/tabls.tex | |
parent | 925e1de18edf4c888f69c026e246e1921ee27ba4 (diff) |
tabls doc update (27feb10)
git-svn-id: svn://tug.org/texlive/trunk@17255 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/latex/tabls/tabls.tex')
-rw-r--r-- | Master/texmf-dist/doc/latex/tabls/tabls.tex | 83 |
1 files changed, 83 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/latex/tabls/tabls.tex b/Master/texmf-dist/doc/latex/tabls/tabls.tex new file mode 100644 index 00000000000..cf5f82e5caf --- /dev/null +++ b/Master/texmf-dist/doc/latex/tabls/tabls.tex @@ -0,0 +1,83 @@ +\documentclass[a4paper]{article} +\usepackage[a4paper]{geometry} +\usepackage{miscdoc} +\usepackage[scaled=0.85]{luximono} +\begin{document} +\title{The \textsf{tabls} package} +\author{Donald Arseneau\thanks{Documentation derived from the package + file by Robin Fairbairns}} +\maketitle +\begin{quote} + The package modifies \LaTeX{}'s \texttt{array} and \texttt{tabular} + environments to keep text from touching other text or hlines above + or below. +\end{quote} +\section{New parameters, etc.} + +The behaviour of the package is controlled by a small set of +parameters, which are all \TeX{} \cs{dimen} registers (and so may be +adjusted using \LaTeX{} \cs{setlength} commands. + +\paragraph{\cs{tablinesep} (or \cs{tablelineskip}):} the minimum space +between text on successive lines in a tabular environment. Negative +distances are treated as zero. The default value is \texttt{1pt}. A +value of \texttt{0pt} turns off checking for touching text. Text +given in an \verb|@{ }| specification (cf. the \textsf{array} package) +is never checked for overlap. + +\paragraph{\cs{arraylinesep} (or \cs{arraylineskip})}: like +\cs{tablinesep}, but for arrays. + +\paragraph{\cs{extrarulesep}:} extra space to add above and below each +\cs{hline} and \cs{cline}. There will be at least +\texttt{\cs{extrarulesep} + 0.5\cs{tablinesep}} between an \cs{hline} +and a line of text. Negative values can be used, but only until some +text touches the line. The default value is \texttt{3pt}. + +\noindent To ensure interline separations in tables but not arrays, +declare +\begin{quote} + \cs{setlength}\cmdinvoke{arraylinesep}{0pt} +\end{quote} +\noindent The appearance of normal \LaTeX{} tables can be had with +\begin{quote} + \cs{setlength}\cmdinvoke{tablinesep}{0pt}\\ + \cs{setlength}\cmdinvoke{arraylinesep}{0pt}\\ + \cs{setlength}\cmdinvoke{extrarulesep}{0pt} +\end{quote} +\noindent but it would be better to not use \textsf{tabls} in this +situation. + +The command \cmdinvoke{hline}[extra] has gained an optional length +argument (just like \bsbs), which gives the space to insert below the +line. This space is in addition to the \cs{extrarulesep} and +linesep. A negative value will reduce the space until the line +touches some text below, and will then have no further effect. For +example, \cmdinvoke{hline}[-9cm] draws a horizontal line while +suppressing all the extra spacing. + +(This \cs{hline} also fixes the notches that used to appear at the +junction between horizontal and vertical lines.) + +\section{How it works} + +There are no struts in the preamble entries\footnote{The comments in + the package say this is a lie\dots}, rather, there are tests to +measure the maximum height and depth of all entries on a line. The +maximum values start at the size of LaTeX's \cs{@arstrut} minus the +appropriate linesep. At the \bsbs, a strut is inserted (in its own +column) which is that maximum size plus the linesep plus any +additional space for separation from \cs{hline}s. + +\section{The Downside} + +Building a table will be slower than before because the entries have +to be boxed twice (by the package's \cs{@seesize} and by \cs{halign} +itself) instead of just once. +\cs{setlength}\cmdinvoke{tablinesep}{0pt} will recover most of this +speed, with \cs{extrarulesep} still partially in effect\,---\,extra +space will still be added around \cs{hline}s, but it may be taken up +by very tall or very deep table entries; thus text may still touch the +lines. Because of the speed penalty, if your computer is slow, it is +probably best to omit \textsf{tabls} until producing a final copy. +\end{document} |