| Author | DaveJarvis <email> |
|---|---|
| Date | 2021-04-15 21:36:59 GMT-0700 |
| Commit | 74c5c621ae9af1de14ed6df627133194763636df |
| Parent | 9a8fa61 |
| -\definecolor[WPtocheading][h=111111] | ||
| -\definecolor[WPinternal][h=46A5E5] | ||
| -\definecolor[WPexternal][h=B93507] | ||
| -\definecolor[WPframe][h=EEEEEE] | ||
| +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | ||
| +% | ||
| +% Constant declarations for colours used throughout the document | ||
| +% | ||
| +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | ||
| + | ||
| +% Darken or lighten the colours by the same amount. | ||
| +\def\TextColourDk{0.5} | ||
| +\def\TextColourLt{1.5} | ||
| + | ||
| +% Main colour | ||
| +\definecolor[TextColourPrimary][h=0081C2] | ||
| + | ||
| +% Accent colour | ||
| +\definecolor[TextColourSecondary][h=CB4A4C] | ||
| + | ||
| +% Shade colours | ||
| +\definecolor[TextColourTertiary][h=454545] | ||
| + | ||
| +% Hyperlink colour | ||
| +\definecolor[TextColourHyperlink][h=6C984C] | ||
| + | ||
| +\definespotcolor[TextColourPrimaryDk][TextColourPrimary][p=\TextColourDk] | ||
| +\definespotcolor[TextColourPrimaryLt][TextColourPrimary][p=\TextColourLt] | ||
| + | ||
| +\definespotcolor[TextColourSecondaryDk][TextColourSecondary][p=\TextColourDk] | ||
| +\definespotcolor[TextColourSecondaryLt][TextColourSecondary][p=\TextColourLt] | ||
| + | ||
| +\definespotcolor[TextColourTertiaryDk][TextColourTertiary][p=\TextColourDk] | ||
| +\definespotcolor[TextColourTertiaryLt][TextColourTertiary][p=\TextColourLt] | ||
| -\define\WPui{User Interface} | ||
| -\define\WPintro{Overview} | ||
| -\define\WPnavigation{Navigation} | ||
| -\define\WPproposal{proposal} | ||
| -\define\WPproposals{\WPproposal{}s} | ||
| -\define\WPProposal{\Word{\WPproposal{}}} | ||
| -\define\WPProposals{\WPProposal{}s} | ||
| - | ||
| -\define\WPdeliberation{deliberation} | ||
| -\define\WPdeliberations{\WPdeliberation{}s} | ||
| -\define\WPDeliberation{\Word{\WPdeliberation{}}} | ||
| -\define\WPDeliberations{\WPdeliberation{}s} | ||
| - | ||
| -% Separator for contiguous citations. | ||
| -\define\WPcitesep{\high{\,}} | ||
| - | ||
| -% Links to the web site for demonstration purposes. | ||
| -\def\WPhomepagebase{http://djarvis.bitbucket.org/xml/} | ||
| -\edef\WPpageaccount{\WPhomepagebase account.xml} | ||
| -\edef\WPpagediscuss{\WPhomepagebase discuss.xml} | ||
| -\edef\WPpagehome{\WPhomepagebase index.xml} | ||
| -\edef\WPpagehypothesis{\WPhomepagebase hypothesis.xml} | ||
| -\edef\WPpageproposal{\WPhomepagebase proposal.xml} | ||
| -\edef\WPpagesummary{\WPhomepagebase summary.xml} | ||
| -\edef\WPpagesupport{\WPhomepagebase support.xml} | ||
| -\edef\WPpageresources{\WPhomepagebase resources.xml} | ||
| - | ||
| % Since the TOC suppresses a chapter title, conditionally set the | ||
| % page heading. | ||
| {\vl{}}% | ||
| {}% | ||
| -} | ||
| - | ||
| -\define[1]\WPcode{The #1 page source:\\} | ||
| - | ||
| -\define[3]\WPquote{% | ||
| - \quotation{#1} | ||
| - \par | ||
| - \startalignment[flushright] | ||
| - \textasciitilde{} #2, \it{#3} | ||
| - \stopalignment | ||
| -} | ||
| - | ||
| -\define[1]\WPpage{% | ||
| - \placefigure[force][fig:page-#1]{\Word{#1 Page}}{% | ||
| - \externalfigure[#1.svg] | ||
| - } | ||
| -} | ||
| - | ||
| -\define[1]\WPxref{% | ||
| - \in{Figure}[fig:#1] illustrates% | ||
| -} | ||
| - | ||
| -\define[1]\WPrefpage{% | ||
| - (see page \at[cha:#1])% | ||
| -} | ||
| - | ||
| -\define[1]\WPrefchapter{% | ||
| - \about[cha:#1] \WPrefpage{#1}% | ||
| -} | ||
| - | ||
| -\define[1]\WPreffigure{% | ||
| - illustrated in \in{Figure}[fig:#1] (on page \at[fig:#1])% | ||
| -} | ||
| - | ||
| -\define[1]\WPregistered{% | ||
| - #1\fontchar{registered}% | ||
| } | ||
| +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | ||
| +% | ||
| +% Settings that apply to the whole document | ||
| +% | ||
| +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | ||
| + | ||
| +% Enable full-colour documents | ||
| +\setupcolors[ | ||
| + state=start, | ||
| + rgb=yes, | ||
| + color=TextColourHyperlink, | ||
| + textcolor=TextColourTertiaryDk, | ||
| + pagecolormodel=auto, | ||
| + spot=no, | ||
| +] | ||
| + | ||
| +% Enable clickable hyperlinks | ||
| +% title={}, | ||
| +% author={} | ||
| +% subtitle={}, | ||
| +% keyword={}, | ||
| +\setupinteraction[ | ||
| + state=start, | ||
| + color=TextColourHyperlink, | ||
| + contrastcolor=TextColourSecondary, | ||
| +] | ||
| + | ||
| +\placebookmarks[title, chapter][ | ||
| + force=yes, | ||
| +] | ||
| + | ||
| +% Prevent widows and orphans by forcing at least two (2) lines together | ||
| +\startsetups[grid][TextPenalties] | ||
| + \setdefaultpenalties | ||
| + \setpenalties\widowpenalties{2}{10000} | ||
| + \setpenalties\clubpenalties {2}{10000} | ||
| +\stopsetups | ||
| + | ||
| +\setuplayout[ | ||
| + setups=TextPenalties, | ||
| +] | ||
| + | ||
| directory={screens,graphs}, | ||
| frame=on, | ||
| - framecolor=WPframe, | ||
| + framecolor=TextColourTertiaryLt, | ||
| rulethickness=1pt, | ||
| frameoffset=.5em, |
| \definefontfamily [TextFont] [ss] [Archivo Narrow] | ||
| \definefontfamily [TextFont] [tt] [Inconsolata] | ||
| -\definefontfamily [TextFont] [mm] [Lucida Bright Math OT] | ||
| -\definefontfamily [TextFont] [hw] [Lucida Handwriting OT] | ||
| -\definefontfamily [TextFont] [cg] [Lucida Calligraphy OT] | ||
| \setupbodyfont[TextFont] |
| -\setupinteraction[ | ||
| - state=start, | ||
| - color=WPinternal, | ||
| - contrastcolor=WPinternal, | ||
| - title={Liberum Consilium}, | ||
| - author={White Magic Software, Ltd.}, | ||
| - subtitle={A system design for moderated deliberation}, | ||
| - keyword={proposal, policy, democracy, software, discussion, deliberation}, | ||
| -] | ||
| - | ||
| -\placebookmarks[title, chapter][ | ||
| - force=yes, | ||
| -] | ||
| +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | ||
| +% | ||
| +% Command to simplify hyperlink syntax | ||
| +% | ||
| +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | ||
| % Create hyperlink references within the document. | ||
| \define[2]\href{% | ||
| - \goto{\color[WPexternal]{#1}}[url(#2)]% | ||
| + \goto{\color[TextColourHyperlink]{#1}}[url(#2)]% | ||
| } | ||
| \input fonts | ||
| \input colours | ||
| +\input document | ||
| \input hyperlinks | ||
| \input layout | ||
| \input headings | ||
| \input pages | ||
| \input makeups | ||
| +\input paragraphs | ||
| \input figures | ||
| \input tables |
| ] | ||
| -\setupcolors[ | ||
| - state=start, | ||
| - rgb=yes, | ||
| - spot=no, | ||
| -] | ||
| - | ||
| -\setupcolors[pagecolormodel=auto] | ||
| - | ||
| -\setuplayout[ | ||
| - setups=*lessstrict, | ||
| - location=singlesided, | ||
| -] | ||
| - | ||
| -% Strongly suggest avoiding orphaned headings. | ||
| -\startsetups[*lessstrict] | ||
| - \setup[*reset] | ||
| - \widowpenalty=10000 | ||
| - \clubpenalty=1000 | ||
| - \brokenpenalty=100 | ||
| -\stopsetups | ||
| - | ||
| \setupwhitespace[medium] | ||
| +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | ||
| +% | ||
| +% Configure how paragraphs are presented | ||
| +% | ||
| +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | ||
| + | ||
| +\setupindenting[medium, yes] | ||
| + | ||
| +\setbreakpoints[compound] | ||
| + | ||
| +\setupalign[ | ||
| + hz, | ||
| + hanging, | ||
| + lesshyphenation, | ||
| +] | ||
| + | ||
| +\setuptolerance[ | ||
| + stretch, | ||
| + verytolerant, | ||
| +] | ||
| + | ||
| \setupxtable[body][] | ||
| \setupxtable[foot][ | ||
| + topframe=on, | ||
| bottomframe=on, | ||
| rulethickness=1pt, |
| % Set up the ToC so that the page numbers are the internal link colour. | ||
| \setuplist[chapter, section, subsection][ | ||
| - pagecolor=WPinternal, | ||
| - color=WPtocheading, | ||
| + pagecolor=TextColourHyperlink, | ||
| + color=TextColourPrimary, | ||
| before={\setupheader[state=stop]}, | ||
| ] |
| textcolor=TextColourTertiaryDk, | ||
| pagecolormodel=auto, | ||
| + spot=no, | ||
| ] | ||
| % Enable clickable hyperlinks | ||
| +% title={}, | ||
| +% author={} | ||
| +% subtitle={}, | ||
| +% keyword={}, | ||
| \setupinteraction[ | ||
| - state=start | ||
| + state=start, | ||
| + color=TextColourHyperlink, | ||
| + contrastcolor=TextColourSecondary, | ||
| +] | ||
| + | ||
| +\placebookmarks[title, chapter][ | ||
| + force=yes, | ||
| ] | ||
| % %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | ||
| +% Create hyperlink references within the document. | ||
| \define[2]\href{% | ||
| - \begingroup | ||
| - \setupinteraction[ | ||
| - style=normal, | ||
| - color=TextColourHyperlink, | ||
| - ]% | ||
| - \goto{\color[TextColourHyperlink]{#1}}[url(#2)]% | ||
| - \endgroup% | ||
| + \goto{\color[TextColourHyperlink]{#1}}[url(#2)]% | ||
| } | ||
| \input tables | ||
| \input paragraphs | ||
| +\input quotations | ||
| \input rules | ||
| +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | ||
| +% | ||
| +% Configure how quotations are presented | ||
| +% | ||
| +% %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% | ||
| + | ||
| +\define\TextQuotationBefore{\blank\startnarrower} | ||
| +\define\TextQuotationAfter{\stopnarrower\blank} | ||
| + | ||
| +\setupdelimitedtext[quotation][ | ||
| + before=\TextQuotationBefore, | ||
| + after=\TextQuotationAfter, | ||
| + repeat=yes, | ||
| + middle={\symbol[leftquotation]}, | ||
| +] | ||
| + | ||
| \setupxtable[body][] | ||
| \setupxtable[foot][ | ||
| + topframe=on, | ||
| bottomframe=on, | ||
| rulethickness=1pt, |
| % Block elements | ||
| - \xmlsetsetup{\xmldocument}{p|blockquote|div}{xml:*} | ||
| + \xmlsetsetup{\xmldocument}{blockquote|div|p}{xml:*} | ||
| + \xmlsetsetup{\xmldocument}{blockquote/p}{xml:blockquote:p} | ||
| + \xmlsetsetup{\xmldocument}{blockquote[count(p)=1]}{xml:blockquote:single} | ||
| + \xmlsetsetup{\xmldocument}{blockquote[count(p)=2]/p[position()=first()]}{xml:blockquote:began} | ||
| + \xmlsetsetup{\xmldocument}{blockquote[count(p)=2]/p[position()=last()]}{xml:blockquote:ended} | ||
| + \xmlsetsetup{\xmldocument}{blockquote[count(p)>2]/p[position()=first()]}{xml:blockquote:began} | ||
| + \xmlsetsetup{\xmldocument}{blockquote[count(p)>2]/p[position()>first() and position()<last()]}{xml:blockquote:multiple:middle} | ||
| + \xmlsetsetup{\xmldocument}{blockquote[count(p)>2]/p[position()=last()]}{xml:blockquote:ended} | ||
| % List elements |
| % Paragraphs are followed by a paragraph break. | ||
| \startxmlsetups xml:p | ||
| - \xmlflush{#1}\par | ||
| + \startparagraph | ||
| + \xmlflush{#1} | ||
| + \stopparagraph | ||
| \stopxmlsetups | ||
| % Indented quotations. | ||
| \startxmlsetups xml:blockquote | ||
| - \quotation{\xmlflush{#1}} | ||
| + \xmlflush{#1} | ||
| +\stopxmlsetups | ||
| + | ||
| +\startxmlsetups xml:blockquote:p | ||
| + \xmlflush{#1} | ||
| +\stopxmlsetups | ||
| + | ||
| +\startxmlsetups xml:blockquote:single | ||
| + \startquotation | ||
| + \xmlflush{#1} | ||
| + \stopquotation | ||
| +\stopxmlsetups | ||
| + | ||
| +\startxmlsetups xml:blockquote:began | ||
| + \startquotation | ||
| + \xmlflush{#1} | ||
| +\stopxmlsetups | ||
| + | ||
| +\startxmlsetups xml:blockquote:multiple:middle | ||
| + \par\xmlflush{#1} | ||
| +\stopxmlsetups | ||
| + | ||
| +\startxmlsetups xml:blockquote:ended | ||
| + \par\xmlflush{#1} | ||
| + \stopquotation | ||
| \stopxmlsetups | ||
| Delta | 173 lines added, 119 lines removed, 54-line increase |
|---|