pandoc/tests/writers-lang-and-dir.context

114 lines
2.7 KiB
Text
Raw Normal View History

% Enable hyperlinks
\setupinteraction
[state=start,
2015-11-13 01:09:41 +01:00
style=,
color=,
contrastcolor=]
% make chapter, section bookmarks visible when opening document
\placebookmarks[chapter, section, subsection, subsubsection, subsubsubsection, subsubsubsubsection][chapter, section]
\setupinteractionscreen[option=bookmark]
\setuptagging[state=start]
2015-11-13 01:09:41 +01:00
% use microtypography
\definefontfeature[default][default][protrusion=quality,expansion=quality,onum=yes,pnum=yes]
\definefontfeature[smallcaps][smallcaps][protrusion=quality,expansion=quality,onum=yes,pnum=yes]
\setupalign[hz,hanging]
\setupbodyfontenvironment[default][em=italic] % use italic as em, not slanted
\setupbodyfont[mainfont]
\setupwhitespace[medium]
\setuphead[chapter] [style=\tfd,header=empty]
\setuphead[section] [style=\tfc]
\setuphead[subsection] [style=\tfb]
\setuphead[subsubsection] [style=\bf]
\setuphead[subsubsubsection] [style=\sc]
\setuphead[subsubsubsubsection][style=\it]
\setuphead[chapter, section, subsection, subsubsection, subsubsubsection, subsubsubsubsection][number=no]
\definedescription
[description]
[headstyle=bold, style=normal, location=hanging, width=broad, margin=1cm, alternative=hanging]
\setupitemize[autointro] % prevent orphan list intro
\setupitemize[indentnext=no]
\setupfloat[figure][default={here,nonumber}]
\setupfloat[table][default={here,nonumber}]
\setupthinrules[width=15em] % width of horizontal rules
\setuphead[title][
style={\tfd\raggedcenter},
before={\startalignment[middle]},
after={
\bigskip\stopalignment}]
\starttext
\section[empty-divs-and-spans]{Empty Divs and Spans}
Some text and
div contents
and more text.
Next paragraph with a span and a word-thatincludesaspanright?
\section[directionality]{Directionality}
Some text and
\startalignment[righttoleft]
rtl div contents
\stopalignment
and more text.
\startalignment[lefttoright]
and a ltr div. with a {\righttoleft rtl span}.
\stopalignment
Next paragraph with a {\righttoleft rtl span} and a
word-that-includesa{\lefttoright ltrspan}right?
\section[languages]{Languages}
Some text and
\start\language[de]
German div contents
\stop
and more text.
Next paragraph with a \start\language[en-gb]British span\stop and a
word-that-includesa\start\language[de-ch]Swiss German span\stop right?
Some \start\language[es]Spanish text\stop .
\section[combined]{Combined}
Some text and
\start\language[fr]
\startalignment[righttoleft]
French rtl div contents
\stopalignment
\stop
and more text.
Next paragraph with a \start\language[en-gb]{\lefttoright British ltr
span}\stop and a
word-that-includesa\start\language[de-ch]{\lefttoright Swiss German ltr
span}\stop right?
\stoptext