summaryrefslogtreecommitdiff
path: root/tex/context/modules/mkiv
diff options
context:
space:
mode:
Diffstat (limited to 'tex/context/modules/mkiv')
-rw-r--r--tex/context/modules/mkiv/s-pre-60.mkiv212
-rw-r--r--tex/context/modules/mkiv/s-pre-69.mkiv336
-rw-r--r--tex/context/modules/mkiv/s-pre-70.mkiv176
-rw-r--r--tex/context/modules/mkiv/s-pre-71.lua63
-rw-r--r--tex/context/modules/mkiv/s-pre-71.mkiv170
5 files changed, 0 insertions, 957 deletions
diff --git a/tex/context/modules/mkiv/s-pre-60.mkiv b/tex/context/modules/mkiv/s-pre-60.mkiv
deleted file mode 100644
index 70f8978b0..000000000
--- a/tex/context/modules/mkiv/s-pre-60.mkiv
+++ /dev/null
@@ -1,212 +0,0 @@
-%D \module
-%D [ file=s-pre-60,
-%D version=2004.03.15,
-%D title=\CONTEXT\ Style File,
-%D subtitle=Presentation Environment 60,
-%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.
-
-% use lua instead of global mess
-
-\unprotect
-
-\startmode[paper,print]
- \let\StartSteps\relax
- \let\StopSteps \relax
- \let\FlushStep \relax
- \let\ResetStep \relax
- \let\StartBusy \relax
- \let\StopBusy \relax
- \endinput
-\stopmode
-
-\newcount\c_module_pre_steps_current
-\newcount\c_module_pre_steps_maximum
-\newcount\c_module_pre_steps_nesting_step
-\newcount\c_module_pre_steps_nesting_steps
-\newcount\c_module_pre_steps_nesting_busy
-
-\def\StepCounter {\the\c_module_pre_steps_current}
-\def\StepMaximum {\the\c_module_pre_steps_maximum}
-\def\StepLayer {step:\the\c_module_pre_steps_current}
-\def\NextStepLayer {step:\the\numexpr\c_module_pre_steps_current+\plusone\relax}
-\def\FirstStepLayer{step:1}
-
-\useJSscripts[stp]
-
-\startsetups[set-stepper]
-
- \ifnum\getvariable{stepper}{nofsteps}>\c_module_pre_steps_maximum
-
- \dostepwiserecurse {\numexpr\c_module_pre_steps_maximum+\plusone\relax} {\getvariable{stepper}{nofsteps}} {1} {
- \doifnotmode{nosteps,nostep} {
- \expanded{\defineviewerlayer[step:\recurselevel][state=stop,scope=global]}
- }
- }
-
- \global\c_module_pre_steps_maximum\getvariable{stepper}{nofsteps}\relax
-
- \fi
-
-\stopsetups
-
-\setvariables
- [stepper]
- [set=\setups{set-stepper},
- nofsteps=50]
-
-\defineviewerlayer[step:busy][state=start]
-
-\definereference [SetupStepper] [JS(SetupStepper{step,\StepMaximum})]
-\definereference [ResetStepper] [JS(ResetStepper)]
-\definereference [CheckStepper] [JS(CheckStepper{\StepCounter})]
-\definereference [InvokeStepper] [JS(InvokeStepper)]
-
-% todo: roll back blank
-
-\unexpanded\def\ResetStep
- {\iftrialtypesetting\else
- \global\c_module_pre_steps_current\zerocount
- \fi}
-
-\unexpanded\def\NextStep
- {\iftrialtypesetting\else
- \global\advance\c_module_pre_steps_current\plusone
- \fi}
-
-\unexpanded\def\PrevStep
- {\iftrialtypesetting\else
- \global\advance\c_module_pre_steps_current\minusone
- \fi}
-
-\unexpanded\def\FlushStep
- {\iftrialtypesetting\else
- \StopStep
- \NextStep
- \StartStep
- \fi}
-
-\unexpanded\def\StartStep
- {\iftrialtypesetting\else
- \global\advance\c_module_pre_steps_nesting_step\plusone
- \ifcase\c_module_pre_steps_nesting_step\or
- \startviewerlayer[\StepLayer]%
- \fi
- \fi
- \ignorespaces}
-
-\unexpanded\def\StopStep
- {\removeunwantedspaces
- \iftrialtypesetting\else
- \ifcase\c_module_pre_steps_nesting_step\or
- \stopviewerlayer
- \fi
- \global\advance\c_module_pre_steps_nesting_step\minusone
- \fi}
-
-\unexpanded\def\StartSteps
- {\iftrialtypesetting\else
- \global\advance\c_module_pre_steps_nesting_steps\plusone
- \ifcase\c_module_pre_steps_nesting_steps\or
- \ResetStep
- \NextStep
- \StartStep
- \fi
- \fi}
-
-\unexpanded\def\StopSteps
- {\iftrialtypesetting\else
- \ifcase\c_module_pre_steps_nesting_steps\or
- \StopStep
- \PrevStep
- \fi
- \global\advance\c_module_pre_steps_nesting_steps\minusone
- \fi}
-
-\unexpanded\def\StartBusy
- {\iftrialtypesetting\else
- \global\advance\c_module_pre_steps_nesting_busy\plusone
- \ifcase\c_module_pre_steps_nesting_busy\or
- \startviewerlayer[step:busy]
- \fi
- \fi
- \ignorespaces}
-
-\unexpanded\def\StopBusy
- {\removeunwantedspaces
- \iftrialtypesetting\else
- \ifcase\c_module_pre_steps_nesting_busy\or
- \stopviewerlayer
- \fi
- \global\advance\c_module_pre_steps_nesting_busy\minusone
- \fi}
-
-%D Handy:
-
-\unexpanded\def\StartLocalSteps
- {\ResetStep}
-
-\unexpanded\def\StopLocalSteps
- {}
-
-\unexpanded\def\StartLocalStep
- {\NextStep
- \StartStep}
-
-\unexpanded\def\StopLocalStep
- {\StopStep}
-
-\appendtoks
- \ResetStep
-\to \everyaftershipout
-
-\setupinteraction
- [%openaction=SetupStepper,
- closeaction=ResetStepper,
- openpageaction=CheckStepper,
- closepageaction=ResetStepper]
-
-\defineoverlay[invoke][\overlaybutton{InvokeStepper}]
-
-\setupbackgrounds
- [text]
- [background=invoke]
-
-% bonus
-
-\useMPlibrary[nav]
-
-\definepalet
- [navplus]
- [attach=interactioncolor,
- comment=interactioncolor]
-
-\setupcomment
- [symbol={comment-normal,comment-down},
- textlayer=\StepLayer,
- option=buffer,
- height=\textheight,
- width=\textwidth,
- margin=0pt]
-
-\setupattachments
- [symbol={attach-normal,attach-down},
- textlayer=\StepLayer]
-
-%D used as (given some definitions):
-%D
-%D \starttyping
-%D \StartLocalSteps
-%D \startcombination[both]
-%D {\StartLocalStep\placestreamlayer[left]\StopLocalStep} {}
-%D {\StartLocalStep\placestreamlayer[right]\StopLocalStep} {}
-%D \stopcombination
-%D \StopLocalSteps
-%D \stoptyping
-
-\protect \endinput
diff --git a/tex/context/modules/mkiv/s-pre-69.mkiv b/tex/context/modules/mkiv/s-pre-69.mkiv
deleted file mode 100644
index cc6af9ad3..000000000
--- a/tex/context/modules/mkiv/s-pre-69.mkiv
+++ /dev/null
@@ -1,336 +0,0 @@
-%D \module
-%D [ file=s-pre-69,
-%D version=2010.04.28,
-%D title=\CONTEXT\ Style File,
-%D subtitle=Presentation Environment 69,
-%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.
-
-\setuppapersize[S6][S6]
-\setuppapersize[SM][SM]
-
-\usemodule
- [abr-01,pre-60]
-
-\setupinteraction
- [state=start,
- contrastcolor=white,
- color=white,
- click=no]
-
-\setuplayout
- [location=middle,
- topspace=60pt,
- bottomspace=80pt,
- backspace=80pt,
- header=0pt,
- footer=0pt,
- width=middle,
- height=middle]
-
-\setupcolors
- [textcolor=white]
-
-\setupbodyfont[euler]
-
-\definecolor[maincolor] [blue]
-\definecolor[extracolor][green]
-
-% \definecolor[maincolor] [red]
-% \definecolor[extracolor][blue]
-
-\startMPinitializations
- if unknown MyColor[1] :
- color MyColor[] ;
- MyColor[1] := transparent(1,.25,\MPcolor{maincolor}) ;
- MyColor[2] := transparent(1,.25,\MPcolor{extracolor}) ;
-
- picture MySoFar ; MySoFar := nullpicture ;
- path MyLastOne ; MyLastOne := origin -- cycle ;
- color MyPageColor ; MyPageColor := MyColor[1] ;
- path MyLeftSteps, MyRightSteps ;
- boolean MyPageDone ; MyPageDone := false ;
-
- vardef MySmallShape(expr parent) =
- path p ; p := boundingbox parent ;
- p := boundingbox parent ;
- numeric w, h ; w := bbwidth(p) ; h := bbheight(p) ;
- urcorner p shifted (-uniformdeviate w/4,0) --
- lrcorner p shifted (0,uniformdeviate h/4) --
- llcorner p shifted (uniformdeviate w/4,0) --
- ulcorner p shifted (0,-uniformdeviate h/4) -- cycle
- enddef ;
-
- vardef MyShape(expr parent) =
- path p ; p := boundingbox parent ;
- if MyPageDone :
- MyPageDone := false ;
- urcorner p shifted (-EmWidth + -uniformdeviate CutSpace/2,0) --
- lrcorner p shifted (0,EmWidth + uniformdeviate BottomSpace/2) --
- llcorner p shifted (EmWidth + uniformdeviate BackSpace/2,0) --
- ulcorner p shifted (0,-EmWidth + -uniformdeviate TopSpace/2) -- cycle
- else :
- MyPageDone := true ;
- urcorner p shifted (0,-EmWidth + -uniformdeviate TopSpace/2) --
- lrcorner p shifted (-EmWidth + -uniformdeviate CutSpace/2,0) --
- llcorner p shifted (0,EmWidth + uniformdeviate BottomSpace/2) --
- ulcorner p shifted (EmWidth + uniformdeviate BackSpace/2,0) -- cycle
- fi
- enddef ;
-
- vardef MyMakeOne =
- MyLastOne := MyShape(Page) ;
- enddef ;
-
- vardef MyAddOne =
- addto MySoFar also image(fill MyLastOne withcolor MyPageColor ; ) ;
- enddef ;
-
- vardef MyDrawOne =
- fill MyLastOne withcolor black ;
- fill MyLastOne withcolor MyPageColor ;
- enddef ;
-
- vardef MyDrawPage =
- draw MySoFar ;
- enddef ;
-
- vardef MySetSteps =
- path l, r ; numeric s ; path ll[], rr[] ; path t ;
- l := point 2 of MyLastOne -- point 3 of MyLastOne ;
- r := point 0 of MyLastOne -- point 1 of MyLastOne ;
- t := topboundary Field[Text][Text] rightenlarged TextWidth leftenlarged TextWidth ;
- s := bbheight(Field[Text][Text])/LineHeight + 2 ;
- t := t shifted (0,-TopSkip) ;
- for i=1 upto s :
- ll[i] := t intersectionpoint l ;
- rr[i] := t intersectionpoint r ;
- t := t shifted (0,-LineHeight) ;
- endfor ;
- MyLeftSteps := for i=1 upto s : ll[i] -- endfor cycle ;
- MyRightSteps := for i=1 upto s : rr[i] -- endfor cycle ;
- enddef ;
-
- vardef MyDrawText(expr txt) =
- pair a ; a := (point 1 of MyLastOne) - (point 2 of MyLastOne) ;
- picture p ; p := txt ;
- p := p
- shifted (-EmWidth,EmWidth)
- shifted ulcorner txt
- shifted point 1 of MyLastOne ;
- p := p rotatedaround(lrcorner p, radian * tan(ypart a/xpart a)) ;
- setbounds p to origin -- cycle ;
- draw p ;
- enddef ;
-
- vardef MyDrawTitle(expr txt) =
- % pair a ; a := (point 2 of MyLastOne) - (point 3 of MyLastOne) ;
- pair a ; a := (point 3 of MyLastOne) - (point 4 of MyLastOne) ;
- picture p ;
- if bbheight(txt) > bbwidth(txt) :
- p := txt ysized(0.8*TextHeight) ;
- else :
- p := txt xsized(0.8*TextWidth) ;
- fi ;
- numeric d ; d := arclength(point 2 of MyLastOne -- point 3 of MyLastOne) - bbheight(p) ;
- p := p
- shifted (BackSpace,-d/2)
- shifted -ulcorner p
- shifted point 3 of MyLastOne ;
- % p := p rotatedaround(ulcorner p, - radian * tan(xpart a/ypart a)) ;
- % p := p rotatedaround(ulcorner p, radian * tan(ypart a/xpart a)) ;
- setbounds p to origin -- cycle ;
- draw p ;
- enddef ;
-
- vardef MyDrawSteps =
- s := bbheight(Field[Text][Text])/LineHeight + 2 ;
- for i=1 upto s :
- draw ll[i] withpen pencircle scaled 1mm ;
- draw rr[i] withpen pencircle scaled 1mm ;
- draw ll[i] -- rr[i] ;
- endfor ;
- draw Field[Text][Text] ;
- enddef ;
-
- fi ;
-\stopMPinitializations
-
-\startuseMPgraphic{initialization}
- StartPage ;
- MySoFar := image(fill Page enlarged 12pt withcolor MyPageColor) ;
- MyMakeOne ;
- MySetSteps ;
- StopPage ;
-\stopuseMPgraphic
-
-\appendtoks
- \startnointerference
- \useMPgraphic{initialization}
- \stopnointerference
-\to \everystarttext
-
-\startuseMPgraphic{page}
- StartPage ;
- MyDrawPage ;
- MyDrawOne ;
- MySetSteps ;
- MyDrawTitle(textext("\getvariable{document}{title}")) ;
- MyDrawText(textext("\getvariable{document}{topic}")) ;
- %
- % we have multiple runs when we have text
- %
-% MyDrawSteps ;
-% MyMakeOne ;
-% MySetSteps ;
- StopPage ;
-\stopuseMPgraphic
-
-\appendtoks
- \startnointerference
- \startMPcode
- MyAddOne ;
- MyMakeOne ;
- MySetSteps ;
- \stopMPcode
- \stopnointerference
-\to \everyshipout
-
-\defineoverlay[page][\useMPgraphic{page}]
-
-\startuseMPgraphic{symbol}
- color cc ; cc := MyColor[2] ;
- path p ; p := MySmallShape(unitsquare scaled (.6*LineHeight)) ;
- fill p withcolor white ;
- fill p withcolor cc ;
-\stopuseMPgraphic
-
-\definesymbol[mysymbol][\struttedbox{\useMPgraphic{symbol}}]
-
-\setupitemgroup[itemize][1][symbol=mysymbol]
-
-\setupbackgrounds
- [page]
- [background=page]
-
-\startluacode
- local texdimen = tex.dimen
- function document.SetParShape()
- local leftpath = metapost.getclippath("metafun","metafun","clip currentpicture to MyLeftSteps ;")
- local rightpath = metapost.getclippath("metafun","metafun","clip currentpicture to MyRightSteps ;")
- local shape = { }
- for i=1,#leftpath do
- local left = leftpath[i].x_coord
- local right = rightpath[i].x_coord
- local hsize = right - left - (texdimen.backspace + texdimen.cutspace)*number.dimenfactors.bp
- shape[#shape+1] = string.format("%sbp %sbp",left,hsize)
- end
- -- print(table.serialize(shape))
- -- context.parshape(string.format("%s %s ",#shape,table.concat(shape," ")))
- context("\\parshape %s %s ",#shape,table.concat(shape," "))
- end
-\stopluacode
-
-\nopenalties \dontcomplain
-
-\setupwhitespace[none]
-
-\def\StartText#1#2%
- {\starttext
- \setvariable{document}{title}{\framed[frame=off,offset=0pt,align=flushleft,foregroundstyle=\tfd\setupinterlinespace]{\begstrut#1\endstrut}}
- \setvariable{document}{topic}{\tfb#2}
- \startstandardmakeup
- % dummy page
- \stopstandardmakeup
- \setvariable{document}{title}{}
- \setvariable{document}{topic}{}}
-
-\def\StopText
- {\stoptext}
-
-\def\StartItems#1%
- {\setvariable{document}{topic}{\tfb#1}
- \startstandardmakeup[top=,bottom=\vss]
- \startelement[items][title={#1}]%
- \ctxlua{document.SetParShape()}
- \StartSteps}
-
-\def\StopItems
- {\StopSteps
- \stopelement
- \stopstandardmakeup}
-
-\def\StartItem
- {\dontleavehmode
- \startelement[item]%
- \llap{\symbol[mysymbol]\quad}% graphic
- \ignorespaces}
-
-\def\StopItem
- {\removeunwantedspaces
- \nobreak
- \crlf
- \stopelement
- \crlf
- \FlushStep}
-
-\def\ShapeParagraph
- {\ctxlua{document.SetParShape()}}
-
-% no parshape yet
-
-\def\StartParagraphs#1%
- {\setvariable{document}{topic}{\tfb#1}
- \startstandardmakeup[top=,bottom=\vss]
- %\ctxlua{document.SetParShape()}
- \startelement[paragraphs]%
- \StartSteps}
-
-\def\StopParagraphs
- {\StopSteps
- \stopelement
- \stopstandardmakeup}
-
-\def\StartParagraph
- {\startelement[paragraph]}
-
-\def\StopParagraph
- {\par
- \stopelement
- \FlushStep}
-
-% experiment .. likely to change
-
-\setelementexporttag[items] [nature][display]
-\setelementexporttag[item] [nature][mixed]
-\setelementexporttag[paragraphs][nature][display]
-\setelementexporttag[paragraph] [nature][mixed]
-
-\continueifinputfile{s-pre-69.mkiv}
-
-% finetuning: \StartText{\TEX\ and Reality\vskip2exClashing Mindsets?\vskip1ex}{Bacho\TEX, May 1, 2010}
-
-\StartText{Just\\A Demo}{Bacho\TEX, May 1, 2010}
-
-\StartItems{Quote from Tufte and Ward}
- \StartItem
- \input tufte
- \StopItem
- \StartItem
- \input ward
- \StopItem
-\StopItems
-
-% \dorecurse{20}{
-% \ctxlua{document.SetParShape()}
-% \input tufte
-% \page
-% }
-
-\StopText
-
diff --git a/tex/context/modules/mkiv/s-pre-70.mkiv b/tex/context/modules/mkiv/s-pre-70.mkiv
deleted file mode 100644
index 2c8bb2d26..000000000
--- a/tex/context/modules/mkiv/s-pre-70.mkiv
+++ /dev/null
@@ -1,176 +0,0 @@
-%D \module
-%D [ file=s-pre-70,
-%D version=2008.04.15,
-%D title=\CONTEXT\ Style File,
-%D subtitle=Presentation Environment 70,
-%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.
-
-%D At the cost of more runtime and a larger output file, we
-%D turn on randomization. The instances are cached in the
-%D MkIV cache, so successive runs use the same shapes.
-
-% \usemodule[punk] \usetypescript[punk] \setupbodyfont[punk,20pt]
-%
-% \EnableRandomPunk
-
-\setupbodyfont[punknova,20pt] % we now use the opentype variant
-
-%D We use the regular screen size paper and layout setup.
-
-\setuppapersize
- [S6][S6]
-
-\setuplayout
- [topspace=30pt,
- backspace=30pt,
- width=middle,
- height=fit,
- header=0pt,
- footer=0pt,
- bottomdistance=24pt,
- bottom=30pt,
- bottom=18pt,
- top=0pt]
-
-\setupinterlinespace
- [top=height,
- line=1.25\bodyfontsize]
-
-\setupcolors
- [state=start,
- textcolor=white]
-
-\setupinteraction
- [state=start,
- %click=off,
- menu=on]
-
-%D We predefine a few palets. Of course you can define more.
-
-\definecolor[punkblue] [r=.4,b=.8,g=.4]
-\definecolor[punkgreen] [r=.4,b=.4,g=.8]
-\definecolor[punkred] [r=.8,b=.4,g=.4]
-\definecolor[punkyellow][r=.6,g=.6,b=.2]
-
-\definepalet [punk-one] [textcolor=punkblue,pagecolor=punkgreen]
-\definepalet [punk-two] [textcolor=punkred,pagecolor=punkyellow]
-\definepalet [punk-three] [textcolor=punkblue,pagecolor=punkyellow]
-\definepalet [punk-one-reverse] [textcolor=punkgreen,pagecolor=punkblue]
-\definepalet [punk-two-reverse] [textcolor=punkyellow,pagecolor=punkred]
-\definepalet [punk-three-reverse] [textcolor=punkyellow,pagecolor=punkblue]
-
-\setuppalet[punk-one]
-
-%D We use a few backgrounds. The hyperlink that invokes the
-%D stepper is hooked into the text background.
-
-\definelayer
- [page]
- [width=\paperwidth,
- height=\paperheight]
-
-\setupbackgrounds
- [page]
- [background={color,page},
- backgroundcolor=pagecolor,
- setups=pagestuff]
-
-\setupbackgrounds
- [text]
- [background={color,invoke},
- backgroundoffset=12pt,
- backgroundcolor=textcolor]
-
-%D We need different symbols for itemized lists.
-
-\definesymbol[1][\hbox{\lower1ex\hbox{*}}]
-\definesymbol[2][\endash]
-\definesymbol[3][\letterhash]
-\definesymbol[3][>]
-
-%D We don't want these reversed clicked areas in Acrobat.
-
-\setupinteraction
- [click=no,
- color=white, % pagecolor,
- contrastcolor=white] % pagecolor,
-
-%D We define a rather simple navigational panel at the
-%D bottom
-
-\setupinteractionmenu
- [bottom]
- [color=white, % pagecolor,
- contrastcolor=white, % pagecolor,
- background=color,
- backgroundcolor=textcolor,
- frame=off,
- height=24pt,
- left=\hfill,
- middle=\hskip12pt]
-
-\setupsubpagenumber
- [state=start]
-
-\startinteractionmenu[bottom]
- \starttxt
- \interactionbar
- [alternative=d,
- symbol=yes,
- color=white,
- contrastcolor=textcolor]
- \stoptxt
- \hfilll
- \startbut [previouspage] < < < \stopbut
- \startbut [nextpage] > > > \stopbut
-\stopinteractionmenu
-
-%D Instead of the normal symbols we use more punky ones.
-
-\startsymbolset [punk]
- \definesymbol[previous] [\string<\string<]
- \definesymbol[somewhere] [\string^\string^]
- \definesymbol[next] [\string>\string>]
-\stopsymbolset
-
-\setupinteraction[symbolset=punk]
-
-%D Because the font is rather large, we use less whitespace.
-
-\setuphead
- [chapter]
- [after={\blank[big]}]
-
-%D Run this file with the command: \type {context --mode=demo s-pre-70}
-%D in order to get an example.
-
-\continueifinputfile{s-pre-70.mkiv}
-
-\usemodule[pre-60] % use the stepper
-
-\starttext
-
-\title {Punk for dummies}
-
-\dorecurse{10} {
-
- \title{Just a few dummy pages}
-
- \StartSteps
- \startitemize[packed]
- \startitem bla \FlushStep \stopitem
- \startitem bla bla \FlushStep \stopitem
- \startitem bla bla bla \FlushStep \stopitem
- \startitem bla bla bla bla \FlushStep \stopitem
- \stopitemize
- \StopSteps
-
-}
-
-\stoptext
diff --git a/tex/context/modules/mkiv/s-pre-71.lua b/tex/context/modules/mkiv/s-pre-71.lua
deleted file mode 100644
index bfa45a705..000000000
--- a/tex/context/modules/mkiv/s-pre-71.lua
+++ /dev/null
@@ -1,63 +0,0 @@
-if not modules then modules = { } end modules ['steps'] = {
- version = 1.001,
- comment = "companion to steps.mkiv",
- author = "Hans Hagen, PRAGMA-ADE, Hasselt NL",
- copyright = "PRAGMA ADE / ConTeXt Development Team",
- license = "see context related readme files"
-}
-
-moduledata.steps = moduledata.steps or { }
-local steps = moduledata.steps
-
-local locations = {
- 'lefttop',
- 'middletop',
- 'righttop',
- 'middleleft',
- 'middle',
- 'middleright',
- 'leftbottom',
- 'middlebottom',
- 'rightbottom',
-}
-
-local done, current, previous, n
-
-function steps.reset_locations()
- done, current, previous, n = table.tohash(locations,false), 0, 0, 0
-end
-
-function steps.next_location(loc)
- previous = current
- n = n + 1
- loc = loc and loc ~= "" and tonumber(loc)
- while true do
- current = loc or math.random(1,#locations)
- if not done[current] then
- done[current] = true
- break
- end
- end
-end
-
-function steps.current_location()
- context(locations[current] or "")
-end
-
-function steps.previous_location()
- context(locations[previous] or "")
-end
-
-function steps.current_n()
- context(current)
-end
-
-function steps.previous_n()
- context(previous)
-end
-
-function steps.step()
- context(n)
-end
-
-steps.reset_locations()
diff --git a/tex/context/modules/mkiv/s-pre-71.mkiv b/tex/context/modules/mkiv/s-pre-71.mkiv
deleted file mode 100644
index 38dae61df..000000000
--- a/tex/context/modules/mkiv/s-pre-71.mkiv
+++ /dev/null
@@ -1,170 +0,0 @@
-% engine=luatex
-
-%D \module
-%D [ file=s-pre-71,
-%D version=2008.08.05,
-%D title=\CONTEXT\ Style File,
-%D subtitle=Presentation Environment 71,
-%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.
-
-%D I might improve this module so consider it experimental.
-
-% \enablemode[numbers]
-% \enablemode[paper]
-
-\usemodule[pre-60,abr-02]
-
-\registerctxluafile{s-pre-71}{}
-
-\setupinteraction[state=start,click=off]
-
-\definepapersize[wide][width=900pt,height=600pt]
-
-\setuppapersize[wide][wide]
-
-\setuplayout[page]
-
-% \setupbodyfont[15pt]
-
-\usetypescriptfile[type-hgz]
-\usetypescript[palatino-informal]
-\setupbodyfont[palatino-informal,15pt]
-
-\setupsorting[logo][style=]
-
-\startnotmode[paper]
- \setupbackgrounds[page][background=color,backgroundcolor=black]
-\stopnotmode
-
-\TransparencyHack
-
-\definelayer[page][width=\paperwidth,height=\paperheight]
-
-\definecolor[TopicColor-1][r=.3,g=.4,b=.5]
-\definecolor[TopicColor-2][r=.3,g=.5,b=.4]
-\definecolor[TopicColor-3][r=.4,g=.3,b=.5]
-\definecolor[TopicColor-4][r=.4,g=.5,b=.3]
-\definecolor[TopicColor-5][r=.5,g=.3,b=.4]
-\definecolor[TopicColor-6][r=.5,g=.4,b=.3]
-\definecolor[TopicColor-7][r=.35,g=.35,b=.6]
-\definecolor[TopicColor-8][r=.6,g=.35,b=.35]
-\definecolor[TopicColor-9][r=.35,g=.6,b=.35]
-
-\definecolor[TopicColor-0][t=.5,a=1,s=.5]
-\definecolor[TopicColor] [s=1]
-
-\setupcolors[state=start]
-\setupcolors[textcolor=TopicColor]
-
-\def\StartTopics
- {\startstandardmakeup
- \ctxlua{moduledata.steps.reset_locations()}
- \doifnotmode{paper}{\StartLocalSteps}}
-
-\def\StopTopics
- {\doifnotmode{paper}{\StopLocalSteps}
- \flushlayer[page]
- \stopstandardmakeup}
-
-\def\StartTopic
- {\dosingleempty\doStartTopic}
-
-\def\doStartTopic[#1]%
- {\doifnotmode{paper}{\NextStep}
- \ctxlua{moduledata.steps.next_location("#1")}
- \startnotmode[paper]
- \doifnothing{#1}
- {\ifcase\ctxlua{moduledata.steps.previous_n()}\else
- \setlayer
- [page]
- [preset=\ctxlua{moduledata.steps.previous_location()}]
- \bgroup
- \doifnotmode{paper}{\startviewerlayer[\StepLayer]}%
- \framed
- [offset=20pt,
- strut=no,
- align=normal,
- frame=off,
- height=\dimexpr\paperheight/3\relax,
- width=\dimexpr\paperwidth/3\relax,
- background=color,
- backgroundcolor=TopicColor-0]
- {}%
- \doifnotmode{paper}{\stopviewerlayer}%
- \egroup
- \fi}
- \stopnotmode
- \setlayer
- [page]
- [preset=\ctxlua{moduledata.steps.current_location()}]
- \bgroup
- \doifnotmode{paper}{\startviewerlayer[\StepLayer]}%
- \framed
- [offset=20pt,
- strut=no,
- align=\expdoifelse{#1}{}{normal}{middle,lohi},
- align=\expdoifelse{#1}{}{flushleft,verytolerant}{middle,lohi},
- frame=off,
- height=\dimexpr\paperheight/3\relax,
- width=\dimexpr\paperwidth/3\relax,
- background=color,
- backgroundcolor=TopicColor-\ctxlua{moduledata.steps.current_n()}]
- \bgroup
- \ignorespaces}
-
-\def\StopTopic
- {\removeunwantedspaces
- \egroup
- \doifnotmode{paper}{\stopviewerlayer}%
- \egroup
- \startmode[numbers]
- \setlayerframed
- [page]
- [preset=\ctxlua{moduledata.steps.current_location()}]
- [height=\dimexpr\paperheight/3\relax,
- width=\dimexpr\paperwidth/3\relax,
- frame=off,
- foregroundstyle=\bfa,
- align={flushright,low}]
- {\doifnotmode{paper}{\startviewerlayer[\StepLayer]}%
- \ctxlua{moduledata.steps.step()}\kern\strutdepth
- \doifnotmode{paper}{\stopviewerlayer}}
- \stopmode}
-
-\logo [METAPOST] {MetaPost}
-
-\definefont[TitleFont][SansBold at 60pt]
-\definefont[TempFont] [SansBold at 12pt]
-
-\let\StartText\starttext
-\let\StopText \stoptext
-
-\continueifinputfile{s-pre-71.mkiv}
-
-\starttext
-
-\StartTopics
- \StartTopic[1] A \StopTopic
- \StartTopic[5] B \StopTopic
- \StartTopic[9] C \StopTopic
-\StopTopics
-
-\StartTopics
- \StartTopic A \StopTopic
- \StartTopic B \StopTopic
- \StartTopic C \StopTopic
- \StartTopic D \StopTopic
- \StartTopic E \StopTopic
- \StartTopic F \StopTopic
- \StartTopic G \StopTopic
- \StartTopic H \StopTopic
- \StartTopic I \StopTopic
-\StopTopics
-
-\stoptext