From 9267eacce4c7971d8e6b466642a4e0720592be3f Mon Sep 17 00:00:00 2001 From: Yann Herklotz Date: Mon, 8 Aug 2022 23:13:08 +0100 Subject: Add more changes --- presentation.mkiv | 8 +++-- s-present-split.mkiv | 82 ++++++++++++++++++++++++++++++++++++++++++---------- type-imp-ymhgd.mkiv | 8 ++--- 3 files changed, 77 insertions(+), 21 deletions(-) diff --git a/presentation.mkiv b/presentation.mkiv index 0d283db..723c350 100644 --- a/presentation.mkiv +++ b/presentation.mkiv @@ -5,14 +5,18 @@ subtitle=Yann Herklotz, location=INI'22] -\Topic{Forms of Predicated Execution} +\Title{Predicated Execution} + +\Title{} \Topic{Knuth} -\Topic{Reich} +\Title{Reich} \Topic{Zapf} +\Title{Predicated Execution} + \Topic{Materie} \stopdocument diff --git a/s-present-split.mkiv b/s-present-split.mkiv index ae3b1df..b787b4b 100644 --- a/s-present-split.mkiv +++ b/s-present-split.mkiv @@ -38,7 +38,11 @@ header=0pt, footer=0pt, topspace=1cm, - backspace=1cm] + backspace=1cm, + grid=yes,] + +%\showframe +%\showgrid \setupbackgrounds [page] @@ -46,23 +50,58 @@ %D We only use two colors, named \type {ColorOne} and \type {ColorTwo}: -\definecolor [ColorOne] [x=E0C2B8] -\definecolor [ColorTwo] [x=ACCDC7] +\definecolor [ColorOne] [x=F0EFEB] +\definecolor [ColorTwo] [x=DBE7E4] + +\definecolor[ChapOneColOne] [x=D6E2E9] +\definecolor[ChapOneColTwo] [x=BCD4E6] + +\definecolor[ChapTwoColOne] [x=FFF1E6] +\definecolor[ChapTwoColTwo] [x=EDDCD2] + +\definecolor[ChapThreeColOne] [x=FDE2E4] +\definecolor[ChapThreeColTwo] [x=FAD2E1] + +\definecolor[ChapFourColOne] [x=F5EFFF] +\definecolor[ChapFourColTwo] [x=E5D9F2] + +\definecolor[ChapFiveColOne] [x=FAEDCB] +\definecolor[ChapFiveColTwo] [x=F7D9C4] \defineoverlay[numberb][\useMPgraphic{numberb}] \startuseMPgraphic{numberb} + CurrentTitleNum := \somenamedheadnumber{Title}{current} ; + color FirstCol ; color SecondCol ; + FirstCol := \MPcolor{ColorOne} ; + SecondCol := \MPcolor{ColorTwo} ; StartPage ; + if CurrentTitleNum = 1 : + FirstCol := \MPcolor{ChapOneColOne} ; + SecondCol := \MPcolor{ChapOneColTwo} ; + elseif CurrentTitleNum = 2 : + FirstCol := \MPcolor{ChapTwoColOne} ; + SecondCol := \MPcolor{ChapTwoColTwo} ; + elseif CurrentTitleNum = 3 : + FirstCol := \MPcolor{ChapThreeColOne} ; + SecondCol := \MPcolor{ChapThreeColTwo} ; + elseif CurrentTitleNum = 4 : + FirstCol := \MPcolor{ChapFourColOne} ; + SecondCol := \MPcolor{ChapFourColTwo} ; + elseif CurrentTitleNum = 4 : + FirstCol := \MPcolor{ChapFiveColOne} ; + SecondCol := \MPcolor{ChapFiveColTwo} ; + fi ; picture Left, Right ; numeric Shift ; Shift := -TextWidth - BackSpace - RightEdgeDistance/2 ; - fill Page withcolor "ColorOne" ; - fill Page leftenlarged Shift withcolor "ColorTwo" ; + fill Page withcolor FirstCol ; + fill Page leftenlarged Shift withcolor SecondCol ; if RealPageNumber > 1 : Left := Right := textext("\bf\pagenumber") ysized 3cm ; clip Right to boundingbox Right shifted ( bbwidth(Right)/2,0) ; clip Left to boundingbox Left shifted (-bbwidth(Left) /2,0) ; - draw Left shifted (-Shift,2.25cm) withcolor "ColorTwo" ; - draw Right shifted (-Shift,2.25cm) withcolor "ColorOne" ; + draw Left shifted (-Shift,2.25cm) withcolor SecondCol ; + draw Right shifted (-Shift,2.25cm) withcolor FirstCol ; fi ; StopPage ; \stopuseMPgraphic @@ -96,9 +135,19 @@ %D Next we define structuring commands. -\definehead[Topic] [chapter] \setuphead[Topic] [style=\ssc\bf] -\definehead[Subject][section] \setuphead[Subject][style=\ssa\bf] +\definehead[Title] [chapter] +\definehead[Topic] [section] +\definehead[Subject][subsection] + +\setuphead[Title] + [style={\ttd\bf}, + align=middle, + grid=middle, + before={\blank[5*big,force]}, + page={yes},after=\page,] +\setuphead[Topic][style={\ttc\bf},page={yes},] +\setuphead[Subject][style={\tta\bf}] \setuphead [Topic,Subject] [number=no, @@ -106,6 +155,7 @@ %D Because we will provide a menu, we don't offer lists. +\let\Titles \gobbleoneargument \let\Topics \gobbleoneargument \let\Subjects\relax @@ -116,18 +166,20 @@ [color=black, contrastcolor=Two] \placelist - [Topic] - [alternative=f, + [Title] + [alternative=paragraph, + pagenumber=no, + headnumber=no, frame=off, criterium=all,] \vfill \stopinteractionmenu \setuplist - [Topic] + [Title] [width=\rightedgewidth, maxwidth=\rightedgewidth, - style=\ssxx\bf, + style=\ttxx\bf, width=fit] %D We safe some space: @@ -147,8 +199,8 @@ \unexpanded\def\StartTitlePage {\startstandardmakeup \setupalign[middle] - \enforced\protected\def\\{\vfil\ssa\setupinterlinespace} - \ssc\bf\setupinterlinespace + \enforced\protected\def\\{\vfil\tta\setupinterlinespace} + \ttc\bf\setupinterlinespace \vfil} \unexpanded\def\StopTitlePage diff --git a/type-imp-ymhgd.mkiv b/type-imp-ymhgd.mkiv index ccc0301..92303aa 100644 --- a/type-imp-ymhgd.mkiv +++ b/type-imp-ymhgd.mkiv @@ -1,8 +1,8 @@ \starttypescript[mono] [iosevka] - \definefontsynonym[Iosevka-Regular] [name:iosevkaslabmedium] - \definefontsynonym[Iosevka-Italic] [name:iosevkaslabmediumitalic] - \definefontsynonym[Iosevka-Bold] [name:iosevkaslabbold] - \definefontsynonym[Iosevka-BoldItalic] [name:iosevkaslabbolditalic] + \definefontsynonym[Iosevka-Regular] [name:iosevkaymhgmedium] + \definefontsynonym[Iosevka-Italic] [name:iosevkaymhgmediumitalic] + \definefontsynonym[Iosevka-Bold] [name:iosevkaymhgbold] + \definefontsynonym[Iosevka-BoldItalic] [name:iosevkaymhgbolditalic] \stoptypescript \starttypescript[mono] [iosevka] -- cgit