Am 09.07.2012 um 04:47 schrieb Kip Warner:
Hey list,
On the cover page of my book I'd like just an image displayed and another image used as the background for every other page in the book. So I put this in my environment,
% Cover image... \definelayer [CoverImage] [x=0mm, y=0mm, \paperwidth, \paperheight] \setupbackgrounds[page][background=CoverImage]
\setlayer [CoverImage] % name of the layer {\externalfigure [Makeup/Images/Cover.jpg] [align=center, \paperwidth, \paperheight]} % the actual contents of the layer
% Regular background image... \definelayer [BackgroundImage] [x=0mm, y=0mm, \paperwidth, \paperheight, repeat=yes]
\setlayer [BackgroundImage] % name of the layer {\externalfigure [Makeup/Images/Background.png] [align=center, \paperwidth, \paperheight]} % the actual contents of the layer
, the following in the book's first page,
\setupbackgrounds[page][background=CoverImage]
, and the following on second page,
\setupbackgrounds[page][background=BackgroundImage]
. But this does not work properly. What ends up happening is the cover image is displayed correctly, but every page after that just has a blank white background.
\setupexternalfigures[directory=Makeup/Images] \defineoverlay [backgroundimage] [{\ifnum\rawcountervalue[userpage]=1\relax \overlayfigure{Cover}% \else \overlayfigure{Background}% \fi}] \setupbackgrounds[page][background=backgroundimage] \starttext \dorecurse{4}{\input knuth\page} \stoptext Wolfgang