Difference between revisions of "Cover Pages"
Jump to navigation
Jump to search
(added title page example from Hans Hagen (mailinglist)) |
|||
Line 59: | Line 59: | ||
[http://archive.contextgarden.net/message/20050223.145512.19d6450f.html Reference to mailing list] | [http://archive.contextgarden.net/message/20050223.145512.19d6450f.html Reference to mailing list] | ||
+ | |||
+ | == Another title page == | ||
+ | |||
+ | <texcode> | ||
+ | \definetype[ytyp][color=yellow] | ||
+ | |||
+ | \startbuffer[title] | ||
+ | \type{/(}\ytyp{h}\type{*?)testexpr/io}\par | ||
+ | \type{/t(}\ytyp{a}\type{*?)estexpr/io}\par | ||
+ | \type{/te(}\ytyp{n}\type{*?)stexpr/io}\par | ||
+ | \type{/tes(}\ytyp{s}\type{*?)texpr/io}\par | ||
+ | \type{/test(}\ytyp{h}\type{*?)expr/io}\par | ||
+ | \type{/teste(}\ytyp{a}\type{*?)xpr/io}\par | ||
+ | \type{/testex(}\ytyp{g}\type{*?)pr/io}\par | ||
+ | \type{/testexp(}\ytyp{e}\type{*?)r/io}\par | ||
+ | \type{/testexpr(}\ytyp{n}\type{*?)/io}\par | ||
+ | \stopbuffer | ||
+ | |||
+ | \setupcolors[state=start] | ||
+ | |||
+ | \definelayer | ||
+ | [TitleGraphic] | ||
+ | [width=\paperwidth, | ||
+ | height=\paperheight] | ||
+ | |||
+ | \setlayer | ||
+ | [TitleGraphic] | ||
+ | [preset=lefttop] | ||
+ | {\scale | ||
+ | [width=\paperwidth, | ||
+ | height=\paperheight] | ||
+ | {\framed | ||
+ | [frame=off, | ||
+ | offset=overlay, | ||
+ | background=color, | ||
+ | backgroundcolor=blue, | ||
+ | foregroundcolor=red, | ||
+ | align=normal] | ||
+ | % {\setuptyping[before=,after=]\typebuffer[title]}}} | ||
+ | {\getbuffer[title]}}} | ||
+ | |||
+ | \setupbackgrounds[page][background=TitleGraphic] | ||
+ | |||
+ | \starttext | ||
+ | |||
+ | \startstandardmakeup | ||
+ | |||
+ | \stopstandardmakeup | ||
+ | |||
+ | \stoptext | ||
+ | </texcode> | ||
+ | |||
+ | Guess who did this one :-) [http://archive.contextgarden.net/message/20050321.011152.0eb2d729.html Reference to mailing list] | ||
+ | |||
+ | <context> | ||
+ | \setuplayout[location=middle,scale=.2] | ||
+ | \definetype[ytyp][color=yellow] | ||
+ | |||
+ | \startbuffer[title] | ||
+ | \type{/(}\ytyp{h}\type{*?)testexpr/io}\par | ||
+ | \type{/t(}\ytyp{a}\type{*?)estexpr/io}\par | ||
+ | \type{/te(}\ytyp{n}\type{*?)stexpr/io}\par | ||
+ | \type{/tes(}\ytyp{s}\type{*?)texpr/io}\par | ||
+ | \type{/test(}\ytyp{h}\type{*?)expr/io}\par | ||
+ | \type{/teste(}\ytyp{a}\type{*?)xpr/io}\par | ||
+ | \type{/testex(}\ytyp{g}\type{*?)pr/io}\par | ||
+ | \type{/testexp(}\ytyp{e}\type{*?)r/io}\par | ||
+ | \type{/testexpr(}\ytyp{n}\type{*?)/io}\par | ||
+ | \stopbuffer | ||
+ | |||
+ | \setupcolors[state=start] | ||
+ | |||
+ | \definelayer | ||
+ | [TitleGraphic] | ||
+ | [width=\paperwidth, | ||
+ | height=\paperheight] | ||
+ | |||
+ | \setlayer | ||
+ | [TitleGraphic] | ||
+ | [preset=lefttop] | ||
+ | {\scale | ||
+ | [width=\paperwidth, | ||
+ | height=\paperheight] | ||
+ | {\framed | ||
+ | [frame=off, | ||
+ | offset=overlay, | ||
+ | background=color, | ||
+ | backgroundcolor=blue, | ||
+ | foregroundcolor=red, | ||
+ | align=normal] | ||
+ | {\getbuffer[title]}}} | ||
+ | |||
+ | \setupbackgrounds[page][background=TitleGraphic] | ||
+ | |||
+ | \starttext | ||
+ | |||
+ | \startstandardmakeup | ||
+ | |||
+ | \stopstandardmakeup | ||
+ | |||
+ | \stoptext | ||
+ | </context> |
Revision as of 20:33, 30 March 2005
\setupcolors[state=start] \startuseMPgraphic{cover} StartPage ; fill Page withcolor .5green ; path p ; p := unitcircle randomized .1 xsized(PaperWidth-1cm) ; fill p shifted -center p shifted center Page withcolor red ; StopPage ; \stopuseMPgraphic \defineoverlay[cover][\useMPgraphic{cover}] \starttext \setupbackgrounds[page][background=cover] \startstandardmakeup \raggedcenter \vfill \definedfont[SerifBold at 48pt]\setstrut \strut Penguins in Vietnam \blank[2*big] \definedfont[SerifBold at 24pt]\setstrut \strut A Very Short Story \vfill \stopstandardmakeup \setupbackgrounds[page][background=] \input tufte \stoptext
Another title page
\definetype[ytyp][color=yellow] \startbuffer[title] \type{/(}\ytyp{h}\type{*?)testexpr/io}\par \type{/t(}\ytyp{a}\type{*?)estexpr/io}\par \type{/te(}\ytyp{n}\type{*?)stexpr/io}\par \type{/tes(}\ytyp{s}\type{*?)texpr/io}\par \type{/test(}\ytyp{h}\type{*?)expr/io}\par \type{/teste(}\ytyp{a}\type{*?)xpr/io}\par \type{/testex(}\ytyp{g}\type{*?)pr/io}\par \type{/testexp(}\ytyp{e}\type{*?)r/io}\par \type{/testexpr(}\ytyp{n}\type{*?)/io}\par \stopbuffer \setupcolors[state=start] \definelayer [TitleGraphic] [width=\paperwidth, height=\paperheight] \setlayer [TitleGraphic] [preset=lefttop] {\scale [width=\paperwidth, height=\paperheight] {\framed [frame=off, offset=overlay, background=color, backgroundcolor=blue, foregroundcolor=red, align=normal] % {\setuptyping[before=,after=]\typebuffer[title]}}} {\getbuffer[title]}}} \setupbackgrounds[page][background=TitleGraphic] \starttext \startstandardmakeup \stopstandardmakeup \stoptext
Guess who did this one :-) Reference to mailing list