[texhax] Memoir Class and \newcommad in tabular argument

Lars Madsen daleif at imf.au.dk
Sun Nov 18 14:00:13 CET 2007


Swami Pallasena :

> With memoir class option, in tabular environment,
> \begin{tabular}c @{\hspace{3pt}} c}
> works fine giving 3pt intercolumn space.
> But if I abbreviate @{\hspace{3pt}} using
> \newcommand{\HS}{@{\hspace{3pt}}}
> and use
> \begin{tabular}{c \HK c}
> it does not compile and gives the  followingerror message:
> Class memoir Error -- Illegal pream-token {\HS}:  `c' used.
>
> This problem does not occur in `article class', where everything
> works fine.  So, how can I make the above `\renewcommad'
> work inside Tabular when using Memoir Class?
> _______________________________________________
> TeX FAQ: http://www.tex.ac.uk/faq
> Mailing list archives: http://tug.org/pipermail/texhax/
> More links: http://tug.org/begin.html
>
> Automated subscription management: http://tug.org/mailman/listinfo/texhax
> Human mailing list managers: postmaster at tug.org
>

do it as a \newcolumntype instead

\newcoloumntype{H}{@{\hspace{3pt}}}

then

\begin{tabular}{c H c}

works fine

/daleif


More information about the texhax mailing list