From: Hans Hagen <pragma@wxs.nl>
Subject: Re: Weird godown, dorecurse, colors and page-fitting interaction
Date: Tue, 06 Dec 2005 11:00:51 +0100 [thread overview]
Message-ID: <43956153.6070808@wxs.nl> (raw)
In-Reply-To: <43948DBB.8050505@comp.lancs.ac.uk>
Adam Lindsay wrote:
> Hi all,
>
> What's happening here?
>
> \setupcolors[state=start]
> \starttext
> \startTEXpage
> \dorecurse{2}{abc\godown[0pt]}
> \stopTEXpage
> \startTEXpage
> \startcolor[yellow]
> \dorecurse{2}{abc\godown[0pt]}
> \stopcolor
> \stopTEXpage
> \stoptext
>
a long story ... to which ttp wizzard taco might want to add comment
ok, a fix first (missing \fi)
\def\godown[#1]%
{\relax
\ifhmode\endgraf\fi
\ifvmode\nointerlineskip\vskip#1\relax\fi}
what you observe is some interference; the fitting page macros use
framed and when you set width and height to fit, it will use the
reshaperr to determine the width; this mechanism fails as soon as nodes
show up that cannot be \un-whatevered or \last-whatevered; also, some
mechanisms have as side effect that they force the box to have a width
of \hsize
question for taco: how difficult would it be to have something:
\squeezebox\scratchbox
where the result is a box with a width equal to the max(natural width of
lines)
(that way we could replace the reshaper and get around those interfering
and blocking nodes)
you may see some of the side effects when you play with:
\starttext
\setupcolors[state=start]
\startTEXpage
\dorecurse{2}{abc\godown[0pt]}
\stopTEXpage
\startTEXpage[foregroundcolor=yellow]
\dorecurse{2}{abc\godown[0pt]}
\stopTEXpage
\startTEXpage
\startcolor[red]\dorecurse{2}{abc\godown[0pt]}\stopcolor
\stopTEXpage
\startTEXpage[width=fixed]
\startcolor[green]\dorecurse{2}{abc\godown[0pt]}\stopcolor
\stopTEXpage
\startTEXpage[width=fixed]
\dorecurse{2}{\startcolor[cyan]abc\stopcolor\godown[0pt]}
\stopTEXpage
\startTEXpage
\dorecurse{2}{\startcolor[magenta]abc\stopcolor\godown[0pt]}
\stopTEXpage
\startTEXpage
\vbox{\startcolor[blue]\dorecurse{2}{abc\godown[0pt]}\stopcolor}
\stopTEXpage
\stoptext
so, there is no real solution unless you use the foreground color or box
things yourself
Hans
next prev parent reply other threads:[~2005-12-06 10:00 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-12-05 18:58 Adam Lindsay
2005-12-06 10:00 ` Hans Hagen [this message]
2005-12-06 10:06 ` Taco Hoekwater
2005-12-06 12:53 ` Adam Lindsay
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=43956153.6070808@wxs.nl \
--to=pragma@wxs.nl \
--cc=ntg-context@ntg.nl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).