From: "Peter Münster" <pmlists@free.fr>
Subject: Re: multiple backgrounds
Date: Mon, 16 Jan 2006 20:13:57 +0100 (CET) [thread overview]
Message-ID: <Pine.LNX.4.58.0601161934280.4913@gaston.free.fr> (raw)
In-Reply-To: <8C3CE40E-A082-4582-B666-A11EB7675437@fiee.net>
On Sun, 15 Jan 2006, Henning Hraban Ramm wrote:
> Now I must only find a way to *subtract* a layer, but I guess I can
> manage that with some "doifmode"s
Hello TeX-experts,
I tried to do the layer-subtraction, but it seems that I need more
experience with expansion in TeX. Here is the error:
! Undefined control sequence.
\GetList #1,#2;->\edef \ListHead
And here my test file:
\def\GetList#1,#2;{\edef\ListHead{#1}\edef\ListTail{#2}}
\def\Remove#1#2{\doRemove{#1}{#2,\relax}}
\def\doRemove#1#2{\expandafter\GetList#2;%
\doifelse{\ListHead}{#1}{}{\ListHead,}%
\doifelse{\ListTail}{\relax}{}{\doRemove{#1}{\ListTail}}%
}
\def\addBGbefore#1{\expandparameters
\setupbackgrounds[page][background={#1,\currentvalue}]}
\def\addBGafter#1{\expandparameters
\setupbackgrounds[page][background={\currentvalue,#1}]}
\def\removeBG#1{\expandparameters
\setupbackgrounds[page][background={\Remove{#1}{\currentvalue}}]}
\setupcolors[state=start]
\defineoverlay[layer1][{\color[red]{this is layer 1}}]
\defineoverlay[layer2][{\rotate[rotation=30]{\color[blue]{this is layer 2}}}]
\defineoverlay[layer3][{\rotate[rotation=60]{\color[green]{this is layer 3}}}]
\starttext
\addBGafter{layer1}
\input tufte
\page
\addBGafter{layer2}
\input tufte
\page
\addBGbefore{layer3}
\input tufte
\page
\removeBG{layer2}
\Values
\input tufte
\page
\removeBG{layer1}
\input tufte
\stoptext
Cheers, Peter
--
http://pmrb.free.fr/contact/
next prev parent reply other threads:[~2006-01-16 19:13 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-01-14 23:42 Henning Hraban Ramm
[not found] ` <6faad9f00601141623x70ae39a9m11a0854a9045f418@mail.gmail.com>
2006-01-15 0:37 ` Henning Hraban Ramm
2006-01-15 8:03 ` Peter Münster
2006-01-15 11:17 ` Henning Hraban Ramm
2006-01-16 19:13 ` Peter Münster [this message]
2006-01-16 19:51 ` Hans Hagen
2006-01-16 20:15 ` Hans Hagen
2006-01-15 17:54 ` Hans Hagen
2006-01-15 19:13 ` Henning Hraban Ramm
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=Pine.LNX.4.58.0601161934280.4913@gaston.free.fr \
--to=pmlists@free.fr \
--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).