At 05:21 PM 6/4/2002 +0900, Matthew Huggett wrote:
>Hi:
>
>I have a document with line-numbering. When I use one of my own commands---
>for example, \Red{Some Words in Red}--- the line-numbering stops working.
>The line-numbering works fine without these homemade commands. Any ideas as
>to why this might be?
This is a limitation of tex: one cannot disassemble boxes with marks (which
we used to keep track of colors.
So, the solution is: \setupcolors[state=local] which is ok as long as color
does not cross pages.
A better way is (in cont-new.tex):
\newevery \everyshapebox \relax
\def\beginofshapebox%
{\setbox\oldshapebox\normalvbox
\bgroup
\reshapingboxtrue
\the\everyshapebox
\normalhbox to \shapesignal{\strut\hss}%
\prevdepth\dp\strutbox}
\appendtoks \localcolortrue \to \everyshapebox
Now, the latest version has a problem with spacing (introduced when
extending the number placement), in cont-new there should be (only in
latest version!):
\def\dodoschrijfregelnummer%
{% beware of em's, the font is already switched !
\setbox\scratchbox\hbox
{\setbox0\hbox{\@@rncommando{\regelweergave}}\vsmashbox0%
\ifcase\linenumberlocation
\rlap{\hbox to \@@rnbreedte{\box0\hss}}% was \llap, nog testen !!
\or
%\llap{\hbox to \@@rnbreedte{\hss\box0\hskip\linkermargeafstand}}%
\inleftmargin
{\forgetall
\doifelse\@@rnbreedte\v!marge
{\hsize\linkermargebreedte}{\hsize\@@rnbreedte}%
\alignedline\@@rnuitlijnen\v!rechts{\box0\hskip\@@rnafstand}}%
\else
\inrightmargin
{\forgetall
\doifelse\@@rnbreedte\v!marge
{\hsize\rechtermargebreedte}{\hsize\@@rnbreedte}%
\alignedline\@@rnuitlijnen\v!links{\hskip\@@rnafstand\box0}}%
\fi}%
\vsmashbox\scratchbox
\box\scratchbox}
Hans
-------------------------------------------------------------------------
Hans Hagen | PRAGMA ADE | [EMAIL PROTECTED]
Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
information: http://www.pragma-ade.com/roadmap.pdf
documentation: http://www.pragma-ade.com/showcase.pdf
-------------------------------------------------------------------------