[xsl] forth and back

Subject: [xsl] forth and back
From: Tobias Reif <tobiasreif@xxxxxxxxx>
Date: Sat, 21 Apr 2001 12:38:15 -0700 (PDT)

I'm experimenting with XSLT and SVG:
(those are working)

Now I want to generate different colors for the
levels; forth and back in an array of colors. The
level can be set to any depth, and I don't want to
just go from blue to yellow for a result with 2 levels
as well as one with 10 levels; I'd rather have the
colors go from blue to yellow to blue to yellow and so
forth for the depth set in the input-doc ("up and
(the opacity of the levels goes one way from low to
high for any depth; this works.)

The result should look something like this:

I tried to write two recursing templates:
the first is called "forth"; red and blue are
icremented, and green is decremented.
The second one works the otherway round.
One should start the other as soon as one of the
values reached the limlit of either 0 or 255.
Both should stop as soon as the set level of depth is

The current, crashing attempt is here:
the input is

Any ideas?


Tobias Reif

Do You Yahoo!?
Yahoo! Auctions - buy the things you want at great prices

 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list

Current Thread