From 8d8d528d2ad52599f11250cfc567fea4f37f2a8b Mon Sep 17 00:00:00 2001 From: Context Git Mirror Bot Date: Tue, 12 Jan 2016 17:15:07 +0100 Subject: 2016-01-12 16:26:00 --- tex/context/modules/common/s-cdr-01.tex | 145 ++++++++++++++++++++++++++++++++ 1 file changed, 145 insertions(+) create mode 100644 tex/context/modules/common/s-cdr-01.tex (limited to 'tex/context/modules/common/s-cdr-01.tex') diff --git a/tex/context/modules/common/s-cdr-01.tex b/tex/context/modules/common/s-cdr-01.tex new file mode 100644 index 000000000..b0bced9da --- /dev/null +++ b/tex/context/modules/common/s-cdr-01.tex @@ -0,0 +1,145 @@ +%D \module +%D [ file=s-cdr-01, +%D version=2001.2.07, % maybe earlier +%D title=\CONTEXT\ Style File, +%D subtitle=CDROM Cover, +%D author=Hans Hagen, +%D date=\currentdate, +%D copyright={PRAGMA ADE \& \CONTEXT\ Development Team}] +%C +%C This module is part of the \CONTEXT\ macro||package and is +%C therefore copyrighted by \PRAGMA. See mreadme.pdf for +%C details. + +\startmodule[cdr-01] + +\setupmodule[cdr-01][option=] + +\def\PDFMPformoffset{20cm} + +\definepapersize + [CDcover] + [width=12.5cm, + height=12.4cm] + +\definelayout + [CDcover] + [topspace=5mm, + backspace=5mm, + header=0pt, + footer=0pt, + width=middle, + height=middle] + +\setuparranging + [2SIDE] + +\setuppapersize + [CDcover] + [A4,landscape] + +\setuplayout + [CDcover] + +\setuplayout + [location=middle] + +\setupcolors + [state=start] + +\setupbackgrounds + [leftpage] + [background=leftcover] + +\setupbackgrounds + [rightpage] + [background=rightcover] + +\setuppagenumbering + [alternative=doublesided] + +\defineoverlay[leftcover] [\useMPgraphic{leftcover}] +\defineoverlay[rightcover][\useMPgraphic{rightcover}] + +\definecolor [cd-color] [s=0] +\definemeasure[cd-linewidth][.4pt] + +\doif {\moduleparameter{cdr-01}{option}} {light} { + \definecolor [cd-color] [s=.85] + \definemeasure[cd-linewidth][.2pt] +} + +\startuseMPgraphic{leftcover} + StartPage ; + pickup pencircle scaled \measure{cd-linewidth} ; + draw + bottomboundary Page & + rightboundary Page & + topboundary Page withcolor \MPcolor{cd-color} ; + draw + bottomboundary (Page enlarged 3mm) & + rightboundary (Page enlarged 3mm) & + topboundary (Page enlarged 3mm) dashed evenly withcolor \MPcolor{cd-color} ; + StopPage ; +\stopuseMPgraphic + +\startuseMPgraphic{rightcover} + StartPage ; + pickup pencircle scaled \measure{cd-linewidth} ; + draw + topboundary Page & + leftboundary Page & + bottomboundary Page withcolor \MPcolor{cd-color} ; + draw + topboundary (Page enlarged 3mm) & + leftboundary (Page enlarged 3mm) & + bottomboundary (Page enlarged 3mm) dashed evenly withcolor \MPcolor{cd-color} ; + draw + bottomboundary Page -- + lrcorner Page shifted (-5mm,-1cm) -- + llcorner Page shifted ( 5mm,-1cm) -- cycle withcolor \MPcolor{cd-color} ; + draw + topboundary Page -- + ulcorner Page shifted ( 5mm, 1cm) -- + urcorner Page shifted (-5mm, 1cm) -- cycle withcolor \MPcolor{cd-color} ; + StopPage ; + setbounds currentpicture to Page ; +\stopuseMPgraphic + +\setupmakeup + [standard] + [doublesided=no,page=] + +\setuplayout + [topspace=5mm, + backspace=5mm, + header=0pt, + footer=0pt, + width=middle, + height=middle] + +\defineframedtext + [maintext] + [background={foreground,color}, + backgroundcolor=a-bit-white, + frame=off, + before=, + after=, + align=right, + strut=no, + height=fit, + width=\textheight] + +\stopmodule + +\doifnotmode{demo}{\endinput} + +\starttext + \startstandardmakeup + page 1 + \stopstandardmakeup + + \startstandardmakeup + page 2 + \stopstandardmakeup +\stoptext -- cgit v1.2.3