diff options
author | Hans Hagen <pragma@wxs.nl> | 2016-11-04 12:01:00 +0100 |
---|---|---|
committer | Context Git Mirror Bot <phg42.2a@gmail.com> | 2016-11-04 12:01:00 +0100 |
commit | 2ad220abb483dea0ba0d85d9963095f5c7dfdfa1 (patch) | |
tree | f2bdb02c48bf671d1e57da3d759c602231ac9a22 /tex/context/modules/mkii | |
parent | 5a501d72ddc9ab9003746aa46fad3a12046e20ec (diff) | |
download | context-2ad220abb483dea0ba0d85d9963095f5c7dfdfa1.tar.gz |
2016-11-04 11:12:00
Diffstat (limited to 'tex/context/modules/mkii')
-rw-r--r-- | tex/context/modules/mkii/s-pre-63.mkii | 73 | ||||
-rw-r--r-- | tex/context/modules/mkii/s-pre-64.mkii | 208 | ||||
-rw-r--r-- | tex/context/modules/mkii/s-pre-68.mkii | 152 |
3 files changed, 433 insertions, 0 deletions
diff --git a/tex/context/modules/mkii/s-pre-63.mkii b/tex/context/modules/mkii/s-pre-63.mkii new file mode 100644 index 000000000..9ecb2cb1a --- /dev/null +++ b/tex/context/modules/mkii/s-pre-63.mkii @@ -0,0 +1,73 @@ +%D \module +%D [ file=s-pre-63, +%D version=2006.05.11, +%D title=\CONTEXT\ Style File, +%D subtitle=Presentation Environment 63, +%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. + +\usemodule[pre-61,streams] + +\definemeasure[textgap] [\dimexpr24pt\relax] + +\definemeasure[leftwidth] [\dimexpr.25\textwidth-.5\measure{textgap}\relax] +\definemeasure[rightwidth][\dimexpr.75\textwidth-.5\measure{textgap}\relax] + +\definestreamlayer[left] [width=\measure{leftwidth}] +\definestreamlayer[right][width=\measure{rightwidth}] + +\setupbodyfont[12pt] + +\definefont[LeftFont][Normal sa 3] + +\setupheader[style=\tfc,before=\vss,after=\vss] + +\startsetups streamlayer:left:settings + \hsize\measure{leftwidth} + \LeftFont + \setupinterlinespace +\stopsetups + +\startsetups streamlayer:right:settings + \hsize\measure{rightwidth} +\stopsetups + +\definecombination[both][distance=\measure{textgap},location=top] + +\startsetups place:both + \startcombination[both] + {\StartLocalStep\placestreamlayer[left]\StopLocalStep} {} + {\StartLocalStep\placestreamlayer[right]\StopLocalStep} {} + \stopcombination +\stopsetups + +\def\StartPage {\page \StartLocalSteps} +\def\StopPage {\StopLocalSteps \page} + +\def\StartLeft {\startstreamlayer[left]} +\def\StartRight{\startstreamlayer[right]} + +\def\StopLeft {\stopstreamlayer} +\def\StopRight {\stopstreamlayer} + +\def\StartPair {} +\def\StopPair {\setups[place:both]} + +\doifnotmode {demo} {\endinput} + +\setupbodyfont[8pt] \definefont[BigFont][Normal sa 4] + +\starttext + +\StartPage + \StartPair \StartLeft ZAPF \StopLeft \StartRight \input zapf \StopRight \StopPair + \StartPair \StartLeft DAVIS \StopLeft \StartRight \input davis \StopRight \StopPair + \StartPair \StartLeft WARD \StopLeft \StartRight \input ward \StopRight \StopPair +\StopPage + +\stoptext diff --git a/tex/context/modules/mkii/s-pre-64.mkii b/tex/context/modules/mkii/s-pre-64.mkii new file mode 100644 index 000000000..ef4889bbb --- /dev/null +++ b/tex/context/modules/mkii/s-pre-64.mkii @@ -0,0 +1,208 @@ +%D \module +%D [ file=s-pre-64, +%D version=2006.05.11, +%D title=\CONTEXT\ Style File, +%D subtitle=Presentation Environment 64, +%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. + +% To be documented, used in 2007 + +\usemodule[s][pre-60] + +\newcounter\shapesynctag +\newdimen\slantedshapedimen +\newdimen\slantedshapestep +\newdimen\slantedshapeleftskip +\newdimen\slantedshapeoffset +\newdimen\slantedshapeextra + +\positioningtrue + +\def\AdaptShape + {\doglobal\increment\shapesynctag + \getnoflines\textheight + \slantedshapestep\dimexpr\slantedshapeleftskip/\noflines\relax + \leftskip\slantedshapeleftskip + \scratchdimen\dimexpr\MPy{text:\MPp\shapesynctag}+\MPh{text:\MPp\shapesynctag}-\topskip-\MPy\shapesynctag\relax + \advance\scratchdimen\slantedshapeextra + \getnoflines\scratchdimen + \slantedshapedimen \noflines \slantedshapestep + \scratchtoks\emptytoks + \dorecurse{30} + {\appendetoks + \the\dimexpr-\slantedshapedimen+\slantedshapeoffset \relax\space + \the\dimexpr \hsize-2\slantedshapeoffset\relax\space + \to\scratchtoks + \advance\slantedshapedimen \slantedshapestep}% + \parshape 30 \the\scratchtoks + \strut\xypos\shapesynctag} + +\def\AdaptShapeX + {\doglobal\increment\shapesynctag + \getnoflines\textheight + \slantedshapestep\dimexpr\slantedshapeleftskip/\noflines\relax + \leftskip\slantedshapeleftskip + \scratchdimen\dimexpr\MPy{text:\MPp\shapesynctag}+\MPh{text:\MPp\shapesynctag}-\topskip-\MPy\shapesynctag\relax + \advance\scratchdimen\slantedshapeextra + \getnoflines\scratchdimen + \slantedshapedimen \noflines \slantedshapestep + \scratchtoks\emptytoks + \dorecurse{30} + {\appendetoks + \the\dimexpr-\slantedshapedimen+\slantedshapeoffset +5cm \relax\space + \the\dimexpr \hsize-2\slantedshapeoffset\relax\space + \to\scratchtoks + \advance\slantedshapedimen \slantedshapestep}% + \parshape 30 \the\scratchtoks + \strut\xypos\shapesynctag} + +\setuppapersize[S6][S6] + +\setupinteraction + [state=start, + click=no] + +\setupinteractionscreen + [option=max] + +\setuplayout + [backspace=12pt, + topspace=24pt, + height=middle, + width=middle, + header=0pt, + footer=0pt] + +\definecolor[maincolor][b=.5] +\definecolor[somecolor][g=.5] +\definecolor[morecolor][r=.5] + +\setupcolors + [textcolor=maincolor, + state=start] + +\setupbackgrounds + [text]% [text] + [background={base,text,invoke}] + +\definelayer + [text] + [width=\textwidth, + height=\textheight] + +\definelayer + [base] + [width=\textwidth, + height=\textheight] + +\definetype [epet] [style=,color=morecolor] +\setuptype [style=,color=somecolor] + +\slantedshapeleftskip150pt +\slantedshapeoffset12pt +\slantedshapeextra10pt + +\startreusableMPgraphic{page} + StartPage ; + fill Page withcolor \MPcolor{maincolor} ; + path p ; p := Field[Text][Text] enlarged 6pt ; + p := + llcorner p shifted (0,-12pt) -- + lrcorner p shifted (-150pt,0) -- + urcorner p shifted (0,12pt) -- + ulcorner p shifted (150pt,0) -- + cycle ; + fill p + withcolor .9white ; + StopPage ; +\stopreusableMPgraphic + +\defineoverlay[page][\reuseMPgraphic{page}] +\setupbackgrounds[page][background=page] + +\setupalign[flushleft] + +\def\StartItem + {\blank[line] + \begingroup + \EveryPar {\AdaptShape}} % beware: \ABBREV aan begin gaat fout + +\def\StopItem + {\endgraf + \endgroup + \blank[line]} + +\def\StartType + {\blank[halfline] + \begingroup + \EveryPar {\AdaptShape} + \dontleavehmode \quad} + +\def\StopType + {\endgraf + \endgroup + \blank[halfline]} + +\def\Title#1% + {\page + \setlayer + [text] + [preset=lefttop, + rotation=90] + {\color[white]{\scale[height=24pt]{\strut#1}}}} + +\def\SetBanner#1% + {\setuplayer[base][state=repeat] + \setlayer[base][preset=rightbottom]{\color[white]{\scale[height=9pt]{\strut#1}}}} + +\let\TitleFont\relax + +\startmode[atpragma] + \definefontfeature[default][method=node,script=latn,language=dflt,liga=yes,onum=yes,kern=yes] + \definefont[TitleFont][palatinosanscom-bold*default at 48pt] + \definefont[MainTextFont][palatinosanscom-regular*default at 12pt] \setupinterlinespace[line=15pt] + \appendtoks + \MainTextFont % hack, as we define a bodyfont at that point (better have a proper typeface) + \to \everystarttext +\stopmode + +\doifnotmode{demo}{\endinput} + +\starttext + +\usemodule[abr-01] + +\SetBanner{tug 2007 san diego} + +\Title {hans hagen} + +\startstandardmakeup \TitleFont \setupinterlinespace[line=3ex] \vfill + +\StartItem \dontleavehmode \quad {\morecolor zapfino, a} \StopItem +\StartItem \dontleavehmode \quad {\morecolor torture test} \StopItem +\StartItem \dontleavehmode \quad {\morecolor for luatex} \StopItem + +\vfill \stopstandardmakeup + +\Title{loading fonts} + +\StartSteps + +\StartItem the \OPENTYPE\ font reader is borrowed from \FONTFORGE\ \FlushStep \StopItem +\StartItem once it was ready, we could look into such a font \FlushStep \StopItem +\StartItem it tooks while to figure out the format due to rather fuzzy specs \FlushStep \StopItem +\StartItem it took us even more time to find out that the loader was flawed \FlushStep \StopItem +\StartItem one reason was that fonts themselves may have bugs or be incomplete \FlushStep \StopItem +\StartItem then we changed to \FONTFORGE\ version 2 \FlushStep \StopItem +\StartItem this made the missing pieces surface in more complex feature handling \FlushStep \StopItem +\StartItem while implementing features the new table format was cleaned up \FlushStep \StopItem + +\StopSteps + +\stoptext diff --git a/tex/context/modules/mkii/s-pre-68.mkii b/tex/context/modules/mkii/s-pre-68.mkii new file mode 100644 index 000000000..c22640efd --- /dev/null +++ b/tex/context/modules/mkii/s-pre-68.mkii @@ -0,0 +1,152 @@ +%D \module +%D [ file=s-pre-68, +%D version=2009.08.28, +%D title=\CONTEXT\ Style File, +%D subtitle=Presentation Environment 68, +%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. + +\usemodule[pre-60,abr-02] + +% style + +\setuppapersize + [S66][S66] + +\setuplayout + [height=middle, + width=middle, + header=0pt, + footer=0pt, + backspace=2cm, + topspace=2cm] + +\setupinteraction + [state=start, + click=no] + +\definecolor[maincolor][r=.4] + +\startreusableMPgraphic{page} + StartPage ; + fill Page enlarged 5mm withcolor \MPcolor{maincolor} ; + StopPage ; +\stopreusableMPgraphic + +\startreusableMPgraphic{next} + fill ultriangle scaled .15PaperWidth withcolor white ; +\stopreusableMPgraphic + +\startreusableMPgraphic{last} + fill boundingbox(ultriangle scaled .15PaperWidth) withcolor white ; +\stopreusableMPgraphic + +\startuniqueMPgraphic{bullit} + fill ultriangle scaled 2ExHeight withcolor white ; +\stopuniqueMPgraphic + +\definelayer + [extra] + [width=\paperwidth, + height=\paperheight] + +\defineoverlay + [page] + [\reuseMPgraphic{page}] + +\setupbackgrounds + [page] + [background={page,extra}] + +\setupcolors + [state=start, + textcolor=white] + +\setuphead + [chapter] + [style=\bfc] + +\definehead[Title][title] + +\definesymbol[MyBullet][\uniqueMPgraphic{bullit}] + +\setupitemgroup[itemize][each][symbol=MyBullet] + +\startmode[asintended] + \usetypescript[cambria] + \setupbodyfont[cambria,14.4pt] +\stopmode + +% interface + +\def\StartItems + {\begingroup + \StartSteps + \startitemize + \def\StartItems{\startitemize\def\StopItems{\stopitemize}}} + +\def\StopItems + {\FlushStep + \stopitemize + \NextPageSymbol + \StopSteps + \endgroup} + +\def\Item + {\def\Item{\FlushStep\item} + \item} + +\def\NextPageSymbol + {\setlayer + [extra] + [preset=rightbottom,offset=2mm] + {\ifnum\realpageno=\lastpage + \reuseMPgraphic{last}% + \else\ifnum\realpageno>1 + \reuseMPgraphic{next}% + \fi\fi + \FlushStep}} + +\def\TitlePage#1#2% + {\startstandardmakeup[bottom=,top=] + \scale[width=\textwidth]{\framed[align=flushleft,foregroundstyle=\bf,frame=off]{#1}} + \vfilll + \hfill\scale[width=.5\textwidth]{\framed[align=flushright,foregroundstyle=\bf,frame=off]{#2}} + \stopstandardmakeup} + +\doifnotmode{demo}{\endinput} + +\starttext + +\TitlePage{I'm running\\out of examples}{Hans Hagen\\Someplace, 2031} + +\Title{Alpha} + +\StartItems +\Item one +\Item two +\Item three +\StopItems + +\Title{Beta} + +\StartItems +\Item four +\Item five +\Item six +\StopItems + +\Title{Gamma} + +\StartItems +\Item seven +\Item eight +\Item nine +\StopItems + +\stoptext |