summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/context/third/simpleslides
diff options
context:
space:
mode:
authorManuel Pégourié-Gonnard <mpg@elzevir.fr>2011-08-03 12:53:25 +0000
committerManuel Pégourié-Gonnard <mpg@elzevir.fr>2011-08-03 12:53:25 +0000
commit595c7ec7f9d471f058625dabe3241c425ea97a71 (patch)
tree478e358ac301d001fb3138e79ba5490294954e89 /Master/texmf-dist/tex/context/third/simpleslides
parent093571e26fb48ab0546f5fde706dd2eb1c5f1c64 (diff)
context-simpleslides update
git-svn-id: svn://tug.org/texlive/trunk@23370 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/context/third/simpleslides')
-rw-r--r--Master/texmf-dist/tex/context/third/simpleslides/simpleslides-f-default.tex5
-rw-r--r--Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-BigNumber.tex5
-rw-r--r--Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-BottomSquares.tex37
-rw-r--r--Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-Shaded.tex56
-rw-r--r--Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-SideToc.tex107
-rw-r--r--Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-Swoosh.tex229
-rw-r--r--Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-default.tex125
-rw-r--r--Master/texmf-dist/tex/context/third/simpleslides/t-simpleslides.tex4
8 files changed, 408 insertions, 160 deletions
diff --git a/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-f-default.tex b/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-f-default.tex
index bb368d8e91c..f2e595d0c96 100644
--- a/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-f-default.tex
+++ b/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-f-default.tex
@@ -62,6 +62,11 @@
\definebodyfont [14pt,15pt,16pt,17pt,20pt,25pt,\NormalSize,\TitleSize] [ss] [default]
\stoptypescript
+\starttypescript [mono] [default] [size]
+\definebodyfont [14pt,15pt,16pt,17pt,20pt,25pt,\NormalSize,\TitleSize] [tt] [default]
+\stoptypescript
+
+
\definebodyfontenvironment[\NormalSize]
\definebodyfontenvironment[\TitleSize]
diff --git a/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-BigNumber.tex b/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-BigNumber.tex
index dcf446a1e28..dba3f68458e 100644
--- a/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-BigNumber.tex
+++ b/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-BigNumber.tex
@@ -214,6 +214,11 @@ StopPage ;
\c!height=2.5cm,
\c!command=\doSlideTitle]
+\setupTitle
+ [\c!headcolor=simpleslides:textcolor,
+ \c!title\c!color=simpleslides:textcolor,
+ \c!date\c!color=simpleslides:textcolor,
+ \c!author\c!color=simpleslides:textcolor]
%D Squares are used as the first level of itemizations
diff --git a/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-BottomSquares.tex b/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-BottomSquares.tex
index 3f866ed6d68..ea7bcbeba64 100644
--- a/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-BottomSquares.tex
+++ b/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-BottomSquares.tex
@@ -115,7 +115,7 @@ StopPage ;
%D We want the title information to be colored
\setupTitle
- [\c!headcolor={simpleslides:contrastcolor}]
+ [color=simpleslides:contrastcolor]
%D The slide title is typeset in a layer
@@ -127,6 +127,41 @@ StopPage ;
\c!height=3cm,
\c!after=]
+%D attempt!
+
+\startuniqueMPgraphic{Important}
+save p, q ; path p[], q[] ;
+p[1] = unitsquare xyscaled (\overlaywidth,\overlayheight) ;
+z[1] = ulcorner p[1] ;
+z[2] = llcorner p[1] ;
+save a ; numeric a ;
+a = arclength (z[1] -- z[2])/15 ;
+z[3] = ulcorner p[1] shifted (a,0) ;
+z[4] = urcorner p[1] shifted (-a,0) ;
+z[5] = urcorner p[1] shifted (0,-a) ;
+z[6] = lrcorner p[1] shifted (0,a) ;
+z[7] = lrcorner p[1] shifted (-a,0) ;
+z[8] = llcorner p[1] shifted (a,0) ;
+z[9] = llcorner p[1] shifted (0,a) ;
+z[10] = ulcorner p[1] shifted (0,-a) ;
+z[11] = z[8] shifted (5mm,0) ;
+z[12] = z[5] shifted (0,-5mm) ;
+p[2] = z[3] --- z[4] .. z[5] --- z[6] .. z[7] --- z[8] .. z[9] --- z[10] .. cycle ;
+q[1] = z[11] --- z[7] .. z[6] --- z[12] ;
+for i = 3 upto 22:
+ pickup pencircle scaled (i*0.5mm) ;
+ draw q[1] withcolor transparent ("normal", 0.01, black) ;
+endfor
+pickup pencircle scaled 2pt ;
+fill p[2] withcolor \MPcolor{simpleslides:contrastcolor} ;
+%draw z[8] withcolor red ;
+\stopuniqueMPgraphic
+
+\defineoverlay[VImportant][\useMPgraphic{Important}]
+
+\define[1]\Important%
+ {\blank[line]\midaligned{{\framed[height=5cm,width=0.9\textwidth,frame=off,background=VImportant,align=middle,offset=0pt,top=\vss,bottom=\vss,strut=no,foregroundcolor=simpleslides:backgroundcolor]{#1}}}}
+
%D The symbol for the first level of itemizations.
\definesymbol[1][\useMPgraphic{simpleslides:itemize:square}]
diff --git a/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-Shaded.tex b/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-Shaded.tex
index 7da4ef5d847..25869b1e0d4 100644
--- a/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-Shaded.tex
+++ b/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-Shaded.tex
@@ -27,11 +27,11 @@
rightmargindistance=0pt,
height=fit,
header=0pt,
- footer=5pt,
+ footer=0pt,
topspace=.8cm,
backspace=1.5cm,
- bottomspace=.8cm,
- bottom=12pt,
+ bottomspace=1cm,
+ bottom=1cm,
location=singlesided]
%D These macros are used for placing figures/pictures:
@@ -43,7 +43,6 @@
%D This module has three color schemes, blue, green and bluered.
-
\startsetups simpleslides:setups:bluered
\definecolor [simpleslides:textcolor] [white]
\definecolor [simpleslides:interactioncolor] [b=.2]
@@ -78,18 +77,22 @@
\setupcolors[textcolor={simpleslides:textcolor}]
+\setupTitle[color=white]
%D This module shades the background in a gradient. We use \METAPOST\ to draw
%D the background.
-\startuniqueMPgraphic{simpleslides:MP:ornament}
-save p;
-path p ;
-p := unitsquare xscaled \overlaywidth yscaled \overlayheight ;
-linear_shade(p,6,
+
+\startuseMPgraphic{simpleslides:MP:ornament}
+StartPage ;
+linear_shade(Page, 6,
\MPcolor{simpleslides:backgroundcolor},
\MPcolor{simpleslides:variantcolor}) ;
-\stopuniqueMPgraphic
+if PageNumber >1:
+ \includeMPgraphic{\simpleslidescounter} ;
+fi
+StopPage ;
+\stopuseMPgraphic
%D We define these backgrounds as overlays:
@@ -105,21 +108,24 @@ linear_shade(p,6,
\definesymbol[1][\useMPgraphic{simpleslides:itemize:square}]
\setupitemize[1][color={simpleslides:itemize:color}]
-
-%D The \quotation{Shaded} style uses \CONTEXT's interactionbar:
-
-\setupsubpagenumber[way=bytext,state=start]
-
-\setupinteraction
- [page=yes,
- color=simpleslides:interactioncolor,
- contrastcolor=simpleslides:contrastcolor,
- menu=on,
- state=start]
-
-\startinteractionmenu[bottom]
-{\interactionbar[alternative=f,width=\makeupwidth,height=1ex]}
-\stopinteractionmenu
+
+% %D The \quotation{Shaded} style uses \CONTEXT's interactionbar:
+%
+% \setupsubpagenumber[way=bytext,state=start]
+%
+% \setupinteraction
+% [page=yes,
+% color=simpleslides:interactioncolor,
+% contrastcolor=simpleslides:contrastcolor,
+% menu=on,
+% state=start]
+%
+% %\setupinteractionbar
+% %\startinteractionmenu[bottom]
+% \setupbottomtexts[XXX{\interactionbar[state=start,alternative=e,width=8cm,height=0.2cm,step=small,frame=on]}YYY]
+% %\stopinteractionmenu
+
+%\setupbottomtexts[\useMPgraphic{shaded:counter}]
\protect
\stopmodule
diff --git a/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-SideToc.tex b/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-SideToc.tex
index 862d3fe5fa6..c835b8c8335 100644
--- a/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-SideToc.tex
+++ b/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-SideToc.tex
@@ -74,46 +74,6 @@
%D typeset in the left margin. It is inspired by something Hans did in
%D s-pre-19. The Difference is that I wanted the Topic to be independent from
%D SlideTitle macro. This way, several slides can be combined into one Topic.
-%D Here are the main macros for defining and typesetting this list.:
-
-\definelist[MyTopics][criterium=all]
-
-\def\MyMark{}
-
-\def\Topic%
- {\dosingleargument\doTopic}
-
-\def\doTopic[#1]{%
- \def\MyMark{#1}%
- \writetolist[MyTopics]{#1}{}%
-}
-
-\define[3]\FancyEntry
- {\doifelse{#1}{\MyMark} %
- {\framed[width=3.5cm,
- height=4ex,
- align=middle,
- frame=off,
- framecolor=red,
- background=color,
- backgroundcolor=simpleslides:altcontrastcolor,
- foregroundcolor=simpleslides:backgroundcolor]
- {\switchtobodyfont[14pt]#1}}% fancy layout
- {\framed[width=3.5cm,
- height=4ex,
- align=middle,
- frame=off,
- framecolor=red,
- foregroundcolor=simpleslides:backgroundcolor]
- {\switchtobodyfont[14pt]#1}}% normal layout
-}
-
-\setuplist[MyTopics]
- [pagenumber=no,
- alternative=command,
- command=\FancyEntry]
-
-\setuptexttexts[margin][\vbox{\placelist[MyTopics]}][]
% \definelayer
% [Topiclayer]
@@ -141,11 +101,78 @@
%D We define our color scheme
+\enablemode[\moduleparameter{simpleslides}{color}]
+
+\startmode[dark]
\definecolor [simpleslides:backgroundcolor] [s=.9]
\definecolor [simpleslides:altcontrastcolor] [b=.6]
\definecolor [simpleslides:contrastcolor] [s=.3]
\definecolor [simpleslides:itemize:color] [simpleslides:altcontrastcolor]
+\define[3]\FancyEntry
+ {\doifelse{#1}{\MyMark}%
+ {\framed[width=3.5cm,
+ height=4ex,
+ align=middle,
+ frame=off,
+ framecolor=red,
+ background=color,
+ backgroundcolor=simpleslides:altcontrastcolor,
+ foregroundcolor=simpleslides:backgroundcolor]
+ {\switchtobodyfont[13pt]#1}}% fancy layout
+ {\framed[width=3.5cm,
+ height=4ex,
+ align=middle,
+ frame=off,
+ framecolor=red,
+ foregroundcolor=simpleslides:backgroundcolor]
+ {\switchtobodyfont[13pt]#1}}% normal layout
+}
+\stopmode
+\startmode[light]
+\definecolor [simpleslides:altcontrastcolor] [r=1,g=0.5,b=0]
+\definecolor [simpleslides:contrastcolor] [s=0.95]
+\definecolor [simpleslides:textcolor] [s=0]
+\definecolor [simpleslides:itemize:color] [simpleslides:altcontrastcolor]
+\define[3]\FancyEntry
+ {\doifelse{#1}{\MyMark} %
+ {\framed[width=3.5cm,
+ height=4ex,
+ frame=off,
+ align=middle,
+ foregroundcolor=simpleslides:altcontrastcolor]
+ {\switchtobodyfont[13pt]\bf #1}}% fancy layout
+ {\framed[width=3.5cm,
+ height=4ex,
+ align=middle,
+ frame=off,
+ framecolor=red,
+ foregroundcolor=simpleslides:altcontrastcolor]
+ {\switchtobodyfont[13pt]#1}}% normal layout
+}
+\stopmode
+
+%D Here are the main macros for defining and typesetting the Topic list:
+
+\definelist[MyTopics][criterium=all]
+
+\def\MyMark{}
+
+\def\Topic%
+%{\relax}
+ {\dosingleargument\doTopic}
+
+\def\doTopic[#1]{%
+ \def\MyMark{#1}%
+ \writetolist[MyTopics]{#1}{}%
+}
+
+\setuplist[MyTopics]
+ [pagenumber=no,
+ alternative=command,
+ command=\FancyEntry]
+
+\setuptexttexts[margin][\vbox{\placelist[MyTopics]}][]
%D We use \METAPOST to draw the background.
diff --git a/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-Swoosh.tex b/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-Swoosh.tex
index 0a72866be75..86b20718664 100644
--- a/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-Swoosh.tex
+++ b/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-Swoosh.tex
@@ -19,6 +19,88 @@
\unprotect
+%D The "counter" parameter controls which kind of counter will be used:
+
+\startsetups simpleslides:setup:randomizeyes
+\startuseMPgraphic{simpleslides:MP:randomize}
+if condition = 1:
+ qw := qw shifted (-5pt - c*0.1*uniformdeviate(10), 0) ;
+elseif condition = 2:
+ qw := qw shifted (0, c*0.1*uniformdeviate(10)) ;
+fi ;
+\stopuseMPgraphic
+\stopsetups
+
+\startsetups simpleslides:setups:dot
+\setuplayout [simpleslides:layout:horizontal][header=3cm,footer=0cm]
+\startuseMPgraphic{simpleslides:MP:counter}
+if NOfPages > 1:
+ numeric prog ; prog = PageNumber/NOfPages - 0.005 ;
+fi ;
+if PageNumber > 1:
+ if condition = 1:
+ z11 = (prog * PaperWidth, PaperHeight) ;
+ z12 = (x11, 0) ;
+ z13 = (z11 -- z12) intersectionpoint qw ;
+ draw z13 withcolor \MPcolor{simpleslides:altcontrastcolor} ;
+ elseif condition = 2:
+ z14 = (0, (PaperHeight - prog * PaperHeight)) ;
+ z15 = (PaperWidth, y14) ;
+ z16 = (z14 -- z15) intersectionpoint qw ;
+ draw z16 withcolor \MPcolor{simpleslides:altcontrastcolor} ;
+ fi ;
+fi ;
+\stopuseMPgraphic
+\stopsetups
+
+\startsetups simpleslides:setups:circle
+\setuplayout [simpleslides:layout:horizontal][header=3cm]
+\startuseMPgraphic{simpleslides:MP:counter}
+save b, s, t, p, circcenter, theta, pic ;
+path p[] ;
+pair t[] ;
+pair s[] ;
+pair circcenter ; circcenter = lrcorner Page shifted (-1cm, 1cm) ;
+pair zt, zr, zb, zl ;
+picture pic ;
+b = 1.5cm ;
+if PageNumber > 1:
+ theta = (PageNumber - 1)/(NOfPages - 1) ;
+ p[4] = fullcircle scaled b rotated 90 ;
+ p[4] := p[4] shifted circcenter ;
+ fill p[4] withcolor \MPcolor{simpleslides:altcontrastcolor} ;
+ t[0] = center p[4] ;
+ t[1] = point 1 along p[4] ;
+ t[2] = point -theta along p[4] ;
+ t[3] = point -theta/2 along p[4] ;
+ p[5] = t[0] -- t[1] .. t[3] .. t[2] -- cycle ;
+ fill p[5] withcolor \MPcolor{simpleslides:contrastcolor} ;
+ for i = 1 upto NOfPages :
+ s[i] = point i/(NOfPages -1) along p[4] ;
+ pickup pencircle scaled 1pt ;
+ draw s[i] -- t[0] withcolor \MPcolor{simpleslides:backgroundcolor} ;
+ endfor ;
+ zt = t[0] shifted (0, b * 0.2) ;
+ zr = t[0] shifted (b * 0.2, 0) ;
+ zb = t[0] shifted (0, -b * 0.2) ;
+ zl = t[0] shifted (-b * 0.2, 0) ;
+ p[3] = zt .. zr .. zb .. zl .. cycle ;
+ fill p[3] withcolor \MPcolor{simpleslides:contrastcolor} ;
+ draw p[3] withcolor \MPcolor{simpleslides:backgroundcolor} ;
+ label(textext("\switchtobodyfont[10pt]\color[simpleslides:backgroundcolor]\pagenumber"),center p[3]) ;
+fi ;
+\stopuseMPgraphic
+\stopsetups
+
+\doifsetupselse{simpleslides:setups:\moduleparameter{simpleslides}{counter}}
+ {\setups{simpleslides:setups:\moduleparameter{simpleslides}{counter}}}
+ {\setups{simpleslides:setups:dot}}
+
+\doif%
+ {\moduleparameter{simpleslides}{randomize}}
+ {yes}
+ {\setups{simpleslides:setup:randomizeyes}}
+
%D First we change the page layout, adding more space on the top.
\setuplayout [width=fit,
@@ -30,7 +112,6 @@
backspace=1cm,
location=singlesided]
-\setuplayout [simpleslides:layout:horizontal][header=3cm]
\setuplayout [simpleslides:layout:vertical] [header=0.8cm]
\setuplayout [simpleslides:layout:title] [header=0.8cm]
@@ -54,97 +135,91 @@
%D We define our color scheme:
-\definecolor [simpleslides:backgroundcolor] [r=.88,g=.92,b=.95]
-\definecolor [simpleslides:contrastcolor] [r=.4,g=.6,b=.8]
-\definecolor [simpleslides:altcontrastcolor] [r=.1,g=.1,b=.4]
+\define\SScolorsbackground{r=.88,g=.92,b=.95}
+\define\SScolorscontrasta{r=.4,g=.6,b=.8}
+\define\SScolorscontrastb{r=.1,g=.1,b=.4}
+
+%D I'm still trying to implement a color mechanism that can be set by the users
+%D in their files.
+
+\def\setupSimpleSlideColors[#1]%
+ {\getparameters[SScolors][#1]}
+
+% \setupSimpleSlideColors[background={r=1,g=0,b=0}]
+
+\definecolor [simpleslides:backgroundcolor] [\SScolorsbackground]
+\definecolor [simpleslides:contrastcolor] [\SScolorscontrasta]
+\definecolor [simpleslides:altcontrastcolor] [\SScolorscontrastb]
\definecolor [simpleslides:itemize:color] [simpleslides:contrastcolor]
-\definecolor [simpleslides:textcolor] [simpleslides:altcontrastcolor]
+\definecolor [simpleslides:textcolor] [simpleslides:altcontrastcolor]
\setupcolors[textcolor=simpleslides:textcolor]
%D We use \METAPOST\ to draw backgrounds.
-\startuniqueMPgraphic{simpleslides:MP:horizontal}
+\startuseMPgraphic{simpleslides:MP:horizontal}
StartPage ;
-save a, b;
-numeric a ; a = 2.5cm ;
-numeric b ; b = 0.7cm ;
fill Page withcolor \MPcolor{simpleslides:backgroundcolor} ;
-
-z1 = ulcorner Page ;
-z2 = urcorner Page ;
-z3 = (x1,y1-0.7*a) ;
-z4 = (x1+5cm,y1-a-b) ;
-z5 = (x1+12cm,y1-a) ;
-z6 = (x1+14cm,y1-a+0.3cm) ;
-z7 = (x2,y2-a-b) ;
-
-save p ;
-path p ;
-p = z1--z3..z4..z5..z6..z7--z2--cycle ;
-fill p withcolor \MPcolor{simpleslides:contrastcolor} ;
+numeric c ; c = PaperWidth * 0.4 ;
+numeric d ; d = 2.2cm ;
+numeric e ; e = PaperWidth / 46.9 ;
+numeric condition ; condition = 1 ;
+save ql, qr, qt, qw, qnw, qc ; path ql, qr, qt, qw, qnw, qc ;
+ql = ulcorner Page -- llcorner Page ;
+qr = lrcorner Page -- urcorner Page ;
+qt = urcorner Page -- ulcorner Page ;
pickup pencircle scaled 4pt ;
-draw z3..z4..z5..z6..z7 withcolor white ;
-StopPage ;
-\stopuniqueMPgraphic
-
-\startuniqueMPgraphic{simpleslides:MP:vertical}
-StartPage ;
-
-save a,b;
-numeric a ; a = 2cm ;
-numeric b ; b = 1cm ;
-pair t[] ;
-
-fill Page withcolor \MPcolor{simpleslides:backgroundcolor} ;
z1 = ulcorner Page ;
-z2 = llcorner Page ;
-z3 = center Page ;
-z4 = (x3,y1) ;
-z5 = (x3+b,y1-4cm) ;
-z6 = (x3+b/2,y1-7cm) ;
-z7 = (x3-b/2,y2+2cm) ;
-z8 = (x3,y2) ;
-
-save p;
-path p[] ;
-p[1] = z1--z4..z5..z6..z7..z8--z2--cycle ;
-fill p[1] withcolor \MPcolor{simpleslides:contrastcolor} ;
-pickup pencircle scaled 4pt ;
-draw z4..z5..z6..z7..z8 withcolor white ;
+z2 = (x1, y1 - d - 2*e) ;
+z3 = (x1 + 4pt, y2) ;
+z4 = (x3 + c, y2 + 2*e) ;
+z5 = (x4 + c, y2) ;
+z6 = (x5 + c, y2 + 2*e) ;
+z7 = (x6 + c, y2) ;
+z8 = (x7, y1) ;
+qw = z2 .. z3 .. z4 .. z5 .. z6 .. z7 ;
+\includeMPgraphic{simpleslides:MP:randomize} ;
+z9 = ql intersectionpoint qw ;
+z10 = qr intersectionpoint qw ;
+qw := qw cutbefore z9 cutafter z10 ;
+fill qr & qt & ql -- qw -- cycle withcolor \MPcolor{simpleslides:contrastcolor} ;
+draw qw withcolor white ;
+\includeMPgraphic{simpleslides:MP:counter} ;
StopPage ;
-\stopuniqueMPgraphic
+\stopuseMPgraphic
-\startuseMPgraphic{simpleslides:MP:ornament}
-save b, s, t, p, circcenter, theta, pic ;
+\startuseMPgraphic{simpleslides:MP:vertical}
StartPage ;
-path p[] ;
-pair t[] ;
-pair s[] ;
-pair circcenter ; circcenter = lrcorner Page shifted (-1cm, 1cm) ;
-picture pic ;
-b = 1.5cm ;
+fill Page withcolor \MPcolor{simpleslides:backgroundcolor} ;
+numeric c ; c = PaperHeight * 0.4 ;
+numeric d ; d = 2.2cm ;
+numeric e ; e = PaperHeight / 46.9 ;
if NOfPages > 1:
- theta = (PageNumber - 1)/(NOfPages - 1) ;
- p[4] = fullcircle scaled b rotated 90 ;
- fill p[4] withcolor \MPcolor{simpleslides:altcontrastcolor} ;
- t[0] = center p[4] ;
- t[1] = point 1 along p[4] ;
- t[2] = point -theta along p[4] ;
- t[3] = point -theta/2 along p[4] ;
- p[5] = t[0] -- t[1] .. t[3] .. t[2] -- cycle ;
- fill p[5] withcolor \MPcolor{simpleslides:contrastcolor} ;
- for i = 1 upto NOfPages :
- s[i] = point i/(NOfPages -1) along p[4] ;
- pickup pencircle scaled 1pt ;
- draw s[i] -- t[0] withcolor \MPcolor{simpleslides:backgroundcolor} ;
- endfor ;
- p[3] = p[4] scaled 0.4 ;
- fill p[3] withcolor \MPcolor{simpleslides:contrastcolor} ;
- draw p[3] withcolor \MPcolor{simpleslides:backgroundcolor} ;
- label(textext("\switchtobodyfont[10pt]\color[simpleslides:backgroundcolor]\pagenumber"),origin) ;
- currentpicture := currentpicture shifted circcenter ;
+ numeric prog ; prog = PageNumber/NOfPages - 0.005 ;
fi ;
+numeric condition ; condition = 2 ;
+save ql, qr, qt, qw, qc, qu, qb ; path ql, qr, qt, qw, qc, qu, qb ;
+pickup pencircle scaled 4pt ;
+z1 = ulcorner Page ;
+z3 = center Page ;
+z4 = (x3 - 2*e, y1) ;
+z6 = (x3 + 2*e, y4 - c) ;
+z7 = (x3 - 2*e, y6 - c) ;
+z8 = (x3 + 2*e, y7 - c) ;
+z9 = (x3 - 2*e, y8 - c) ;
+qw = z4 .. z6 .. z7 .. z8 .. z9 ;
+qt = ulcorner Page -- urcorner Page ;
+ql = llcorner Page -- ulcorner Page ;
+qb = llcorner Page -- lrcorner Page ;
+\includeMPgraphic{simpleslides:MP:randomize} ;
+z10 = qt intersectionpoint qw ;
+qu = ulcorner Page -- z10 ;
+z11 = qb intersectionpoint qw ;
+qr = z11 -- llcorner Page ;
+qw := qw cutbefore z10 cutafter z11 ;
+fill qw -- qr & ql & qu -- cycle withcolor \MPcolor{simpleslides:contrastcolor} ;
+draw qw withcolor white ;
+\includeMPgraphic{simpleslides:MP:counter} ;
StopPage ;
\stopuseMPgraphic
diff --git a/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-default.tex b/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-default.tex
index 9386fcc1562..43253a837a0 100644
--- a/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-default.tex
+++ b/Master/texmf-dist/tex/context/third/simpleslides/simpleslides-s-default.tex
@@ -35,9 +35,9 @@
%D As for the page layout: most of the numbers have been reached by
%D trial and error; I have just taken what seemed to produce the best output.
-\setuplayout [width=fit,
+\setuplayout [width=middle,
margin=0.6cm,
- height=fit,
+ height=middle,
header=0.15cm,
footer=1.35cm,
footerdistance=0.5cm,
@@ -54,6 +54,17 @@
\definelayout [simpleslides:layout:horizontal]
\definelayout [simpleslides:layout:vertical]
\definelayout [simpleslides:layout:title]
+\definelayout [simpleslides:layout:page]
+
+\setuplayout [simpleslides:layout:page]
+ [topspace=0cm,
+ header=0cm,
+ footer=0cm,
+ bottomspace=0cm,
+ backspace=0cm,
+ cutspace=0cm,
+ width=middle,
+ height=middle]
%D We want colored presentations
@@ -71,7 +82,7 @@
%D We use combinations for placing vertical pictures and text side by side, and
%D we want a distance of 3em between both.
-\setupcombinations[distance=3em]
+\setupcombinations[distance=0.9cm]
%D Next we define some dimensions that are used as nominal values by other
%D macros and the user.
@@ -102,6 +113,7 @@
\defineoverlay[simpleslides:background:title]
\defineoverlay[simpleslides:background:vertical]
\defineoverlay[simpleslides:background:ornament]
+\defineoverlay[simpleslides:background:page]
\defineoverlay[simpleslides:background:highlight]
[\useMPgraphic{simpleslides:MP:highlight}]%
@@ -110,18 +122,42 @@
[\c!width=\paperwidth,
\c!height=\paperheight]
+\definelayer[simpleslides:layer:page]
+ [\c!width=\paperwidth,
+ \c!height=\paperheight]
+
+\definelayer[simpleslides:layer:extras]
+ [\c!width=\paperwidth,
+ \c!height=\paperheight]
+
+\definelayer[simpleslides:layer:highlight]
+ [\c!width=\paperwidth,
+ \c!height=\paperheight]
+
+
%D A generic frame which is used for titles and other commands
\defineframed[simpleslides:framed]
- [frame=off,offset=0pt,
- top=\vss,bottom=\vss]
+ [\c!frame=\v!off,\c!offset=\zeropoint,
+ \c!top=\vss,\c!bottom=\vss]
+
+\defineframed[simpleslides:framed:page]
+ [\c!frame=\v!off,\c!offset=3mm,
+ \c!top=\vss,\c!bottom=\vss,
+ \c!width=fit,
+ \c!corner=\v!round,
+ \c!background=\v!color,
+ \c!backgroundcolor=simpleslides:backgroundcolor]
+
%D Now we define setups for specific backgrounds
\startsetups simpleslides:background:title
\setuplayout[simpleslides:layout:title]
\setupbackgrounds[\v!page]
- [background={simpleslides:background:title}]
+ [background={simpleslides:background:title,
+ foreground,
+ simpleslides:layer:highlight}]
\stopsetups
\startsetups simpleslides:background:horizontal
@@ -129,16 +165,31 @@
\setupbackgrounds[\v!page]
[background={simpleslides:background:horizontal,
simpleslides:background:ornament,
- simpleslides:layer:slidetitle}]
+ simpleslides:layer:extras,
+ simpleslides:layer:slidetitle,
+ foreground,
+ simpleslides:layer:highlight}]
\stopsetups
\startsetups simpleslides:background:vertical
\setuplayout[simpleslides:layout:vertical]
\setupbackgrounds[\v!page]
[background={simpleslides:background:vertical,
+ simpleslides:layer:extras,
simpleslides:background:ornament}]
\stopsetups
+\startsetups simpleslides:background:page
+ \page
+ \setuplayout[simpleslides:layout:page]
+ \setupbackgrounds[\v!page]
+ [background={simpleslides:background:page,
+ foreground,
+ %simpleslides:background:ornament,
+ simpleslides:layer:extras,
+ simpleslides:layer:page}]
+\stopsetups
+
%D We also define some fall backs for presentation backgrounds.
\startsetups simpleslides:background:default
@@ -290,6 +341,18 @@
{\doattributes{\??vars:simpleslides:slidetitle:}\c!style\c!color{#1}}}%
\simpleslidesslidetitleparameter\c!after}
+\defineSlideTitleAlternative[page]#1%
+ {\page[\simpleslidesslidetitleparameter\c!page]%
+ %\simpleslidesslidetitleparameter\c!before
+ \setlayer[simpleslides:layer:page]%
+ [\c!preset=\simpleslidesslidetitleparameter\c!preset,
+ \c!hoffset=\simpleslidesslidetitleparameter\c!hoffset,
+ \c!voffset=\simpleslidesslidetitleparameter\c!voffset]
+ {\getvalue{simpleslides:framed:page}
+ [\c!align=\simpleslidesslidetitleparameter\c!align]
+ {\let\\\crlf\doattributes{\??vars:simpleslides:slidetitle:}\c!style\c!color{#1}}}}
+ %\simpleslidesslidetitleparameter\c!after}
+
%D Now the main user command
@@ -356,7 +419,7 @@
direction=0,
opacity=0.4,
shadow=\v!no,
- shadow\c!color=black,
+ shadow\c!color=gray,
verticalbackground=none,
verticalbackgroundcolor=simpleslides:backgroundcolor,
verticalforegroundcolor=simpleslides:textcolor,
@@ -430,6 +493,7 @@
\processaction[#1]
[\v!horizontal=>{\doIncludePictureHorizontal[#2]{#4}},
\v!vertical=>{\doIncludePictureVertical[#2]{#4}},
+ \v!page=>{\doIncludePicturePage[#2]{#4}},
\v!default=>{\doIncludePictureHorizontal[#2]{#4}},
\v!unknown=>{\doIncludePictureHorizontal[#2]{#4}}%
\message{Keywords for positioning pictures are
@@ -444,20 +508,20 @@
%D the available space. Small pictures will be enlarged, big pictures will be
%D fit. This code was suggested by Wolfgang Schuster on the mailing list.
-\def\setPictureDimensionsTo#1#2% graphic width
+\def\setPictureDimensionsTo#1#2#3% graphic height width
{\doifelsenothing{\simpleslidesPictureParameter\c!width}
{\doifelsenothing{\simpleslidesPictureParameter\c!height}
{\setbox\scratchbox\hbox{\externalfigure[#1]
[\c!page=\simpleslidesPictureParameter\c!page]}
% Courtsey Wolfgang Schuster
- \ifdim\dimexpr#2*100/\wd\scratchbox\relax <
- \dimexpr\PictureFrameHeight*100/\ht\scratchbox\relax
+ \ifdim\dimexpr#3*100/\wd\scratchbox\relax <
+ \dimexpr#2*100/\ht\scratchbox\relax
%
- \setvalue{simpleslides:picture:width}{#2}%
+ \setvalue{simpleslides:picture:width}{#3}%
\setvalue{simpleslides:picture:height}{}%
\else
\setvalue{simpleslides:picture:width}{}%
- \setvalue{simpleslides:picture:height}{\PictureFrameHeight}%
+ \setvalue{simpleslides:picture:height}{#2}%
\fi}
{\setvalue{simpleslides:picture:width}{}%
\setvalue{simpleslides:picture:height}{\simpleslidesPictureParameter\c!height}}}
@@ -487,7 +551,7 @@
%D This macro places the picture in horizontal mode.
\def\doIncludePictureHorizontal[#1]#2% graphic text
- {\setPictureDimensionsTo{#1}\textwidth
+ {\setPictureDimensionsTo{#1}\PictureFrameHeight\textwidth
\SlideTitle{#2}%
\doplacePictureFrame
[\c!width=\textwidth,
@@ -502,7 +566,7 @@
\def\doIncludePictureVertical[#1]#2% graphic text
{\page
- \setPictureDimensionsTo{#1}\PictureFrameWidth
+ \setPictureDimensionsTo{#1}\PictureFrameHeight\PictureFrameWidth
\setupPageBackground[vertical]
\startcombination[2]
{\doplacePictureFrame
@@ -525,6 +589,21 @@
\c!strut=\v!no]{#2}}{}
\stopcombination
\page}% Otherwise last page is not correct in \MKII.
+
+%D This macro places the picture in full page mode
+
+\def\doIncludePicturePage[#1]#2% graphic text
+ {%\setPictureDimensionsTo{#1}{0.95\paperheight}{0.95\paperwidth}
+ \getvalue{simpleslides:slidetitle:page}{#2}%
+ \setupPageBackground[page]%
+ \doplacePictureFrame
+ [\c!width=\paperwidth,
+ \c!height=\paperheight]
+ {\externalfigure[#1]
+ [\c!height=\paperheight,
+ \c!width=\paperwidth,
+ \c!page=\simpleslidesPictureParameter\c!page]}%
+ \page}% Otherwise last page is not correct in \MKII.
%D Now, we define the main \METAPOST\ graphic to highlight the picture. It first
%D checks if the user has asked for a grid, and if so, draws a grid and a
@@ -734,7 +813,7 @@
\simpleslidesPictureParameter\c!y *OverlayHeight/10) ;
fill OverlayBox -- reverse p -- cycle
- withcolor transparent ("normal",
+ withcolor transparent (1,
\simpleslidesPictureParameter{opacity},
\MPcolor{\simpleslidesPictureParameter{shadow\c!color}}) ;
\stopuseMPgraphic
@@ -753,7 +832,7 @@
%% I hope there were a better way to do this.
for i = 1 upto 20 :
shadow_draw p shifted shadow_direction
- withcolor transparent ("normal",
+ withcolor transparent (1,
\simpleslidesPictureParameter{opacity}/10, % 0.1,
\MPcolor{\simpleslidesPictureParameter{shadow\c!color}})
withpen pencircle scaled (i*shadow_thickness/20) ;
@@ -774,6 +853,18 @@
withcolor \MPcolor{simpleslides:itemize:color} ;
\stopuniqueMPgraphic
+%D Sometimes we want an image as a background of a page. For that, we use the
+%D following macro. You need to set a transparent image foreground color for
+%D this to work. TODO: This macro should be combined with \type{\SlideTitle}
+
+\def\SlideBackground#1%
+ {\setlayer[simpleslides:layer:extras]
+ {\externalfigure
+ [#1]
+ [width=\paperwidth,height=\paperheight,
+ background={foreground,color},backgroundcolor=simpleslides:imageforegroundcolor]}}
+
+
\protect
diff --git a/Master/texmf-dist/tex/context/third/simpleslides/t-simpleslides.tex b/Master/texmf-dist/tex/context/third/simpleslides/t-simpleslides.tex
index 302188c6395..db81ce6737d 100644
--- a/Master/texmf-dist/tex/context/third/simpleslides/t-simpleslides.tex
+++ b/Master/texmf-dist/tex/context/third/simpleslides/t-simpleslides.tex
@@ -71,6 +71,10 @@
[simpleslides-s]
[default]
+\usemodule
+ [simpleslides-c]
+ [default]
+
\doiffileelse{\currentmoduleparameter\c!style}
{\usemodule[\currentmoduleparameter\c!style]}
{\usemodule[simpleslides-s][\currentmoduleparameter\c!style]}