summaryrefslogtreecommitdiff
path: root/tex
diff options
context:
space:
mode:
Diffstat (limited to 'tex')
-rw-r--r--tex/context/base/context.tex2
-rw-r--r--tex/context/base/core-des.tex434
-rw-r--r--tex/context/base/core-int.tex20
-rw-r--r--tex/context/base/core-lst.tex17
-rw-r--r--tex/context/base/core-new.tex48
-rw-r--r--tex/context/base/core-not.tex3
-rw-r--r--tex/context/base/core-obj.tex3
-rw-r--r--tex/context/base/enco-cas.tex23
-rw-r--r--tex/context/base/enco-def.tex9
-rw-r--r--tex/context/base/enco-ffr.tex8
-rw-r--r--tex/context/base/enco-ini.tex21
-rw-r--r--tex/context/base/lang-ita.tex20
-rw-r--r--tex/context/base/mult-con.tex19
-rw-r--r--tex/context/base/page-flt.tex6
-rw-r--r--tex/context/base/spec-dpx.tex308
-rw-r--r--tex/context/base/spec-tst.tex151
-rw-r--r--tex/context/base/verb-xml.tex9
-rw-r--r--tex/context/interface/cont-cz.xml8
-rw-r--r--tex/context/interface/cont-de.xml8
-rw-r--r--tex/context/interface/cont-it.xml8
-rw-r--r--tex/context/interface/cont-nl.xml8
-rw-r--r--tex/context/interface/cont-ro.xml8
-rw-r--r--tex/context/interface/keys-cz.xml8
-rw-r--r--tex/context/interface/keys-de.xml8
-rw-r--r--tex/context/interface/keys-en.xml8
-rw-r--r--tex/context/interface/keys-it.xml8
-rw-r--r--tex/context/interface/keys-nl.xml8
-rw-r--r--tex/context/interface/keys-ro.xml8
-rw-r--r--tex/context/sample/tufte.tex2
29 files changed, 753 insertions, 438 deletions
diff --git a/tex/context/base/context.tex b/tex/context/base/context.tex
index 60d538895..105fffb18 100644
--- a/tex/context/base/context.tex
+++ b/tex/context/base/context.tex
@@ -31,7 +31,7 @@
%D 2004.8.30 the low level interface is english. Watch out and adapt
%D your styles an modules.
-\def\contextversion{2005.08.19}
+\def\contextversion{2005.08.31}
%D Welcome to the main module. When this module is ran through
%D \type{initex} or \type {tex -i} or \type {whatevertex} using
diff --git a/tex/context/base/core-des.tex b/tex/context/base/core-des.tex
index 84a2d8d64..f2612be3d 100644
--- a/tex/context/base/core-des.tex
+++ b/tex/context/base/core-des.tex
@@ -29,21 +29,46 @@
% De macro \??dd#1\s!do\c!commando levert de koppeling tussen
% \doornumberen en \doordefinieren. Deze constructie is nodig
% omdat doornummeren geen argument heeft en omdat subnummers
-% niet worden genest binnen het hogere niveau. Het commando
-% \??dd#1\s!do\c!state moet in dat geval \v!start zijn.
+% niet worden genest binnen het hogere niveau.
%
% herimplementeren met \nextbox en \unhbox\unvbox
+% list and titles are experiental
+%
+% \definedescription[test] [location=left,hang=4,headalign={right},distance=1em,list=test]
+% \defineenumeration[lemma][title=yes,right=:,textdistance=1em, location=top, titlestyle=\bs,list=lemma]
+% \defineenumeration[ammel][title=yes,right=:,textdistance=.5em,location=left,titlestyle=\it,width=9em]
+%
+% \placelist[enumeration:lemma]
+% \placelist[description:test][width=0pt]
+%
+% \starttest {something something something} \input zapf \stoptest
+% \startlemma {with a title of a certain length} \input tufte \stoplemma
+% \startammel {with a title} \input zapf \stopammel
+%
+% \defineenumeration[lemma][...]
+% \defineenumeration[titledlemma][lemma][title=yes,right=:,text=lemma,list=lemma]
+
\newbox\@@descriptionbox
-\def\descriptionparameter #1{\csname\??dd\currentdescription#1\endcsname}
+\def\descriptionparameter #1{\csname\??dd\currentdescription#1\endcsname}
\def\@@descriptionhandler{\descriptionparameter{\s!do\c!command}}
+% \def\normal@@descriptionhandler[#1]#2#3%
+% {\doattributes
+% {\??dd\currentdescription}\c!headstyle\c!headcolor
+% {\descriptionparameter\c!command{#3}}% NAAR BUITENSTE NIVEAU !
+% \rawreference\s!def{#1}{#2}} % brrr moet in #4
+
\def\normal@@descriptionhandler[#1]#2#3%
{\doattributes
{\??dd\currentdescription}\c!headstyle\c!headcolor
{\descriptionparameter\c!command{#3}}% NAAR BUITENSTE NIVEAU !
+ \doifsomething{\descriptionparameter\c!list}
+ {\dowritetolist
+ {\descriptionparameter\c!type:\descriptionparameter\c!list}
+ {}{#2}{\currentdescription}}%
\rawreference\s!def{#1}{#2}} % brrr moet in #4
\setvalue{@@description\v!left}%
@@ -62,7 +87,7 @@
\next}
\def\@@descriptionleftpure[#1]#2%
- {\@@dostartdescription[#1]{#2}%
+ {\@@dostartdescription[#1]{\def\\{\crlf}}{#2}%
\noindent\ignorespaces
\leftskip\@@leftdescriptionskip
\rightskip\@@rightdescriptionskip
@@ -76,7 +101,7 @@
\@@dodescription}
\def\@@descriptionrightpure[#1]#2%
- {\@@dostartdescription[#1]{#2}%
+ {\@@dostartdescription[#1]{\def\\{\crlf}}{#2}%
\noindent\ignorespaces
\leftskip\@@leftdescriptionskip
\rightskip\@@rightdescriptionskip
@@ -103,7 +128,7 @@
\dp\@@descriptionbox\strutdp}
\def\@@descriptionlefthang[#1]#2%
- {\@@dostartdescription[#1]{#2}%
+ {\@@dostartdescription[#1]{\def\\{\crlf}}{#2}%
\dontcomplain
\advance\!!widtha \!!widthb
\hangindent\!!widtha
@@ -115,7 +140,7 @@
\@@dodescription}
\def\@@descriptionrighthang[#1]#2%
- {\@@dostartdescription[#1]{#2}%
+ {\@@dostartdescription[#1]{\def\\{\crlf}}{#2}%
\dontcomplain
\advance\!!widtha \!!widthb
\hangindent-\!!widtha
@@ -153,8 +178,8 @@
\setvalue{@@description\v!top}[#1]#2%
{%\page[\v!preference]% % Weg ermee!
%\dosomebreak{\goodbreak}% % Dit is beter en nodig!
- \dohandlepagebreakX\plusone % En dit moet het maar worden.
- \@@dostartdescription[#1]{\let\\=\space#2}%
+ \dohandlepagebreakX\plusone % En dit moet het maar worden.
+ \@@dostartdescription[#1]{\let\\=\space}{#2}%
\noindent\ignorespaces
\copy\@@descriptionbox\par
\nobreak
@@ -163,7 +188,7 @@
\@@dodescription}
\def\do@@description#1[#2]#3%
- {\@@dostartdescription[#2]{#3}%
+ {\@@dostartdescription[#2]{\def\\{\crlf}}{#3}%
\noindent\ignorespaces % not needed this ignore
#1{\ifhbox\@@descriptionbox\unhcopy\else\copy\fi\@@descriptionbox}%
\@@dodescription}
@@ -178,21 +203,21 @@
\setvalue{@@description\v!outermargin }{\do@@description\inouter }
\setvalue{@@description\v!serried\v!fit}[#1]#2%
- {\@@dostartdescription[#1]{#2}%
+ {\@@dostartdescription[#1]{\def\\{\crlf}}{#2}%
\noindent\ignorespaces
\ifhbox\@@descriptionbox\unhcopy\else\copy\fi\@@descriptionbox
\hskip\!!widthb % toegevoegd
\@@dodescription}
\setvalue{@@description\v!serried\v!broad}[#1]#2%
- {\@@dostartdescription[#1]{#2}%
+ {\@@dostartdescription[#1]{\def\\{\crlf}}{#2}%
\noindent\ignorespaces
\ifhbox\@@descriptionbox\unhcopy\else\copy\fi\@@descriptionbox
\hskip\!!widthb \!!plus .5\!!widthb \!!minus .25\!!widthb
\@@dodescription}
\setvalue{@@description\v!serried\v!wide}[#1]#2%
- {\@@dostartdescription[#1]{#2}%
+ {\@@dostartdescription[#1]{\def\\{\crlf}}{#2}%
\noindent\ignorespaces
\hbox to \!!widtha
{\ifhbox\@@descriptionbox\unhcopy\else\copy\fi\@@descriptionbox\hss}%
@@ -210,7 +235,7 @@
\getvalue{@@description\v!serried\next}[#1]{#2}}
\setvalue{@@description\v!hanging}[#1]#2%
- {\@@dostartdescription[#1]{#2}% % adds \c!margin to \leftskip
+ {\@@dostartdescription[#1]{\def\\{\crlf}}{#2}% % adds \c!margin to \leftskip
\noindent\ignorespaces
\advance\leftskip -\leftskipadaption \relax
\ifdim\leftskipadaption=\zeropoint
@@ -246,7 +271,7 @@
\let\@@leftdescriptionskip \!!zeropoint
\let\@@rightdescriptionskip\!!zeropoint
-\def\@@dostartdescription[#1]#2%
+\def\@@dostartdescription[#1]#2#3%
{\descriptionparameter\c!before
\begingroup
\doadaptleftskip{\descriptionparameter\c!margin}%
@@ -260,9 +285,8 @@
{\forgetall
\trialtypesettingtrue
\dontcomplain
- \def\\{\crlf}%
- \@@descriptionhandler[#1]{#2}%
- {\begstrut\descriptionparameter\c!text\ignorespaces#2\endstrut}}%
+ #2% sets \\ to space or \crlf
+ \@@descriptionhandler[#1]{#3}{\begstrut\descriptionparameter\c!text\ignorespaces#3\endstrut}}%
% so far
\assignwidth
\!!widtha
@@ -270,19 +294,16 @@
{\doifelsenothing{\descriptionparameter\c!sample}%
{% preroll can move here (test first)
\ifhbox\@@descriptionbox\unhcopy\else\copy\fi \@@descriptionbox}%
- {\@@descriptionhandler[#1]{#2}%
- {\descriptionparameter\c!text\descriptionparameter\c!sample}}}
+ {\@@descriptionhandler[#1]{#3}{\descriptionparameter\c!text\descriptionparameter\c!sample}}}
\!!widthb
\setbox\@@descriptionbox\hbox
{\forgetall
\dontcomplain
- \let\\\endgraf
+ #2% sets \\ to space or \crlf
\doifelse{\descriptionparameter\c!location}\v!serried
- {\@@descriptionhandler[#1]{#2}%
- {\begstrut\descriptionparameter\c!text#2\endstrut}}
- {\@@descriptionhandler[#1]{#2}%
- {\vtop{\hsize\!!widtha\advance\hsize-\!!widthb
- \begstrut\descriptionparameter\c!text\ignorespaces#2\endstrut}}}}%
+ {\@@descriptionhandler[#1]{#3}{\begstrut\descriptionparameter\c!text#3\endstrut}}
+ {\@@descriptionhandler[#1]{#3}{\vtop{\hsize\!!widtha\advance\hsize-\!!widthb
+ \begstrut\descriptionparameter\c!text\ignorespaces#3\endstrut}}}}%
\doifelse{\descriptionparameter\c!aligntitle}\v!no
{\edef\@@leftdescriptionskip {\the\leftskip }%
\edef\@@rightdescriptionskip{\the\rightskip}}
@@ -313,17 +334,29 @@
% starters:
+% \def\@@startdescription[#1][#2]%
+% {\def\currentdescription{#1}%
+% \doifelse{\descriptionparameter{\s!do\c!state}}\v!start
+% {\@@startsomedescription{#1}[#2]{}}
+% {\dowithwargument{\@@startsomedescription{#1}[#2]}}}
+%
+% \def\@@description[#1][#2]%
+% {\def\currentdescription{#1}%
+% \doifelse{\descriptionparameter{\s!do\c!state}}\v!start
+% {\@@somedescription{#1}[#2]{}}
+% {\dowithwargument{\@@somedescription{#1}[#2]}}}
+
\def\@@startdescription[#1][#2]%
{\def\currentdescription{#1}%
- \doifelse{\descriptionparameter{\s!do\c!state}}\v!start
- {\@@startsomedescription{#1}[#2]{}}
- {\dowithwargument{\@@startsomedescription{#1}[#2]}}}
+ \doifelse{\descriptionparameter\c!title}\v!yes
+ {\dowithwargument{\@@startsomedescription{#1}[#2]}}
+ {\@@startsomedescription{#1}[#2]{}}}
\def\@@description[#1][#2]%
{\def\currentdescription{#1}%
- \doifelse{\descriptionparameter{\s!do\c!state}}\v!start
- {\@@somedescription{#1}[#2]{}}
- {\dowithwargument{\@@somedescription{#1}[#2]}}}
+ \doifelse{\descriptionparameter\c!title}\v!yes
+ {\dowithwargument{\@@somedescription{#1}[#2]}}
+ {\@@somedescription{#1}[#2]{}}}
% these call:
@@ -365,248 +398,99 @@
\def\dodosetupdescriptions[#1]% [#2]%
{\getparameters[\??dd#1]} % [#2]}
+% \def\dodefinedescription[#1][#2]%
+% {\copyparameters[\??dd#1][\??dd]
+% [\c!location,\c!headstyle,\c!style,\c!color,\c!headcolor,
+% \c!width,\c!hang,\c!sample,\c!before,\c!inbetween,\c!after,\c!margin,
+% \c!indenting,\c!indentnext,\c!align,\c!text,\c!distance,\c!titledistance,\c!command]%
+% \getparameters[\??dd#1]
+% [\s!do\c!state=\v!stop,\s!do\c!command=\normal@@descriptionhandler,\c!level=,#2]%
+% %\doifvalue{\??dd#1\c!location}\v!top{\doassign[\??dd#1][\c!inbetween=\blank]}%
+% \doifvalue{\??dd#1\c!location}\v!top % we actually need more granularity
+% {\doifnotvalue{\??dd#1\c!inbetween}{\doassign[\??dd#1][\c!inbetween=\blank]}}%
+% \setvalue {#1}{\dodoubleempty\@@description[#1]}%
+% \setvalue{\e!start#1}{\dodoubleempty\@@startdescription[#1]}%
+% \setvalue{\e!stop #1}{\@@stopdescription{#1}}}%
+
\def\dodefinedescription[#1][#2]%
{\copyparameters[\??dd#1][\??dd]
[\c!location,\c!headstyle,\c!style,\c!color,\c!headcolor,
\c!width,\c!hang,\c!sample,\c!before,\c!inbetween,\c!after,\c!margin,
- \c!indenting,\c!indentnext,\c!align,\c!text,\c!distance,\c!command]%
+ \c!indenting,\c!indentnext,\c!align,\c!text,\c!distance,\c!titledistance,\c!command]%
\getparameters[\??dd#1]
- [\s!do\c!state=\v!stop,\s!do\c!command=\normal@@descriptionhandler,\c!level=,#2]%
-% \doifvalue{\??dd#1\c!location}\v!top{\doassign[\??dd#1][\c!inbetween=\blank]}%
+ [\c!title=\v!yes,\s!do\c!command=\normal@@descriptionhandler,
+ \c!type=\v!description,\c!list=,\c!listtext=,
+ \c!level=,#2]%
+ %\doifvalue{\??dd#1\c!location}\v!top{\doassign[\??dd#1][\c!inbetween=\blank]}%
\doifvalue{\??dd#1\c!location}\v!top % we actually need more granularity
{\doifnotvalue{\??dd#1\c!inbetween}{\doassign[\??dd#1][\c!inbetween=\blank]}}%
+ \doifvaluesomething{\??dd#1\c!list}
+ {\definelist[\getvalue{\??dd#1\c!type}:\getvalue{\??dd#1\c!list}]}% new
\setvalue {#1}{\dodoubleempty\@@description[#1]}%
\setvalue{\e!start#1}{\dodoubleempty\@@startdescription[#1]}%
- \setvalue{\e!stop #1}{\@@stopdescription{#1}}}%
+ \setvalue{\e!stop #1}{\@@stopdescription{#1}}}
\def\definedescription
{\dodoubleemptywithset\dodefinedescription}
-% voorlopig handhaven ! ! ! !
-%
-% \def\showdnpuretext#1%
-% {\strut\getvalue{\??dd#1\c!text}} % geen spatie
-%
-% \def\showdntext#1%
-% {\doifelsevaluenothing{\??dd#1\c!text}
-% {\ignorespaces}
-% {\strut
-% \getvalue{\??dd#1\c!text}%
-% \removeunwantedspaces\fixedspace}}
-%
-% \def\showdnnumber#1%
-% {\preparednumber
-% \convertednumber[\getvalue{\??dd#1\??dd\c!number}]}
-%
-% \def\showdnsubnumber#1%
-% {\showdnnumber{#1}%
-% \getvalue{\??dd#1\c!separator}%
-% \convertednumber[\v!sub\getvalue{\??dd#1\??dd\c!number}]}
-%
-% \def\showdnsubsubnumber#1%
-% {\showdnsubnumber{#1}%
-% \getvalue{\??dd#1\c!separator}%
-% \convertednumber[\v!sub\v!sub\getvalue{\??dd#1\??dd\c!number}]}
-%
-% \def\showdnsubsubsubnumber#1%
-% {\showdnsubsubnumber{#1}%
-% \getvalue{\??dd#1\c!separator}%
-% \convertednumber[\v!sub\v!sub\v!sub\getvalue{\??dd#1\??dd\c!number}]}
-%
-% \def\domakednnumber#1#2#3%
-% {\getvalue{\??dd#2#1\c!left}%
-% \strut#3{#1}%
-% \getvalue{\??dd#2#1\c!stopper}%
-% \getvalue{\??dd#2#1\c!right}}
-%
-% \def\special@@descriptionhandler#1#2#3#4[#5]#6#7%
+\def\currentdescriptionnumber
+ {\csname\??dd\currentdescription\??dd\c!number\endcsname}
+
+% \def\special@@descriptionhandler[#1]#2#3%
% {\strut
-% \doifelsevalue{\??dd#1\c!number}\v!no
-% \!!doneafalse{\doifelse{#5}{-}\!!doneafalse\!!doneatrue}%
+% \doifelse{\descriptionparameter\c!number}\v!no
+% \!!doneafalse{\doifelse{#1}{-}\!!doneafalse\!!doneatrue}%
% \chardef\descriptioncoupling\zerocount
% \iflocation
-% \doifvaluesomething{\??dd#1\c!coupling}
+% \doifsomething{\descriptionparameter\c!coupling}
% {\processaction % genereert > of <
-% [\getvalue{\??dd#1\c!couplingway}]
+% [\descriptionparameter\c!couplingway]
% [ \v!local=>\chardef\descriptioncoupling\plusone, % old: default
% \v!global=>\chardef\descriptioncoupling\plustwo]}% new: global crosslinking
% \fi
% \setupnumber % the number is called indirectly
-% [\getvalue{\??dd#1\??dd\c!number}]
-% [\c!sectionnumber=\getvalue{\??dd#1\c!sectionnumber}]%
+% [\currentdescriptionnumber]
+% [\c!sectionnumber=\descriptionparameter\c!sectionnumber]%
% \if!!donea
-% \makeprecedingsectionnumber[\getvalue{\??dd#1\??dd\c!number}]%
-% \preparethenumber{\??dd#1}\precedingsectionnumber\preparednumber
+% \makeprecedingsectionnumber[\currentdescriptionnumber]%
+% \preparethenumber{\??dd\currentdescription}\precedingsectionnumber\preparednumber
% \iftrialtypesetting\startlocal\fi
-% \getvalue{\e!next#2#1}% tricky but we need the preroll
+% \getvalue{\e!next\currentdescription}% tricky but we need the preroll
% \iftrialtypesetting\stoplocal\fi
% % \getvalue{\e!next#2#1}%
% \iflocation
% \bgroup
-% \letvalue{\??dd#1\c!sectionnumber}\v!yes
+% \letvalue{\??dd\currentdescription\c!sectionnumber}\v!yes
% \protectconversion
-% \makeprecedingsectionnumber[\getvalue{\??dd#1\??dd\c!number}]%
-% \preparethenumber{\??dd#1}\precedingsectionnumber\preparednumber
+% \makeprecedingsectionnumber[\currentdescriptionnumber]%
+% \preparethenumber{\??dd\currentdescription}\precedingsectionnumber\preparednumber
% \ifcase\descriptioncoupling \or
-% \xdef\@@internalenumber{#3{#1}}%
+% \xdef\@@internalenumber{\doshowdnnumber}%
% \rawreference\s!num{#1:\@@internalenumber}{}%
% \or
-% \xdef\@@internalenumber{\countervalue{\??dd\c!coupling#1}}%
-% \rawreference\s!num{#1:\@@internalenumber}{}%
+% \xdef\@@internalenumber{\countervalue{\??dd\c!coupling\currentdescription}}%
+% \rawreference\s!num{\currentdescription:\@@internalenumber}{}%
% \fi
% \egroup
% \fi
-% \makeprecedingsectionnumber[\getvalue{\??dd#1\??dd\c!number}]%
-% \preparethenumber{\??dd#1}\precedingsectionnumber\preparednumber
-% \disablepseudocaps % sorry, uppercase causes troubles
-% \doattributes % \nocase primitive needed
-% {\??dd#1}\c!headstyle\c!headcolor
-% {\getvalue{\??dd#1\c!command}% hook for taco
-% {\showdntext{#2#1}%
-% \domakednnumber{#1}{#2}{#3}}}%
+% %\makeprecedingsectionnumber[\currentdescriptionnumber]%
+% %\preparethenumber{\??dd\currentdescription}\precedingsectionnumber\preparednumber
+% \disablepseudocaps % sorry, uppercase causes troubles
+% \doattributes % \nocase primitive needed
+% {\??dd\currentdescription}\c!headstyle\c!headcolor % todo: sub as well
+% {\descriptionparameter\c!command{\showdntext\domakednnumber}}% hook for taco
% \iflocation\ifcase\descriptioncoupling \else
-% \edef\localconnection{\getvalue{\??dd#1\c!coupling}:\@@internalenumber}%
+% \edef\localconnection{\descriptionparameter\c!coupling:\@@internalenumber}%
% \doifreferencefoundelse\localconnection
% {\in[\localconnection]}\donothing % genereert > of <
% \fi\fi
-% \doifnot{#5}{-}{\rawreference\s!num{#5}{#3{#1}}}%
+% \doifnot{#1}{-}{\rawreference\s!num{#1}{\doshowdnnumber}}%
% \else % Why was this strange expansion needed?
-% \edef\!!stringa{\showdnpuretext{#2#1}}% nog eens testen binnen \expanded
-% \expanded{\doattributes{\??dd#1}\noexpand\c!headstyle\noexpand\c!headcolor
-% {\noexpand\getvalue{\??dd#1\c!command}{\!!stringa}}}%
-% \doifnot{#5}{-}{\rawreference\s!num{#5}{}}%
+% \edef\!!stringa{\showdnpuretext}% nog eens testen binnen \expanded
+% \expanded{\doattributes{\??dd\currentdescription}\noexpand\c!headstyle\noexpand\c!headcolor
+% {\noexpand\descriptionparameter\noexpand\c!command{\!!stringa}}}%
+% \doifnot{#1}{-}{\rawreference\s!num{#1}{}}%
% \fi}
-%
-% \setvalue{\??dd\s!set\v!sub\s!sub\s!sub\c!number}#1%
-% {\edef\@@descriptionnumber{\getvalue{\??dd#1\??dd\c!number}}%
-% \setnumber[\v!sub\v!sub\v!sub\@@descriptionnumber]}
-%
-% \setvalue{\??dd\s!set\v!sub\s!sub\c!number}#1%
-% {\getvalue{\??dd\s!reset\v!sub\v!sub\v!sub\c!number}{#1}%
-% \setnumber[\v!sub\v!sub\@@descriptionnumber]}
-%
-% \setvalue{\??dd\s!set\v!sub\c!number}#1%
-% {\getvalue{\??dd\s!reset\v!sub\v!sub\c!number}{#1}%
-% \setnumber[\v!sub\@@descriptionnumber]}
-%
-% \setvalue{\??dd\s!set\c!number}#1%
-% {\getvalue{\??dd\s!reset\v!sub\c!number}{#1}%
-% \setnumber[\@@descriptionnumber]}
-%
-% \setvalue{\??dd\s!reset\v!sub\v!sub\v!sub\c!number}#1%
-% {\edef\@@descriptionnumber{\getvalue{\??dd#1\??dd\c!number}}%
-% \resetnumber[\v!sub\v!sub\v!sub\@@descriptionnumber]}
-%
-% \setvalue{\??dd\s!reset\v!sub\v!sub\c!number}#1%
-% {\getvalue{\??dd\s!reset\v!sub\v!sub\v!sub\c!number}{#1}%
-% \resetnumber[\v!sub\v!sub\@@descriptionnumber]}
-%
-% \setvalue{\??dd\s!reset\v!sub\c!number}#1%
-% {\getvalue{\??dd\s!reset\v!sub\v!sub\c!number}{#1}%
-% \resetnumber[\v!sub\@@descriptionnumber]}
-%
-% \setvalue{\??dd\s!reset\c!number}#1%
-% {\getvalue{\??dd\s!reset\v!sub\c!number}{#1}%
-% \resetnumber[\@@descriptionnumber]}
-%
-% \setvalue{\??dd\e!next\v!sub\v!sub\v!sub\c!number}[#1][#2]%
-% {\edef\@@descriptionnumber{\getvalue{\??dd#1\??dd\c!number}}%
-% \incrementnumber[\v!sub\v!sub\v!sub\@@descriptionnumber]%
-% \rawreference\s!num{#2}{\showdnsubsubsubnumber{\@@descriptionnumber}}}%
-%
-% \setvalue{\??dd\e!next\v!sub\v!sub\c!number}[#1][#2]%
-% {\getvalue{\??dd\s!reset\v!sub\v!sub\v!sub\c!number}{#1}%
-% \incrementnumber[\v!sub\v!sub\@@descriptionnumber]%
-% \rawreference\s!num{#2}{\showdnsubsubnumber{\@@descriptionnumber}}}
-%
-% \setvalue{\??dd\e!next\v!sub\c!number}[#1][#2]%
-% {\getvalue{\??dd\s!reset\v!sub\v!sub\c!number}{#1}%
-% \incrementnumber[\v!sub\@@descriptionnumber]%
-% \rawreference\s!num{#2}{\showdnsubnumber{\@@descriptionnumber}}}
-%
-% \setvalue{\??dd\e!next\c!number}[#1][#2]%
-% {\getvalue{\??dd\s!reset\v!sub\c!number}{#1}%
-% \incrementnumber[\@@descriptionnumber]%
-% \rawreference\s!num{#2}{\showdnnumber{\@@descriptionnumber}}}
-%
-% \def\dodosetupenumerations[#1][#2]%
-% {\getparameters[\??dd#1][#2]%
-% \doifdefined{\??dd#1\c!start}
-% {\setupnumber[#1][\c!start=\getvalue{\??dd#1\c!start}]}%
-% \setupnumber[#1][\c!conversion=\getvalue{\??dd#1\c!conversion}]}
-%
-% \def\dosetupenumerations[#1][#2]%
-% {\ConvertToConstant\doifelse{#2}{}
-% {\getparameters[\??dn][#1]}
-% {\dodoubleargumentwithset\dodosetupenumerations[#1][#2]}}
-%
-% \def\setupenumerations
-% {\dodoubleempty\dosetupenumerations}
-%
-% \def\dododefineenumeration#1#2#3[#4][#5]#6%
-% {\makecounter{\??dd\c!coupling#1}% new: global cross linking
-% \dodefinedescription[#3#1]%
-% [\s!do\c!state=\v!start,
-% \s!do\c!command=\special@@descriptionhandler{#1}{#3}{#6}]%
-% \copyparameters[\??dd#3#1][\??dn]
-% [\c!location,\c!headstyle,\c!style,\c!color,\c!headcolor,
-% \c!width,\c!number,\c!distance,\c!command,
-% \c!sample,\c!hang,\c!align,\c!before,\c!inbetween,\c!after,
-% \c!levels,\c!way,\c!blockway,\c!separator,\c!margin,
-% \c!indenting,\c!indentnext,\c!stopper,\c!sectionnumber,
-% \c!number]%
-% \doifassignmentelse{#4}
-% {\getparameters[\??dd#3#1]%
-% [\c!text=#1,\??dd\c!number=#1,\c!conversion=,
-% \c!left=,\c!right=,\c!coupling=,\c!couplingway=\v!local,#4]}%
-% {\doifelsenothing{#4}
-% {\getparameters[\??dd#3#1]%
-% [\c!text=#1,\??dd\c!number=#1,\c!conversion=,
-% \c!stopper=,
-% \c!left=,\c!right=,\c!coupling=,\c!couplingway=,#4]}%
-% {\copyparameters[\??dd#3#1][\??dd#3#4]
-% [\c!location,\c!headstyle,\c!style,\c!color,\c!headcolor,
-% \c!width,\c!number,\c!distance,\c!command,\c!margin,
-% \c!sample,\c!hang,\c!align,\c!before,\c!inbetween,\c!after,
-% \c!stopper,\c!indenting,\c!indentnext,\c!left,\c!right,
-% \c!coupling,\c!couplingway]%
-% \getparameters[\??dd#3#1]
-% [\c!text=#1,\??dd\c!number=#4,\c!conversion=,#5]}}%
-% \doifvalue{\??dd#3#1\??dd\c!number}{#1}
-% {\definenumber
-% [#3#1]
-% [\c!way=\getvalue{\??dd#1\c!way},
-% \c!blockway=\getvalue{\??dd#1\c!blockway},
-% \c!sectionnumber=\getvalue{\??dd#1\c!sectionnumber}]%
-% \doifvalue{\??dd#1\c!levels}{#2}% % for
-% {\doifsomething{\getvalue{\??dd#1\c!conversion}}% % old
-% {\setupnumber[#3#1] % times
-% [\c!conversion=\getvalue{\??dd#1\c!conversion}]}}}% % sake
-% \setvalue{\s!set #3#1}{\dosetenumerationnumber[#1][#3]}%
-% \setvalue{\s!reset#3#1}{\doresetenumerationnumber[#1][#3]}%
-% \setvalue{\e!next #3#1}{\dotripleempty\donextenumerationnumber[#1][#3]}}
-%
-% \def\doresetenumerationnumber[#1][#2]%
-% {\getvalue{\??dd\s!reset#2\c!number}{#1}}%
-%
-% \def\dosetenumerationnumber[#1][#2]%
-% {\getvalue{\??dd\s!set#2\c!number}{#1}}%
-%
-% \def\donextenumerationnumber[#1][#2]%
-% {\pluscounter{\??dd\c!coupling#1}% new: global crosslinking
-% \getvalue{\??dd\e!next#2\c!number}[#1]}%
-%
-% \def\dodefineenumeration[#1][#2][#3]%
-% {\dododefineenumeration{#1}{1}{}[#2][#3]\showdnnumber
-% \dododefineenumeration{#1}{2}{\v!sub}[#2][#3]\showdnsubnumber
-% \dododefineenumeration{#1}{3}{\v!sub\v!sub}[#2][#3]\showdnsubsubnumber
-% \dododefineenumeration{#1}{4}{\v!sub\v!sub\v!sub}[#2][#3]\showdnsubsubsubnumber}
-%
-% \def\defineenumeration
-% {\dotripleemptywithset\dodefineenumeration}
-
-\def\currentdescriptionnumber
- {\csname\??dd\currentdescription\??dd\c!number\endcsname}
\def\special@@descriptionhandler[#1]#2#3%
{\strut
@@ -624,10 +508,10 @@
[\currentdescriptionnumber]
[\c!sectionnumber=\descriptionparameter\c!sectionnumber]%
\if!!donea
-\makeprecedingsectionnumber[\currentdescriptionnumber]%
-\preparethenumber{\??dd\currentdescription}\precedingsectionnumber\preparednumber
+ \makeprecedingsectionnumber[\currentdescriptionnumber]%
+ \preparethenumber{\??dd\currentdescription}\precedingsectionnumber\preparednumber
\iftrialtypesetting\startlocal\fi
-\getvalue{\e!next\currentdescription}% tricky but we need the preroll
+ \getvalue{\e!next\currentdescription}% tricky but we need the preroll
\iftrialtypesetting\stoplocal\fi
% \getvalue{\e!next#2#1}%
\iflocation
@@ -645,19 +529,29 @@
\fi
\egroup
\fi
-% \makeprecedingsectionnumber[\currentdescriptionnumber]%
-% \preparethenumber{\??dd\currentdescription}\precedingsectionnumber\preparednumber
+ %\makeprecedingsectionnumber[\currentdescriptionnumber]%
+ %\preparethenumber{\??dd\currentdescription}\precedingsectionnumber\preparednumber
\disablepseudocaps % sorry, uppercase causes troubles
\doattributes % \nocase primitive needed
{\??dd\currentdescription}\c!headstyle\c!headcolor % todo: sub as well
- {\descriptionparameter\c!command{\showdntext\domakednnumber}}% hook for taco
+ {\descriptionparameter\c!command
+ {\showdntext
+ \domakednnumber
+ \doif{\descriptionparameter\c!title}\v!yes % new, for david antos
+ {\doattributes{\??dd\currentdescription}\c!titlestyle\c!titlecolor
+ {\hskip\descriptionparameter\c!titledistance\begstrut#2\endstrut}}%
+ }}% \c!command is hook for taco
+ \doifsomething{\descriptionparameter\c!list} % also for david antos
+ {\dowritetolist
+ {\descriptionparameter\c!type:\descriptionparameter\c!list}
+ {\showdnlisttext\doshowdnnumber}{#2}{\currentdescription}}%
\iflocation\ifcase\descriptioncoupling \else
\edef\localconnection{\descriptionparameter\c!coupling:\@@internalenumber}%
\doifreferencefoundelse\localconnection
{\in[\localconnection]}\donothing % genereert > of <
\fi\fi
\doifnot{#1}{-}{\rawreference\s!num{#1}{\doshowdnnumber}}%
- \else % Why was this strange expansion needed?
+ \else % Why was this strange expansion needed?
\edef\!!stringa{\showdnpuretext}% nog eens testen binnen \expanded
\expanded{\doattributes{\??dd\currentdescription}\noexpand\c!headstyle\noexpand\c!headcolor
{\noexpand\descriptionparameter\noexpand\c!command{\!!stringa}}}%
@@ -667,6 +561,9 @@
\def\showdnpuretext
{\strut\descriptionparameter\c!text} % geen spatie
+\def\showdnlisttext
+ {\descriptionparameter\c!listtext} % space in default
+
\def\showdntext
{\doifelsenothing{\descriptionparameter\c!text}
{\ignorespaces}
@@ -770,21 +667,64 @@
\def\setupenumerations
{\dodoubleempty\dosetupenumerations}
+% \def\dododefineenumeration#1#2#3[#4][#5]%
+% {\makecounter{\??dd\c!coupling#1}% new: global cross linking
+% \dodefinedescription[#3#1]%
+% [\s!do\c!state=\v!start,\c!level=#3,
+% \s!do\c!command=\special@@descriptionhandler]%
+% \copyparameters[\??dd#3#1][\??dn]
+% [\c!location,\c!headstyle,\c!style,\c!color,\c!headcolor,
+% \c!width,\c!number,\c!distance,\c!command,
+% \c!sample,\c!hang,\c!align,\c!before,\c!inbetween,\c!after,
+% \c!levels,\c!way,\c!blockway,\c!separator,\c!margin,
+% \c!indenting,\c!indentnext,\c!stopper,\c!sectionnumber,
+% \c!number]%
+% \doifassignmentelse{#4}
+% {\getparameters[\??dd#3#1]%
+% [\c!text=#1,\??dd\c!number=#1,\c!conversion=,
+% \c!left=,\c!right=,\c!coupling=,\c!couplingway=\v!local,#4]}%
+% {\doifelsenothing{#4}
+% {\getparameters[\??dd#3#1]%
+% [\c!text=#1,\??dd\c!number=#1,\c!conversion=,
+% \c!stopper=,
+% \c!left=,\c!right=,\c!coupling=,\c!couplingway=,#4]}%
+% {\copyparameters[\??dd#3#1][\??dd#3#4]
+% [\c!location,\c!headstyle,\c!style,\c!color,\c!headcolor,
+% \c!width,\c!number,\c!distance,\c!command,\c!margin,
+% \c!sample,\c!hang,\c!align,\c!before,\c!inbetween,\c!after,
+% \c!stopper,\c!indenting,\c!indentnext,\c!left,\c!right,
+% \c!coupling,\c!couplingway]%
+% \getparameters[\??dd#3#1]
+% [\c!text=#1,\??dd\c!number=#4,\c!conversion=,#5]}}%
+% \doifvalue{\??dd#3#1\??dd\c!number}{#1}
+% {\definenumber
+% [#3#1]
+% [\c!way=\descriptionparentparameter\c!way,
+% \c!blockway=\descriptionparentparameter\c!blockway,
+% \c!sectionnumber=\descriptionparentparameter\c!sectionnumber]%
+% \doifvalue{\??dd#1\c!levels}{#2}% % for
+% {\doifsomething{\getvalue{\??dd#1\c!conversion}}% % old
+% {\setupnumber[#3#1] % times
+% [\c!conversion=\descriptionparameter\c!conversion]}}}% % sake
+% \setvalue{\s!set #3#1}{\dosetenumerationnumber[#1][#3]}%
+% \setvalue{\s!reset#3#1}{\doresetenumerationnumber[#1][#3]}%
+% \setvalue{\e!next #3#1}{\dotripleempty\donextenumerationnumber[#1][#3]}}
+
\def\dododefineenumeration#1#2#3[#4][#5]%
{\makecounter{\??dd\c!coupling#1}% new: global cross linking
\dodefinedescription[#3#1]%
- [\s!do\c!state=\v!start,\c!level=#3,
+ [\c!title=\v!no,\c!level=#3,\c!type=\v!enumeration,\c!list=,%
\s!do\c!command=\special@@descriptionhandler]%
\copyparameters[\??dd#3#1][\??dn]
[\c!location,\c!headstyle,\c!style,\c!color,\c!headcolor,
- \c!width,\c!number,\c!distance,\c!command,
+ \c!width,\c!number,\c!distance,\c!titledistance,\c!command,
\c!sample,\c!hang,\c!align,\c!before,\c!inbetween,\c!after,
\c!levels,\c!way,\c!blockway,\c!separator,\c!margin,
\c!indenting,\c!indentnext,\c!stopper,\c!sectionnumber,
\c!number]%
\doifassignmentelse{#4}
{\getparameters[\??dd#3#1]%
- [\c!text=#1,\??dd\c!number=#1,\c!conversion=,
+ [\c!text=#1,\??dd\c!number=#1,\c!conversion=,\c!listtext=#1\space,
\c!left=,\c!right=,\c!coupling=,\c!couplingway=\v!local,#4]}%
{\doifelsenothing{#4}
{\getparameters[\??dd#3#1]%
@@ -793,7 +733,7 @@
\c!left=,\c!right=,\c!coupling=,\c!couplingway=,#4]}%
{\copyparameters[\??dd#3#1][\??dd#3#4]
[\c!location,\c!headstyle,\c!style,\c!color,\c!headcolor,
- \c!width,\c!number,\c!distance,\c!command,\c!margin,
+ \c!width,\c!number,\c!distance,\c!titledistance,\c!command,\c!margin,
\c!sample,\c!hang,\c!align,\c!before,\c!inbetween,\c!after,
\c!stopper,\c!indenting,\c!indentnext,\c!left,\c!right,
\c!coupling,\c!couplingway]%
@@ -809,6 +749,8 @@
{\doifsomething{\getvalue{\??dd#1\c!conversion}}% % old
{\setupnumber[#3#1] % times
[\c!conversion=\descriptionparameter\c!conversion]}}}% % sake
+ \doifvaluesomething{\??dd#3#1\c!list}
+ {\definelist[\getvalue{\??dd#3#1\c!type}:\getvalue{\??dd#3#1\c!list}]}% new
\setvalue{\s!set #3#1}{\dosetenumerationnumber[#1][#3]}%
\setvalue{\s!reset#3#1}{\doresetenumerationnumber[#1][#3]}%
\setvalue{\e!next #3#1}{\dotripleempty\donextenumerationnumber[#1][#3]}}
@@ -946,6 +888,7 @@
\c!headcolor=,
\c!width=8em,
\c!distance=0pt,
+ \c!titledistance=0pt,
\c!hang=,
\c!sample=,
\c!align=,
@@ -965,6 +908,7 @@
\c!color=,
\c!width=8em,
\c!distance=0pt,
+ \c!titledistance=0pt,
\c!hang=,
\c!sample=,
\c!align=,
diff --git a/tex/context/base/core-int.tex b/tex/context/base/core-int.tex
index e08644ea9..44d4fa778 100644
--- a/tex/context/base/core-int.tex
+++ b/tex/context/base/core-int.tex
@@ -721,7 +721,7 @@
% \fi
% \if!!donea
% \ifcase\csname\??am\??am\csname#1\c!samepage\endcsname\endcsname\relax
-% \copycsname#1\c!color\endcsname\csname#1\c!contrastkleur\endcsname
+% \copycsname#1\c!color\endcsname\csname#1\c!contrastcolor\endcsname
% \@EAEAEA\dosetlocationboxyes
% \or
% \@EAEAEA\dosetlocationboxempty
@@ -1396,7 +1396,7 @@
\newbox\meterbox
-\newif\ifbalksymbool
+\newif\ifbarsymbol
\def\doganaareenpagina#1#2#3% nog checken !
{\checkreferences % nodig ??
@@ -1532,7 +1532,7 @@
\bgroup
%\setupinteraction[\c!width=\!!zeropoint]%
\setinteractionparameter\c!width\!!zeropoint
- \ifbalksymbool % beter: 3 chars assign en 3*box
+ \ifbarsymbol % beter: 3 chars assign en 3*box
\setupsymbolset[\@@iasymbolset]%
\setbox0\hbox{\symbol[\v!previous]}%
\setbox2\hbox{\symbol[\v!somewhere]}%
@@ -1586,7 +1586,7 @@
\noindent
\hbox to \@@ibwidth
\bgroup
- \ifbalksymbool
+ \ifbarsymbol
\setupsymbolset[\@@iasymbolset]%
\setbox0\hbox{\symbol[\v!previous]}%
\setbox2\hbox{\symbol[\v!somewhere]}%
@@ -1652,7 +1652,7 @@
\advance\!!widtha \@@ibwidth
\advance\!!countc \plusone
\divide\!!widtha \!!countc
- \ifbalksymbool
+ \ifbarsymbol
\setupsymbolset[\@@iasymbolset]%
\setbox0\hbox{\symbol[\v!previous]}%
\setbox4\hbox{\symbol[\v!somewhere]}%
@@ -1748,7 +1748,7 @@
\s!default=>\checkinteractionbar{10em}\v!broad\!!zeropoint,
\s!unknown=>\checkinteractionbar{10em}\v!broad\!!zeropoint]%
\doifelse\@@ibsymbol\v!yes
- \balksymbooltrue\balksymboolfalse
+ \barsymboltrue\barsymbolfalse
\getvalue{interactionbar\@@ibalternative}%
\stopinteraction}%
\fi
@@ -2308,7 +2308,7 @@
% \useattachment[whatever][newname][test.tex]
% \useattachment[whatever][title][newname][test.tex]
%
-% % \setupattachments[\c!symbool={symbol-normal,symbol-down}]
+% % \setupattachments[\c!symbol={symbol-normal,symbol-down}]
%
% \starttext \attachment[whatever] \stoptext
@@ -2351,7 +2351,7 @@
\doifundefined{\??at:#2}
{\showmessage\m!interactions6{#2}%
\useattachment[#2]}%
- \doif\@@atstatus\v!start
+ \doif\@@atstate\v!start
{\bgroup
\getattachmentdata[#2]%
\doiffileelse\attachmentfile
@@ -2360,7 +2360,7 @@
\struttedbox{\tbox{%
\doattachfile
\attachmenttitle
- {1em}\strutheight\strutdepth\@@atkleur\@@atsymbool
+ {1em}\strutheight\strutdepth\@@atcolor\@@atsymbol
\attachmentname
\attachmentfile}%
}}%
@@ -2372,7 +2372,7 @@
\fi}
\def\presetattachmentvariables
- {\let\@@DriverAttachmentLayer\@@attekstlaag}
+ {\let\@@DriverAttachmentLayer\@@attextlayer}
\def\setupattachments
{\dodoubleempty\getparameters[\??at]}
diff --git a/tex/context/base/core-lst.tex b/tex/context/base/core-lst.tex
index a93954fe0..d3a5ebdb4 100644
--- a/tex/context/base/core-lst.tex
+++ b/tex/context/base/core-lst.tex
@@ -601,7 +601,7 @@
\!!widtha\zeropoint
\!!widthc\zeropoint
\setbox2\hbox{}%
-}
+}%
\setbox4\hbox
{\doif{\listparameter\c!pagenumber}\v!yes
{\doifsomething{#5} % \listwidth is new ; temp hack
@@ -979,7 +979,7 @@
{\getparameters[\??ih#1][#2]%
\expanded{\setuplist[\getvalue{\??ih#1\c!list}]}[#2]}
-\def\setupcombinedlist%
+\def\setupcombinedlist
{\dodoubleargument\dosetupcombinedlist}
\def\doplacecombinedlist[#1][#2]%
@@ -995,14 +995,17 @@
\getfromcommacommand[\combinedlist][\!!counta]%
\edef\maximumlist{\commalistelement}}%
{\edef\maximumlist{\getvalue{\??ih#1\c!level}}}%
- \!!counta\getvalue{\??se\getvalue{\??ko\maximumlist\c!section}\c!level}}%
+ \doifdefinedelse{\??ko\maximumlist\c!section}
+ {\!!counta\getvalue{\??se\getvalue{\??ko\maximumlist\c!section}\c!level}}%
+ {\!!counta\zerocount}}
\let\!!stringa\combinedlist
\let\combinedlist\empty
\def\docommand##1%
- {\ifnum\getvalue{\??se\getvalue{\??ko##1\c!section}\c!level}>\!!counta
- \else
- \addtocommalist{##1}\combinedlist
- \fi}%
+ {\doifdefinedelse{\??ko##1\c!section}
+ {\ifnum\getvalue{\??se\getvalue{\??ko##1\c!section}\c!level}>\!!counta\else
+ \addtocommalist{##1}\combinedlist
+ \fi}%
+ {\addtocommalist{##1}\combinedlist}}%
\processcommacommand[\!!stringa]\docommand
\doifvalue{\??ih#1\c!coupling}\v!on
{\startlistreferences{#1}}%
diff --git a/tex/context/base/core-new.tex b/tex/context/base/core-new.tex
index ffaa98214..71be6466a 100644
--- a/tex/context/base/core-new.tex
+++ b/tex/context/base/core-new.tex
@@ -131,9 +131,15 @@
\def\enablemode {\unprotect\doenablemode }
\def\disablemode{\unprotect\dodisablemode}
-\def\dopreventmode[#1]{\protect\rawprocesscommalist[#1]\dodopreventmode}
-\def\doenablemode [#1]{\protect\rawprocesscommalist[#1]\dodoenablemode }
-\def\dodisablemode[#1]{\protect\rawprocesscommalist[#1]\dododisablemode}
+% \def\dopreventmode[#1]{\protect\rawprocesscommalist[#1]\dodopreventmode}
+% \def\doenablemode [#1]{\protect\rawprocesscommalist[#1]\dodoenablemode }
+% \def\dodisablemode[#1]{\protect\rawprocesscommalist[#1]\dododisablemode}
+%
+% better:
+
+\def\dopreventmode[#1]{\protect\cleanuplabel{#1}\rawprocesscommalist[\cleanlabel]\dodopreventmode}
+\def\doenablemode [#1]{\protect\cleanuplabel{#1}\rawprocesscommalist[\cleanlabel]\dodoenablemode }
+\def\dodisablemode[#1]{\protect\cleanuplabel{#1}\rawprocesscommalist[\cleanlabel]\dododisablemode}
\def\dodopreventmode#1%
{\@EA\let\csname\@mode@#1\endcsname\preventedmode}
@@ -155,16 +161,30 @@
\def\dodocheckformode#1%
{\ifcase0\csname\@mode@#1\endcsname\or\checkedmodetrue\fi}
+% \def\docheckformode#1#2#3% will be sped up with a quit
+% {\protect\checkedmodefalse\rawprocesscommalist[#3]\dodocheckformode
+% \ifcheckedmode\@EA#1\else\@EA#2\fi}
+%
+% better:
+
\def\docheckformode#1#2#3% will be sped up with a quit
- {\protect\checkedmodefalse\rawprocesscommalist[#3]\dodocheckformode
+ {\cleanuplabel{#3}%
+ \protect\checkedmodefalse\rawprocesscommacommand[\cleanlabel]\dodocheckformode
\ifcheckedmode\@EA#1\else\@EA#2\fi}
\def\dodocheckforallmodes#1%
{\ifcase0\csname\@mode@#1\endcsname\relax
\checkedmodefalse\or\or\checkedmodefalse\fi}
+% \def\docheckforallmodes#1#2#3% will be sped up with a quit
+% {\protect\checkedmodetrue\rawprocesscommalist[#3]\dodocheckforallmodes
+% \ifcheckedmode\@EA#1\else\@EA#2\fi}
+%
+% better:
+
\def\docheckforallmodes#1#2#3% will be sped up with a quit
- {\protect\checkedmodetrue\rawprocesscommalist[#3]\dodocheckforallmodes
+ {\cleanuplabel{#3}%
+ \protect\checkedmodetrue\rawprocesscommacommand[\cleanlabel]\dodocheckforallmodes
\ifcheckedmode\@EA#1\else\@EA#2\fi}
% simple ones
@@ -284,9 +304,15 @@
\unexpanded \def\setups{\doifnextcharelse\bgroup\dosetupsA\dosetupsB} % {..} or [..]
\unexpanded \def\setup {\doifnextcharelse\bgroup\dosetups \dosetupsC} % {..} or [..]
-\def\dosetupsA #1{\processcommacommand[#1]\dosetups} % {..}
-\def\dosetupsB[#1]{\processcommacommand[#1]\dosetups} % [..]
-\def\dosetupsC[#1]{\dosetups{#1}} % [..]
+% \def\dosetupsA #1{\processcommacommand[#1]\dosetups} % {..}
+% \def\dosetupsB[#1]{\processcommacommand[#1]\dosetups} % [..]
+% \def\dosetupsC[#1]{\dosetups{#1}} % [..]
+%
+% better:
+
+\def\dosetupsA #1{\cleanuplabel{#1}\processcommacommand[\cleanlabel]\dosetups} % {..}
+\def\dosetupsB[#1]{\cleanuplabel{#1}\processcommacommand[\cleanlabel]\dosetups} % [..]
+\def\dosetupsC[#1]{\cleanuplabel{#1}\dosetups\cleanlabel} % [..]
\def\dosetups#1% the grid option will be extended to other main modes
{\executeifdefined{\??su\ifgridsnapping\v!grid\fi:#1}{\csname\??su:#1\endcsname}\empty}
@@ -320,10 +346,12 @@
{\ifthirdargument\@EA\startsetupsC\else\@EA\startsetupsD\fi}
% \long\def\dodostartsetups#1#2#3% watch out: not \grabuntil
-% {\dograbuntil#1{\egroup\long\setvalue{\??su#2:#3}}}
+% {\dograbuntil#1{\egroup\dodoglobal\long\setvalue{\??su#2:#3}}} % \doglobal
+%
+% better:
\long\def\dodostartsetups#1#2#3% watch out: not \grabuntil
- {\dograbuntil#1{\egroup\dodoglobal\long\setvalue{\??su#2:#3}}} % \doglobal
+ {\cleanuplabel{\??su#2:#3}\dograbuntil#1{\egroup\dodoglobal\long\setvalue\cleanlabel}} % \doglobal
\def\systemsetupsprefix{*}
diff --git a/tex/context/base/core-not.tex b/tex/context/base/core-not.tex
index eba5113da..f3f696a56 100644
--- a/tex/context/base/core-not.tex
+++ b/tex/context/base/core-not.tex
@@ -652,7 +652,8 @@
\kern\notesignal\relax} % \relax is needed to honor spaces
\def\dolastnotesymbol
- {\unskip\unskip
+ {\removeunwantedspaces
+ \doifitalicelse\/\donothing % Charles IV \footnote{the fourth}
\ifdim\lastkern=\notesignal
\dodonotesymbol{\kern\noteparameter\c!distance}% gets the font right, hack !
\fi
diff --git a/tex/context/base/core-obj.tex b/tex/context/base/core-obj.tex
index 8f482848d..1e6720540 100644
--- a/tex/context/base/core-obj.tex
+++ b/tex/context/base/core-obj.tex
@@ -212,7 +212,8 @@
\else\ifdim\wd\scratchbox>#4\scaledpoint
\vss\hbox to #4\scaledpoint{\hss\box\scratchbox\hss}\vss
\else
- \vss\box\scratchbox
+ %\vss\box\scratchbox
+ \vss\hbox to #4\scaledpoint{\box\scratchbox\hss}% fix Chof
\fi\fi}}%
\box\scratchbox
\elabelgroup}
diff --git a/tex/context/base/enco-cas.tex b/tex/context/base/enco-cas.tex
index 7629a4b38..032b71786 100644
--- a/tex/context/base/enco-cas.tex
+++ b/tex/context/base/enco-cas.tex
@@ -1,6 +1,6 @@
%D \module
%D [ file=enco-cas,
-%D version=2000.20.12,
+%D version=2000.20.12,
%D title=\CONTEXT\ Encoding Macros,
%D subtitle=Named Glyph Case Mapping,
%D author=Hans Hagen,
@@ -8,15 +8,15 @@
%D copyright=PRAGMA-ADE]
%C
%C This module is part of the \CONTEXT\ macro||package and is
-%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
-%C details.
+%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
+%C details.
%D For quite some years \CONTEXT\ used a rather compact way of
%D defining encoded characters as well as case maps. When late
%D 2000 more advanced remapping features were needed (like pdf
%D unicode remapping), named glyphs were introduced to keep the
-%D coding tables more readable. At the same time, we introduced
-%D named glyph case mapping.
+%D coding tables more readable. At the same time, we introduced
+%D named glyph case mapping.
\defineULcharacter Acircumflex acircumflex
\defineULcharacter Ccircumflex ccircumflex
@@ -36,11 +36,13 @@
\defineULcharacter Igrave igrave
\defineULcharacter Ograve ograve
\defineULcharacter Ugrave ugrave
+\defineULcharacter Ygrave ygrave
\defineULcharacter Atilde atilde
\defineULcharacter Itilde itilde
\defineULcharacter Otilde otilde
\defineULcharacter Utilde utilde
+\defineULcharacter Ntilde ntilde
\defineULcharacter Adiaeresis adiaeresis
\defineULcharacter Ediaeresis ediaeresis
@@ -60,6 +62,7 @@
\defineULcharacter Sacute sacute
\defineULcharacter Uacute uacute
\defineULcharacter Zacute zacute
+\defineULcharacter Yacute yacute
\defineULcharacter Dstroke dstroke
\defineULcharacter Hstroke hstroke
@@ -83,6 +86,8 @@
\defineULcharacter Rcedilla rcedilla
\defineULcharacter Scedilla scedilla
\defineULcharacter Tcedilla tcedilla
+\defineULcharacter Ccedilla ccedilla
+\defineULcharacter Gcedilla gcedilla
\defineULcharacter Ohungarumlaut ohungarumlaut
\defineULcharacter Uhungarumlaut uhungarumlaut
@@ -121,4 +126,12 @@
\defineULcharacter Ssharp ssharp
\defineULcharacter IJligature ijligature
+\defineULcharacter Scommaaccent scommaaccent
+\defineULcharacter Tcommaaccent tcommaaccent
+
+\defineULcharacter Thorn thorn
+\defineULcharacter Eth eth
+
+\defineULcharacter Lslash lslash
+
\endinput
diff --git a/tex/context/base/enco-def.tex b/tex/context/base/enco-def.tex
index 4bc504c1b..af59a799c 100644
--- a/tex/context/base/enco-def.tex
+++ b/tex/context/base/enco-def.tex
@@ -820,4 +820,13 @@
\ifx\leftguillemet \undefined \def\leftguillemet {\leftguillemot } \fi
\ifx\rightguillemet\undefined \def\rightguillemet{\rightguillemot} \fi
+%D New:
+
+\startencoding[\s!default]
+
+\definecharacter schwa {\hbox{\rotate[\c!rotation=180,\c!location=\v!high]{\hbox{e}}}}
+\definecharacter schwagrave {\buildtextgrave\schwa}
+
+\stopencoding
+
\endinput
diff --git a/tex/context/base/enco-ffr.tex b/tex/context/base/enco-ffr.tex
index 012d572ee..f321b1005 100644
--- a/tex/context/base/enco-ffr.tex
+++ b/tex/context/base/enco-ffr.tex
@@ -22,10 +22,10 @@
\startlanguagespecifics[\s!fr]
- \defineactivecharacter : {\directdiscretionary{:}}
- \defineactivecharacter ; {\directdiscretionary{;}}
- \defineactivecharacter ! {\directdiscretionary{!}}
- \defineactivecharacter ? {\directdiscretionary{?}}
+ \defineactivecharacter : {\mathortext{:}{\directdiscretionary{:}}}
+ \defineactivecharacter ; {\mathortext{;}{\directdiscretionary{;}}}
+ \defineactivecharacter ! {\mathortext{!}{\directdiscretionary{!}}}
+ \defineactivecharacter ? {\mathortext{?}{\directdiscretionary{?}}}
\stoplanguagespecifics
diff --git a/tex/context/base/enco-ini.tex b/tex/context/base/enco-ini.tex
index c1120a508..2b7c85fcd 100644
--- a/tex/context/base/enco-ini.tex
+++ b/tex/context/base/enco-ini.tex
@@ -1816,7 +1816,7 @@
% some fake ones, name will change into build
\unexpanded\def\bottomaccent#1#2#3#4#5% down right slantcorrection accent char
- {\leavevmode
+ {\dontleavehmode % why this align mess
\vtop
{\forgetall
\baselineskip\zeropoint
@@ -1848,6 +1848,25 @@
\definecommand d {\buildtextbottomdot}
\definecommand k {\buildtextogonek}
+%D Rarely needed but there:
+
+\unexpanded\def\topaccent#1#2#3#4#5% down right slantcorrection accent char
+ {\dontleavehmode
+ \bgroup
+ \setbox0\hbox{#4}%
+ \setbox2\hbox{#5}%
+ \hbox to \wd2 \bgroup
+ \hss\copy2\hss
+ \hskip-\wd2
+ \hss\hskip#2\wd0\hskip-#3\fontdimen1\font\raise#1\hbox{#4}\hss
+ \egroup
+ \egroup}
+
+\def\buildtextgrave{\topaccent{0pt}{0}{15}{\textgrave}} % e.g.
+
+% \definecharacter schwa {\hbox{\rotate[rotation=180,location=high]{\hbox{e}}}}
+% \definecharacter schwagrave {\buildtextgrave\schwa}
+
% math stuff, will change
\def\definemathaccent#1 #2%
diff --git a/tex/context/base/lang-ita.tex b/tex/context/base/lang-ita.tex
index 69c01a3da..f2640379a 100644
--- a/tex/context/base/lang-ita.tex
+++ b/tex/context/base/lang-ita.tex
@@ -171,7 +171,7 @@
\setupheadtext [\s!ro] [\v!tables=Tabele]
\setupheadtext [\s!fr] [\v!figures=Figures]
-\setupheadtext [\s!es] [\v!figures=Ilustraci\'ons]
+\setupheadtext [\s!es] [\v!figures=Ilustraciones]
\setupheadtext [\s!ca] [\v!figures=Figures]
\setupheadtext [\s!it] [\v!figures=Figure]
\setupheadtext [\s!la] [\v!figures=Imagines]
@@ -195,7 +195,7 @@
\setupheadtext [\s!ro] [\v!intermezzi=Intermzzo]
\setupheadtext [\s!fr] [\v!index=Index]
-\setupheadtext [\s!es] [\v!index=\'Indice]
+\setupheadtext [\s!es] [\v!index=\'Indice alfab\'etico]
\setupheadtext [\s!ca] [\v!index=\'Index alfab\`etic]
\setupheadtext [\s!it] [\v!index=Indice]
\setupheadtext [\s!la] [\v!index=Indices]
@@ -203,7 +203,7 @@
\setupheadtext [\s!ro] [\v!index=Index]
\setupheadtext [\s!fr] [\v!abbreviations=Abr\'eviations]
-\setupheadtext [\s!es] [\v!abbreviations=Abreviaci\'ons]
+\setupheadtext [\s!es] [\v!abbreviations=Abreviaciones]
\setupheadtext [\s!ca] [\v!abbreviations=Abreviacions]
\setupheadtext [\s!it] [\v!abbreviations=Abbreviazioni]
\setupheadtext [\s!la] [\v!abbreviations=Notae]
@@ -219,7 +219,7 @@
\setupheadtext [\s!ro] [\v!logos=Logo-uri]
\setupheadtext [\s!fr] [\v!units=Unit\'es]
-\setupheadtext [\s!es] [\v!units=Unidads]
+\setupheadtext [\s!es] [\v!units=Unidades]
\setupheadtext [\s!ca] [\v!units=Unitats]
\setupheadtext [\s!it] [\v!units=Unit\`a]
\setupheadtext [\s!la] [\v!units=Modi]
@@ -252,7 +252,7 @@
\setuplabeltext [\s!fr] [\v!graphic=Illustration ]
\setuplabeltext [\s!es] [\v!graphic=Gr\'afico ]
-\setuplabeltext [\s!ca] [\v!graphic=Gr\'afica ]
+\setuplabeltext [\s!ca] [\v!graphic=Gr\`afica ]
\setuplabeltext [\s!it] [\v!graphic=Grafico ]
\setuplabeltext [\s!la] [\v!graphic=Typus ]
\setuplabeltext [\s!pt] [\v!graphic=Gr\'afico ]
@@ -343,7 +343,7 @@
\setuplabeltext [\s!fr] [\v!november=novembre]
\setuplabeltext [\s!fr] [\v!december=d\'ecembre]
-\setuplabeltext [\s!es] [\v!january=jenero]
+\setuplabeltext [\s!es] [\v!january=enero]
\setuplabeltext [\s!es] [\v!february=febrero]
\setuplabeltext [\s!es] [\v!march=marzo]
\setuplabeltext [\s!es] [\v!april=abril]
@@ -351,10 +351,10 @@
\setuplabeltext [\s!es] [\v!june=junio]
\setuplabeltext [\s!es] [\v!july=julio]
\setuplabeltext [\s!es] [\v!august=agosto]
-\setuplabeltext [\s!es] [\v!september=septimbre]
+\setuplabeltext [\s!es] [\v!september=septiembre]
\setuplabeltext [\s!es] [\v!october=octubre]
\setuplabeltext [\s!es] [\v!november=noviembre]
-\setuplabeltext [\s!es] [\v!december=deciembre]
+\setuplabeltext [\s!es] [\v!december=diciembre]
\setuplabeltext [\s!ca] [\v!january=gener]
\setuplabeltext [\s!ca] [\v!february=febrer]
@@ -364,10 +364,10 @@
\setuplabeltext [\s!ca] [\v!june=juny]
\setuplabeltext [\s!ca] [\v!july=juliol]
\setuplabeltext [\s!ca] [\v!august=agost]
-\setuplabeltext [\s!ca] [\v!september=septembre]
+\setuplabeltext [\s!ca] [\v!september=setembre]
\setuplabeltext [\s!ca] [\v!october=octubre]
\setuplabeltext [\s!ca] [\v!november=novembre]
-\setuplabeltext [\s!ca] [\v!december=decembre]
+\setuplabeltext [\s!ca] [\v!december=desembre]
\setuplabeltext [\s!it] [\v!january=gennaio]
\setuplabeltext [\s!it] [\v!february=febbraio]
diff --git a/tex/context/base/mult-con.tex b/tex/context/base/mult-con.tex
index 80fb85c31..9a5068321 100644
--- a/tex/context/base/mult-con.tex
+++ b/tex/context/base/mult-con.tex
@@ -1272,6 +1272,9 @@ splitoffset: splitsoffset splitoffset
text: tekst text
text text
testo text
+ listtext: lijsttekst listtext
+ listtext listtext
+ listtext listtext
textwidth: tekstbreedte textwidth
textbreite sirkatextu
ampiezzatesto latimetext
@@ -1296,6 +1299,15 @@ splitoffset: splitsoffset splitoffset
title: titel title
titel titul
titolo titlu
+ titlestyle: titelletter titlestyle
+ titelstil styltitulek
+ stiletitolo stiltitlu
+ titlecolor: titelkleur titlecolor
+ titelfarbe barvatitulek
+ coloretitolo culoaretitlu
+ titledistance: titelafstand titledistance
+ titelabstand vzdalenosttitulek
+ distanzatitolo distantatitlu
aligntitle: titeluitlijnen aligntitle
titelausrichten zarovnejtitul
allineatitolo alinieretitlu
@@ -2357,6 +2369,13 @@ process: proces process
xml xml
xml xml
+ enumeration: doornummering enumeration
+ nummerierung vycet
+ enumerazione enumerare
+ description: doordefinitie description
+ beschreibung popis
+ descrizione descriere
+
\stopvariables
\startconstants dutch english
diff --git a/tex/context/base/page-flt.tex b/tex/context/base/page-flt.tex
index 9933410b4..67c8013d3 100644
--- a/tex/context/base/page-flt.tex
+++ b/tex/context/base/page-flt.tex
@@ -235,7 +235,7 @@
{\setlocalfloathsize
\getvalue{\??fl#1\c!inner}%
\fuzzysnappingfalse
- \postponefootnotes} % new
+ \postponenotes} % new
{\xdocompletefloat{#1}{#3}{#1}{#2}{#1}{#4}% ** not yet done
% we need to carry over the par because of side floats
\doifnotinset\v!text{#2}{\carryoverpar\endgroup}%
@@ -1268,7 +1268,7 @@
\swapdimens\hsize\vsize
\fi
\forgetall
- \postponefootnotes
+ \postponenotes
\dontcomplain
\setbox\tempfloatbox\vbox{\borderedfloatbox{#4}}%
\def\locatefloat
@@ -1550,7 +1550,7 @@
\def\dosetparfloat#1#2#3#4%
{\bgroup
\forgetall
- \postponefootnotes
+ \postponenotes
\dontcomplain
%\showcomposition
\setbox\tempfloatbox\vbox{\borderedfloatbox{#4}}%
diff --git a/tex/context/base/spec-dpx.tex b/tex/context/base/spec-dpx.tex
index 2fc4f08ee..0feffbf0b 100644
--- a/tex/context/base/spec-dpx.tex
+++ b/tex/context/base/spec-dpx.tex
@@ -1,6 +1,6 @@
%D \module
%D [ file=spec-dpx,
-%D version=2002.11.28,
+%D version=2005.08.12,
%D title=\CONTEXT\ Special Macros,
%D subtitle=DVIPDFMx support,
%D author=Jin-Hwan Cho,
@@ -22,7 +22,7 @@
\unprotect
-%D This driver is build on top of the general \PDF\ macros,
+%D This driver is built on top of the general \PDF\ macros,
%D as defined in \type{spec-fdf}, so we inherit that one.
\startspecials[dpx][reset,fdf]
@@ -40,7 +40,7 @@
%D Map files (experimental)
\definespecial\doloadmapfile#1#2%
- {\flushatshipout{\special{pdf: mapfile +#2}}}
+ {\flushatshipout{\special{pdf:mapfile +#2}}}
%D DVIPDFMx supports the special command \type{pdf: literal ...}
%D since the version \type{dvipdfmx-20021028}.
@@ -55,11 +55,23 @@
%D 3. \type{pdf: literal direct #1} puts directly the given PDF
%D commands \#1 without changing the text matrix.
%D
+%D Since the version \type{dvipdfmx-20050812}, the role of the special
+%D command \type{pdf:literal} is changed so that
+%D
+%D 1. \type{pdf:literal #1} puts the given PDF commands \#1
+%D after changing the text matrix with \type{"1 0 0 1 x y cm"}
+%D to set the current DVI position $(x,y)$ to the origin. After that
+%D it restores the previous setting by changing the text matrix with
+%D \type{"1 0 0 1 -x -y cm"}.
+%D
+%D 2. \type{pdf:literal direct #1} puts directly the given PDF commands
+%D #1 without changing the text matrix.
+%D
%D Literal \PDF\ inclusion is implemented as:
-\def\PDFcode #1{\special{pdf: literal direct #1}}
-\def\PDFcontentcode#1{\special{pdf: literal #1}}
-\def\PDFdirectcode #1{\special{pdf: literal direct #1}}
+\def\PDFcode #1{\special{pdf:literal #1}}
+\def\PDFcontentcode#1{\special{pdf:content #1}}
+\def\PDFdirectcode #1{\special{pdf:literal direct #1}}
%D \type{\dosetuppaper} in \type{spec-dpm} did not work properly
%D because DVIPDFM did not permit changing the page size.
@@ -76,13 +88,13 @@
{\bgroup
\scratchdimen#2\edef\width {\the\scratchdimen\space}%
\scratchdimen#3\edef\height{\the\scratchdimen\space}%
- \special{pdf: pagesize width \width height \height}%
+ \special{pdf:pagesize width \width height \height}%
\egroup}
%D \macros
%D {doinsertfile}
%D
-%D Only \METAPOST, \JPG\ \PNG\ and \PDF\ inclusion are supported.
+%D Only \METAPOST, \BMP\ \JPG\ \PNG\ and \PDF\ inclusion are supported.
\definespecial\doinsertfile#1#2#3#4#5#6#7#8#9%
{\dodoinsertfile{dpx}{#1}{#2}{#3}{#4}{#5}{#6}{#7}{#8}{#9}}
@@ -93,30 +105,40 @@
%D So, \METAPOST will be treated as the same way as PDFTeX using
%D MPtoPDF in DVIPDFMx since the version \type{dvipdfmx-20021028}.
-\definefileinsertion{dpx}{mps}#1#2#3#4#5#6#7#8#9%
- {\hbox
- {%\convertMPcolors{#1}% plugged in supp-mpe
- \scratchdimen#3pt \PointsToReal{.01\scratchdimen}\xscale
- \scratchdimen#4pt \PointsToReal{.01\scratchdimen}\yscale
- \special{pdf: literal direct q}\special{pdf: literal}%
- \convertMPtoPDF{#1}\xscale\yscale
- \special{pdf: literal direct Q}
- \global\let\PDFimagereference\empty}}
+%\definefileinsertion{dpx}{mps}#1#2#3#4#5#6#7#8#9%
+% {\hbox
+% {%\convertMPcolors{#1}% plugged in supp-mpe
+% \scratchdimen#3\points \PointsToReal{.01\scratchdimen}\xscale
+% \scratchdimen#4\points \PointsToReal{.01\scratchdimen}\yscale
+% \convertMPtoPDF{#1}\xscale\yscale
+% \global\let\PDFimagereference\empty}}
%D DVIPDFM (and DVIPDFMx too) supports the image files with
-%D the extension, \PDF, \JPG, \PNG, and \EPS.
+%D the extension, \PDF, \JPG, \PNG, \BMP, and \EPS.
+
+\def\handleepsimage#1#2#3#4#5#6#7#8#9%
+ {\PointsToWholeBigPoints{#7}\width
+ \PointsToWholeBigPoints{#8}\height
+ \special
+ {PSfile="#1"\space
+ llx=\EPSllx\space lly=\EPSlly\space
+ urx=\EPSurx\space ury=\EPSury\space
+ rwi=\width0\space rhi=\height0}}
+
+\definefileinsertion{dpx}{mps}{\handleepsimage}
+\definefileinsertion{dpx}{eps}{\handleepsimage} % unstable
-\def\handlepdfimage#1#2#3#4#5#6#7#8#9%
+\def\handlebmpimage#1#2#3#4#5#6#7#8#9%
{\bgroup
\scratchdimen#7\edef\width {\the\scratchdimen\space}%
\scratchdimen#8\edef\height{\the\scratchdimen\space}%
\special{pdf: image width \width height \height (#1)}%
\egroup}
-\definefileinsertion{dpx}{pdf}{\handlepdfimage}
-\definefileinsertion{dpx}{jpg}{\handlepdfimage}
-\definefileinsertion{dpx}{png}{\handlepdfimage}
-\definefileinsertion{dpx}{eps}{\handlepdfimage} % unstable
+\definefileinsertion{dpx}{pdf}{\handlebmpimage}
+\definefileinsertion{dpx}{jpg}{\handlebmpimage}
+\definefileinsertion{dpx}{png}{\handlebmpimage}
+\definefileinsertion{dpx}{bmp}{\handlebmpimage}
\definefileinsertion{dpx}{mov}{\doPDFinsertmov}
\definefileinsertion{dpx}{avi}{\doPDFinsertmov}
@@ -159,7 +181,7 @@
\ifPDFstrokecolor\else\ifnum\dostroke=1
\writestatus\m!colors{pdf stroke color will fail}\wait
\fi\fi
- \special{pdf: content
+ \special{pdf:content
\stroke\space w
\xxmin\space \ymin\space m
\xxmax\space \ymin\space l
@@ -195,27 +217,39 @@
%D \type {\doPDF..} alternatives. Since \CONTEXT\ maintains
%D its own colorstack, we use the \DVIPS\ alternatives.
-\definespecial\dostartgraymode #1{\special{color gray #1}}
-\definespecial\dostopgraymode {\special{color gray 0}}
-\definespecial\dostartrgbcolormode #1#2#3{\special{color rgb #1 #2 #3}}
-\definespecial\dostartcmykcolormode#1#2#3#4{\special{color cmyk #1 #2 #3 #4}}
-\definespecial\dostartgraycolormode #1{\special{color gray #1}}
-\definespecial\dostopcolormode {\special{color gray 0}}
-\definespecial\dostartrotation #1{\special{pdf: bt rotate #1}}
-\definespecial\dostoprotation {\special{pdf: et}}
-\definespecial\dostartscaling #1#2{\special{pdf: bt xscale #1 yscale #2}}
-\definespecial\dostopscaling {\special{pdf: et}}
-\definespecial\dostartmirroring {\special{pdf: bt xscale -1}} % ?
-\definespecial\dostopmirroring {\special{pdf: et}}
+\definespecial\dostartgraymode {\doPDFstartgraymode}
+\definespecial\dostopgraymode {\doPDFstopgraymode}
+\definespecial\dostartrgbcolormode {\doPDFstartrgbcolormode}
+\definespecial\dostartcmykcolormode{\doPDFstartcmykcolormode}
+\definespecial\dostartgraycolormode{\doPDFstartgraycolormode}
+\definespecial\dostartspotcolormode{\doPDFstartspotcolormode}
+\definespecial\dostopcolormode {\doPDFstopcolormode}
-%D Negation is not (yet) supported:
+\definespecial\doregistercmykspotcolor{\doPDFregistercmykspotcolor}
+\definespecial\doregisterrgbspotcolor {\doPDFregisterrgbspotcolor}
+\definespecial\doregistergrayspotcolor{\doPDFregistergrayspotcolor}
-% we need resource access
-%
-% \definespecial\dostartnegative {}
-% \definespecial\dostopnegative {}
-% \definespecial\dostarttransparency {}
-% \definespecial\dostoptransparency {}
+\definespecial\doregistercmykindexcolor{\doPDFregistercmykindexcolor}
+\definespecial\doregisterrgbindexcolor {\doPDFregisterrgbindexcolor}
+\definespecial\doregistergrayindexcolor{\doPDFregistergrayindexcolor}
+
+\definespecial\doregisterfigurecolor{\doPDFregisterfigurecolor}
+
+\definespecial\dostartnonecolormode{\doPDFstartnonecolormode}
+\definespecial\doregisternonecolor {\doPDFregisternonecolor}
+
+\definespecial\dostartrotation #1{\special{pdf:btrans rotate #1}}
+\definespecial\dostoprotation {\special{pdf:etrans}}
+\definespecial\dostartscaling#1#2{\special{pdf:btrans xscale #1 yscale #2}}
+\definespecial\dostopscaling {\special{pdf:etrans}}
+\definespecial\dostartmirroring {\special{pdf:btrans xscale -1}}
+\definespecial\dostopmirroring {\special{pdf:etrans}}
+
+%D Negation is not (yet) supported:
+\definespecial\dostartnegative {\doPDFstartnegative}
+\definespecial\dostopnegative {\doPDFstopnegative}
+\definespecial\dostartoverprint {\doPDFstartoverprint}
+\definespecial\dostopoverprint {\doPDFstopoverprint}
\definespecial\dostarttransparency{\doPDFstarttransparency}
\definespecial\dostoptransparency {\doPDFstoptransparency}
@@ -242,7 +276,7 @@
%\immediate\pdfobj{\PDFtransparancydictionary{#1}{#2}{}}%
% \special{pdf: object @TR:\the\PDFcurrenttransparency\space \PDFtransparancydictionary{#1}{#2}{}}%
\doPDFreserveDPXobject{TR:\the\PDFcurrenttransparency}{<< >>}%
- \special{pdf: \doPDFcheckedDPXobject{TR:\the\PDFcurrenttransparency}\PDFtransparancydictionary{#1}{#2}{}}%
+ \special{pdf:\doPDFcheckedDPXobject{TR:\the\PDFcurrenttransparency}\PDFtransparancydictionary{#1}{#2}{}}%
\edef\PDFtransparencyidentifier{/Tr\the\PDFcurrenttransparency}%
%\edef\PDFtransparencyreference {\PDFobjref\pdflastobj}%
\edef\PDFtransparencyreference {@TR:\the\PDFcurrenttransparency}%
@@ -256,7 +290,7 @@
%{\immediate\pdfobj{\PDFtransparancydictionary{1}{1}{/AIS false}}%
% {\special{pdf: object @TR:0 \PDFtransparancydictionary{1}{1}{/AIS false}}%
{\doPDFreserveDPXobject{TR:0}{<< >>}%
- \special{pdf: \doPDFcheckedDPXobject{TR:0}\PDFtransparancydictionary{1}{1}{/AIS false}}%
+ \special{pdf:\doPDFcheckedDPXobject{TR:0}\PDFtransparancydictionary{1}{1}{/AIS false}}%
\xdef\PDFtransparencyresetidentifier{/Tr0}%
%\xdef\PDFtransparencyresetreference{\PDFobjref\pdflastobj}%
\xdef\PDFtransparencyresetreference{@TR:0}%
@@ -299,11 +333,10 @@
\def\docommando##1%
{\edef\sanitizedJScode{\getJSpreamble{##1}}%
\@EA\doPSsanitizeJScode\sanitizedJScode\to\sanitizedJScode
- \special{pdf: object @JS:#1 <</S /JavaScript /JS (\sanitizedJScode)>>}%
- \edef\compositeJScode{\compositeJScode\space (##1) @JS:#1}}%
+ \special{pdf:object @JS:##1 <</S /JavaScript /JS (\sanitizedJScode)>>}%
+ \edef\compositeJScode{\compositeJScode\space (##1) @JS:##1}}%
\processcommalist[#1]\docommando
- \special{pdf: object @JS:JS <</Names [\compositeJScode]>>}%
- \special{pdf: put @names <</JavaScript @JS:JS>>}%
+ \special{pdf:names /JavaScript [\compositeJScode]}%
\egroup}
%D \macros
@@ -350,9 +383,9 @@
\scratchdimen#3\edef\height{\the\scratchdimen\space}%
\doifsomething{\PDFdestination}
{\special
- {pdf: thread @ART::\PDFdestination\space
- width \width height \height
- <</Title (\PDFdestination)>>}}%
+ {pdf:thread @ART::\PDFdestination\space
+ width \width height \height
+ <</Title (\PDFdestination)>>}}%
\egroup}
\definespecial\doendofprofile
@@ -378,20 +411,21 @@
\scratchdimen#3\edef\width {\the\scratchdimen\space}%
\scratchdimen#4\edef\height{\the\scratchdimen\space}%
\setbox\nextbox\vbox
- {\special{pdf: bxobj @#1::#2 width \width height \height}%
- % we need to compensate for the box offset (ugly, sigh)
- \scratchdimen\nextboxht
- \advance\scratchdimen\nextboxdp
- \advance\scratchdimen-#4\relax
- \nextboxdp\zeropoint
- \nextboxht\zeropoint
- \hbox to #3{\hss\lower.5\scratchdimen\box\nextbox\hss}%
+ {\special{pdf:bxobj @#1::#2 width \width height \height}%
+ % we need to compensate for the box offset (ugly, sigh)
+ \scratchdimen\nextboxht
+ \advance\scratchdimen\nextboxdp
+ \advance\scratchdimen-#4\relax
+ \nextboxdp\zeropoint
+ \nextboxht\zeropoint
+ \hbox to #3{\hss\lower.5\scratchdimen\box\nextbox\hss}%
\ifx\currentPDFresources\empty
- \special{pdf: exobj}%
\else
- \special{pdf: exobj <<\currentPDFresources\the\pdfpageresources>>}%
+ \special{pdf:put @resources
+ <<\currentPDFresources\the\pdfpageresources>>}%
\global\let\currentPDFresources\empty
- \fi}%
+ \fi
+ \special{pdf:exobj}}%
\smashbox\nextbox
\flushatshipout{\box\nextbox}%
\egroup}%
@@ -404,7 +438,7 @@
{\hbox
{\doPDFgetobjectreference{#1}{#2}\PDFobjectreference
\ifx\PDFobjectreference\empty \else
- \special{pdf: usexobj @#1::#2}%
+ \special{pdf:uxobj @#1::#2}%
\fi}}
%D \macros
@@ -452,7 +486,7 @@
%D {doPDFdestination}
\def\doPDFdestination name #1%
- {\special{pdf: dest (#1) [@thispage\PDFpageviewwrd]}}
+ {\special{pdf:names /Dests (#1) [@thispage \PDFpageviewwrd]}}
%D \macros
%D {doPDFaction,doPDFannotation,ifsharePDFactions}
@@ -482,7 +516,7 @@
%\fi
\scratchdimen#2\edef\width {\the\scratchdimen\space}%
\scratchdimen#3\edef\height{\the\scratchdimen\space}%
- \special{pdf: ann #1 width \width height \height
+ \special{pdf:ann #1 width \width height \height
<</Subtype /Link /Border [0 0 0]
\ifhighlighthyperlinks \else /H /N \fi
/A \lastPDFaction\space>>}%
@@ -493,12 +527,16 @@
{\dodoPDFaction\empty{#1}{#2}{#3}}
%D \type{\doPDFannotation} in \type{spec-dpm} had a bug.
+%D
+%D \type{\doPDFannotation} conflicts with \type{\doPDFinsertmov},
+%D since width and height also defined in \type{\doPDFinsertmov}.
\def\doPDFannotation width #1 height #2 data #3%
{\bgroup
+ \edef\data{#3}%
\scratchdimen#1\edef\width {\the\scratchdimen\space}%
\scratchdimen#2\edef\height{\the\scratchdimen\space}%
- \special{pdf: ann width \width height \height <<#3>>}%
+ \special{pdf:ann width \width height \height <<\data>>}%
\egroup}
%D \macros
@@ -508,7 +546,7 @@
{\bgroup
\scratchdimen#3\edef\width {\the\scratchdimen\space}%
\scratchdimen#4\edef\height{\the\scratchdimen\space}%
- \special{pdf: ann @#1::#2 width \width height \height <<#5>>}%
+ \special{pdf:ann @#1::#2 width \width height \height <<#5>>}%
\dosetobjectreference{#1}{#2}{@#1::#2}%
\egroup}
@@ -548,19 +586,19 @@
% \to\everyshipout
\def\doPDFaddtocatalog#1%
- {\special{pdf: put @catalog <<#1>>}}
+ {\special{pdf:put @catalog <<#1>>}}
-\def\doPDFaddtoinfo#1% Is this auto appended? Not checked!
- {\special{pdf: docinfo <<#1>>}} % put @docinfo <<#1>>}}
+\def\doPDFaddtoinfo#1%
+ {\special{pdf:put @docinfo <<#1>>}}
\def\doPDFpageattribute#1%
- {\special{pdf: put @thispage <<#1>>}}
+ {\special{pdf:put @thispage <<#1>>}}
\def\doPDFpagesattribute#1%
- {\special{pdf: put @pages <<#1>>}}
+ {\special{pdf:put @pages <<#1>>}}
\def\doPDFpageresource#1%
- {\special{pdf: put @resources <<#1>>}}
+ {\special{pdf:put @resources <<#1>>}}
\let\doPDFresetpageresources \relax
\let\doPDFresetpageattributes\relax
@@ -573,8 +611,8 @@
\def\doPDFbookmark level #1 n #2 text #3 page #4 open #5%
{\ifcase#1\else
- \scratchcounter#4\advance\scratchcounter\minusone
- \special{pdf: outline #1 %\ifcase\the#5-\fi#1
+ %\scratchcounter#4\advance\scratchcounter\minusone
+ \special{pdf:outline #1 %\ifcase#5 opened\fi
% <</Title (#3) /A <</S /GoTo /D (page:\the\scratchcounter)>>>>}%
<</Title (#3) /A <</S /GoTo /D [@page\number#4\space\PDFpageviewwrd]>> >>}%
\fi}
@@ -599,13 +637,13 @@
\def\doPDFreserveDPXobject#1#2%
{\ifundefined{r:pdx:d:#1}%
% we need a \flushatshipoutprep (prepended, normally appended)
- \flushatshipout{\special{pdf: object @#1 #2}}%
+ \flushatshipout{\special{pdf:object @#1 #2}}%
\global\letvalue{r:pdx:d:#1}\empty
\fi}
\def\doPDFreserveDPXobjectfirst#1#2%
{\ifundefined{r:pdx:d:#1}%
- \doglobal\prependtoks\special{pdf: object @#1 #2}\to\everyfirstshipout
+ \doglobal\prependtoks\special{pdf:object @#1 #2}\to\everyfirstshipout
\global\letvalue{r:pdx:d:#1}\empty
\fi}
@@ -617,12 +655,12 @@
\def\doPDFdictionaryobject class #1 name #2 data #3%
{\flushatshipout
- {\special{pdf: \doPDFcheckedDPXobject{#1::#2}<<#3>>}%
+ {\special{pdf:\doPDFcheckedDPXobject{#1::#2}<<#3>>}%
\dosetobjectreference{#1}{#2}{@#1::#2}}}
\def\doPDFarrayobject class #1 name #2 data #3%
{\flushatshipout
- {\special{pdf: \doPDFcheckedDPXobject{#1::#2}[#3]}%
+ {\special{pdf:\doPDFcheckedDPXobject{#1::#2}[#3]}%
\dosetobjectreference{#1}{#2}{@#1::#2}}}
%D \macros
@@ -649,7 +687,7 @@
% \definespecial\dostartgraphicgroup{\special{pdf: literal direct q}}
% \definespecial\dostopgraphicgroup {\special{pdf: literal direct Q}}
-%D 3. Modified codes from \type{spec-tpd}
+%D 3. Copied codes from \type{spec-tpd}
%D \macros
%D {dostartclipping,dostopclipping}
@@ -662,12 +700,11 @@
\PointsToBigPoints{#3}\height
\grabMPclippath{#1}{1}\width\height
{0 0 m \width\space 0 l \width \height l 0 \height l}%
- \special{pdf: literal direct q}%
- \special{pdf: literal 0 w \MPclippath\space W n}%
- \special{pdf: literal reverse}}
+ \PDFcode
+ {q 0 w \MPclippath\space W n}}
\definespecial\dostopclipping
- {\special{pdf: literal direct Q n}}
+ {\PDFcode{Q n}}
%D 4. Modified codes from \type{supp-mpe}
@@ -681,13 +718,13 @@
\defineMPspecial{30}
{\startMPshading{14}% type 2
\setMPshadingcolors{4}{5}{6}{9}{10}{11}%
- \special{pdf: object @ftn:Sh:\currentMPspecial\space
+ \special{pdf:object @ftn:Sh:\currentMPspecial\space
<</FunctionType 2
/Domain [\gMPs1 \gMPs2]
/C0 [\MPshadeA]
/C1 [\MPshadeB]
/N \gMPs3>>}%
- \special{pdf: object @obj:Sh:\currentMPspecial\space
+ \special{pdf:object @obj:Sh:\currentMPspecial\space
<</ShadingType 2
/ColorSpace /\MPshadeC\space
/Function @ftn:Sh:\currentMPspecial\space
@@ -698,13 +735,13 @@
\defineMPspecial{31}
{\startMPshading{16}% type 3
\setMPshadingcolors{4}{5}{6}{10}{11}{12}%
- \special{pdf: object @ftn:Sh:\currentMPspecial\space
+ \special{pdf:object @ftn:Sh:\currentMPspecial\space
<</FunctionType 2
/Domain [\gMPs1 \gMPs2]
/C0 [\MPshadeA]
/C1 [\MPshadeB]
/N \gMPs3>>}%
- \special{pdf: object @obj:Sh:\currentMPspecial\space
+ \special{pdf:object @obj:Sh:\currentMPspecial\space
<</ShadingType 3
/ColorSpace /\MPshadeC\space
/Function @ftn:Sh:\currentMPspecial\space
@@ -712,29 +749,25 @@
/Extend [true true]>>}%
\stopMPshading}
+\def\handleMPfigurespecial#1#2#3#4#5#6#7% toto : combine with ext fig
+ {\doiffileelse{#7}
+ {\vbox to \zeropoint
+ {\vss
+ \hbox to \zeropoint
+ {\special{pdf:btrans matrix #1 #2 #3 #4 #5 #6}%
+ \rlap{\special{pdf:image width 1bp height 1bp (#7)}}
+ \special{pdf:etrans}\hss}}}
+ {\message{[unknown figure #7]}}}
+
%D 5. Modified codes from \type{supp-pdf}
-\def\handleMPfshow
- {\special{pdf: literal direct q}%
- \special{pdf: literal reverse}%
- \dohandleMPfshow
- \special{pdf: literal direct Q}}
+\let\handleMPfshow\dohandleMPfshow
\newcounter\MPPDFcounter
-\def\setMPPDFobject#1#2% resources boxnumber / see other object macros / unchecked
- {\doglobal\increment\MPPDFcounter
- \bgroup
- \setbox\nextbox\vbox
- {\scratchdimen\wd#2\edef\width {\the\scratchdimen\space}%
- \scratchdimen\ht#2\edef\height{\the\scratchdimen\space}%
- \special{pdf: bxobj @MPPDF:\MPPDFcounter\space width \width height \height}%
- \box#2%
- \special{pdf: exobj <<\currentPDFresources>>}}%
- \smashbox\nextbox
- \flushatshipout{\box\nextbox}%
- \egroup
- \edef\getMPPDFobject{\special{pdf: usexobj @MPPDF:\MPPDFcounter}}}
+\def\setMPPDFobject#1#2%
+ {\ifx\currentPDFresources\empty\else\doPDFpageresource{#1}\fi
+ \def\getMPPDFobject{\box#2}}
\let\getMPPDFobject\relax
@@ -743,8 +776,65 @@
%D Experimental (untested):
-\definespecial\dostartfonteffect{\doPDFstartfonteffect}
-\definespecial\dostopfonteffect {\doPDFstopfonteffect}
+\definespecial\dostartfonteffect#1#2#3%
+ {\ifdim#2>\zeropoint
+ \PointsToBigPoints{#2}\ascii
+ \PDFdirectcode{\ascii\space w}%
+ \fi
+ \ifdim#3\points=\onepoint\else
+ \scratchdimen#3\points
+ \PDFdirectcode{\withoutpt{\the\scratchdimen}\space Tc}%
+ \fi
+ \PDFdirectcode{\purenumber#1 Tr}}
+
+\definespecial\dostopfonteffect
+ {\PDFdirectcode{1 w 0 Tc 0 Tr}}
+
+%D 6. Modified codes from \type{core-obj}
+%D
+%D In the viewpoint of TeX, the special command \type{pdf:uxobj @obj}
+%D generates a box with zero point width and zero point height so that
+%D it must be careful to place the box at the reference point.
+
+\def\dogetobject#1#2#3#4#5#6#7% don't change this, should work for dvi & pdf
+ {\initializepaper
+ \forgetall
+ \dontshowcomposition
+ \setbox\scratchbox\vbox
+ {\doinsertobject{#1}{#2}}%
+ \setbox\scratchbox#3%
+ {\vbox to #5\scaledpoint
+ {\ifdim\ht\scratchbox>#5\scaledpoint
+ \vss\hbox to #4\scaledpoint{\hss\box\scratchbox\hss}\vss
+ \else\ifdim\wd\scratchbox>#4\scaledpoint
+ \vss\hbox to #4\scaledpoint{\hss\box\scratchbox\hss}\vss
+ \else
+ %\vss\box\scratchbox
+ \vss\hbox to #4\scaledpoint{\box\scratchbox\hss}
+ \fi\fi}}%
+ \box\scratchbox
+ \elabelgroup}
+
+%D 7. Copied codes from \type{spec-dvi}
+
+\definespecial\dosetposition#1%
+ {\special{pos:pxy "#1"}}
+
+\definespecial\dosetpositionwhd#1#2#3#4%
+ {\special{pos:pxywhd "#1" #2 #3 #4}}
+
+\definespecial\dosetpositionplus#1#2#3#4#5%
+ {\special{pos:pxyplus "#1" #2 #3 #4 #5}}
+
+\let\flushDVIpositionpapersize\relax
+
+\definespecial\dosetpositionpapersize#1#2%
+ {\xdef\flushDVIpositionpapersize%
+ {\special{pos:papersize #1 #2}%
+ \noexpand\installprogram{dvipos \jobname}%
+ \global\noexpand\let\noexpand\flushDVIpositionpapersize\relax}}
+
+\prependtoksonce \flushDVIpositionpapersize \to \everyshipout
\stopspecials
diff --git a/tex/context/base/spec-tst.tex b/tex/context/base/spec-tst.tex
new file mode 100644
index 000000000..e30eea2fe
--- /dev/null
+++ b/tex/context/base/spec-tst.tex
@@ -0,0 +1,151 @@
+%D \module
+%D [ file=spec-tst,
+%D version=2002.12.08,
+%D title=\CONTEXT\ \PDF\ Macros,
+%D subtitle=Special Test Macro
+%D author=Hans Hagen,
+%D date=\currentdate,
+%D copyright={PRAGMA / Hans Hagen \& Ton Otten}]
+%C
+%C This module is part of the \CONTEXT\ macro||package and is
+%C therefore copyrighted by \PRAGMA. See mreadme.pdf for
+%C details.
+
+\ifcase \pdfoutput \endinput \fi
+
+\unprotect
+
+%D The conversions comes down to (for the sake fo speed the
+%D implementation combines steps):
+%D
+%D \startitemize
+%D \item we expand the \UTF\ sequences into \type {\unicodechar}'s
+%D \item spaces become character 255's (so that they are not
+%D gobbled in argument fetching
+%D \item normal \ASCII\ chars are unchanged
+%D \item \par's and alike are converted to \type {\unicodechar}'s
+%D \stopitemize
+%D
+%D This happens by expansion; next we convert the resulting
+%D sequence by interpreting the stream.
+
+\long\def\sanitizePDFuniencoding#1\to#2%
+ {\enablePDFunicrlf
+ \let\unicodechar\relax % prevent further expansion
+ \retainlccodes\lccode32=255 % slooow
+ \lowercasestring\PDFunicodetrigger#1\to#2%
+ \edef#2{\expandafter\doPDFuni#2\empty\empty}} % slooow
+
+%D Handling of empty lines:
+
+\bgroup
+\catcode`\^^M=\@@active
+\gdef\enablePDFunicrlf%
+ {\def\\{\unicodechar{13}}%
+ \def\par{\\\\}%
+ \catcode`\^^M=\@@active%
+ \let^^M=\\}
+\egroup
+
+%D Conversion to 16 bit \UNICODE:
+
+\def\PDFunicodechar#1%
+ {\@EA\lchexnumbers\@EA{\number\utfdiv{#1}}%
+ \@EA\lchexnumbers\@EA{\number\utfmod{#1}}}
+
+\def\PDFunicodetrigger
+ {\unicodechar{65279}}
+
+%D The postprocessor:
+
+\def\doPDFuni#1%
+ {\ifx#1\relax
+ \@EA\dodoPDFuni
+ \else\ifx#1\empty
+ % quit
+ \else
+ \@EAEAEA\nodoPDFuni
+ \fi\fi#1}
+
+\def\nodoPDFuni#1%
+ {\PDFunicodechar{\ifnum`#1=255 32\else`#1\fi}\doPDFuni}
+
+\def\dodoPDFuni#1#2%
+ {\PDFunicodechar{#2}\doPDFuni}
+
+\def\sanitizePDFencoding
+ {\doifelse\currentregime{utf}%
+ {\PDFunicodetrue\sanitizePDFuniencoding}\sanitizePDFdocencoding}
+
+% pdftex specific
+
+\def\doPDFinsertbookmark#1#2#3#4#5% level sublevels text page open=1
+ {\bgroup
+ \sanitizePDFencoding#3\to\bookmarktext % uses scratchcounter
+ \stripstring\bookmarktext
+ \doPDFbookmark level #1 n #2 text {\bookmarktext} page {#4} open #5
+ \egroup}
+
+\def\doPDFbookmark level #1 n #2 text #3 page #4 open #5%
+ {\doPDFgetpagereference{#4}\PDFobjectreference
+ \pdfoutline
+ user {<</S /GoTo /D [\PDFobjectreference\space\PDFpageviewwrd]>>}%
+ \ifcase#2 \else count \ifcase#5-\fi#2 \fi
+ {\ifPDFunicode<#3>\else#3\fi}}
+
+\def\doPDFsetupidentity#1#2#3#4#5#6%
+ {\bgroup
+ \enablePDFdocencoding
+ \sanitizePDFencoding#1\to\idtitle \stripstring\idtitle
+ \sanitizePDFencoding#2\to\idsubject\stripstring\idsubject
+ \sanitizePDFencoding#3\to\idauthor \stripstring\idauthor
+ \sanitizePDFencoding#4\to\idcreator\stripstring\idcreator
+ \sanitizePDFencoding#6\to\idkeyword\stripstring\idkeyword
+ \expanded{\doPDFaddtoinfo
+ {/Title \ifPDFunicode<\idtitle >\else(\idtitle )\fi
+ /Subject \ifPDFunicode<\idsubject>\else(\idsubject)\fi
+ /Author \ifPDFunicode<\idauthor >\else(\idauthor )\fi
+ /Creator \ifPDFunicode<\idcreator>\else(\idcreator)\fi
+ /ModDate (#4)
+ /ID (\jobname.#5) % needed for pdf/x
+ /Keywords \ifPDFunicode<\idkeyword>\else(\idkeyword)\fi}}%
+ \egroup}
+
+\protect
+
+\doifnotmode{demo}{\endinput}
+
+% \input spec-tst.tex
+
+\mainlanguage[vn]
+\enableregime[utf]
+\usetypescript[all][computer-modern][t5]
+
+\setupinteraction
+ [state=start,
+ title={Thử tiếng Việt},
+ author={Tác Văn Giả},
+ keyword={Thử tiếng Việt}]
+
+\placebookmarks[chapter,section,subsection]
+
+\starttext
+
+\placelist[chapter,section,subsection][alternative=c]
+
+\chapter{Thử tiếng Việt}
+
+\section {Mục thứ nhất}
+\subsection{Mục nhỏ thứ nhất} Thử tiếng Việt
+\subsection{Mục nhỏ thứ hai} Thử tiếng Việt
+
+\section {Mục thứ hai}
+\subsection{Mục nhỏ thứ nhất} Thử tiếng Việt
+\subsection{Mục nhỏ thứ hai} Thử tiếng Việt
+
+\section {Mục thứ ba}
+\subsection{Mục nhỏ thứ nhất} Thử tiếng Việt
+\subsection{Mục nhỏ thứ hai} Thử tiếng Việt
+
+\stoptext
+
diff --git a/tex/context/base/verb-xml.tex b/tex/context/base/verb-xml.tex
index adf2f4c30..f80147ebe 100644
--- a/tex/context/base/verb-xml.tex
+++ b/tex/context/base/verb-xml.tex
@@ -84,8 +84,8 @@
\gdef\XMLsetcontrols%
{\saveprettycontrols
\def\obeyedspace%
- {\ifinXMLvalue
- \else % more tests ?
+ {\ifinXMLvalue
+ \else % more tests ?
\XMLstartattribute
\fi
\oldobeyedspace
@@ -107,7 +107,8 @@
\setpretty`\"=20
\setpretty`\(=30 \setpretty`\)=30 \setpretty`\,=30
\setpretty`\*=30 \setpretty`\+=30 \setpretty`\#=30
- \setpretty`\:=30
+% \setpretty`\:=30
+ \setpretty`\:=10 % better for tags
\setpretty`\&=41 \setpretty`\;=42 }
\gdef\XMLsethandlers%
@@ -224,7 +225,7 @@
\gdef\XMLstartattribute%
{\ifinXMLcomment \else
- \ifinXMLpi
+ \ifinXMLpi
\ifXMLmarkkeys\else\endXMLtagname\fi % option
\else
\endXMLtagname
diff --git a/tex/context/interface/cont-cz.xml b/tex/context/interface/cont-cz.xml
index 44e402edc..c131ba7ca 100644
--- a/tex/context/interface/cont-cz.xml
+++ b/tex/context/interface/cont-cz.xml
@@ -3060,7 +3060,7 @@
<cd:command name="enumeration" generated="yes">
<cd:sequence>
- <cd:variable value="enumeration"/>
+ <cd:variable value="vycet"/>
</cd:sequence>
<cd:arguments>
<cd:nothing interactive="yes"/>
@@ -3069,7 +3069,7 @@
<cd:command name="enumeration" type="environment" generated="yes">
<cd:sequence>
- <cd:variable value="enumeration"/>
+ <cd:variable value="vycet"/>
</cd:sequence>
</cd:command>
@@ -3089,7 +3089,7 @@
<cd:command name="description" generated="yes">
<cd:sequence>
- <cd:variable value="description"/>
+ <cd:variable value="popis"/>
</cd:sequence>
<cd:arguments>
<cd:content/>
@@ -3099,7 +3099,7 @@
<cd:command name="description" type="environment" generated="yes">
<cd:sequence>
- <cd:variable value="description"/>
+ <cd:variable value="popis"/>
</cd:sequence>
<cd:arguments>
<cd:content/>
diff --git a/tex/context/interface/cont-de.xml b/tex/context/interface/cont-de.xml
index 21f47dd37..db05e98e3 100644
--- a/tex/context/interface/cont-de.xml
+++ b/tex/context/interface/cont-de.xml
@@ -3060,7 +3060,7 @@
<cd:command name="enumeration" generated="yes">
<cd:sequence>
- <cd:variable value="enumeration"/>
+ <cd:variable value="nummerierung"/>
</cd:sequence>
<cd:arguments>
<cd:nothing interactive="yes"/>
@@ -3069,7 +3069,7 @@
<cd:command name="enumeration" type="environment" generated="yes">
<cd:sequence>
- <cd:variable value="enumeration"/>
+ <cd:variable value="nummerierung"/>
</cd:sequence>
</cd:command>
@@ -3089,7 +3089,7 @@
<cd:command name="description" generated="yes">
<cd:sequence>
- <cd:variable value="description"/>
+ <cd:variable value="beschreibung"/>
</cd:sequence>
<cd:arguments>
<cd:content/>
@@ -3099,7 +3099,7 @@
<cd:command name="description" type="environment" generated="yes">
<cd:sequence>
- <cd:variable value="description"/>
+ <cd:variable value="beschreibung"/>
</cd:sequence>
<cd:arguments>
<cd:content/>
diff --git a/tex/context/interface/cont-it.xml b/tex/context/interface/cont-it.xml
index 92bb4881e..e9758b989 100644
--- a/tex/context/interface/cont-it.xml
+++ b/tex/context/interface/cont-it.xml
@@ -3060,7 +3060,7 @@
<cd:command name="enumeration" generated="yes">
<cd:sequence>
- <cd:variable value="enumeration"/>
+ <cd:variable value="enumerazione"/>
</cd:sequence>
<cd:arguments>
<cd:nothing interactive="yes"/>
@@ -3069,7 +3069,7 @@
<cd:command name="enumeration" type="environment" generated="yes">
<cd:sequence>
- <cd:variable value="enumeration"/>
+ <cd:variable value="enumerazione"/>
</cd:sequence>
</cd:command>
@@ -3089,7 +3089,7 @@
<cd:command name="description" generated="yes">
<cd:sequence>
- <cd:variable value="description"/>
+ <cd:variable value="descrizione"/>
</cd:sequence>
<cd:arguments>
<cd:content/>
@@ -3099,7 +3099,7 @@
<cd:command name="description" type="environment" generated="yes">
<cd:sequence>
- <cd:variable value="description"/>
+ <cd:variable value="descrizione"/>
</cd:sequence>
<cd:arguments>
<cd:content/>
diff --git a/tex/context/interface/cont-nl.xml b/tex/context/interface/cont-nl.xml
index 3a4cd05ee..7958298fb 100644
--- a/tex/context/interface/cont-nl.xml
+++ b/tex/context/interface/cont-nl.xml
@@ -3060,7 +3060,7 @@
<cd:command name="enumeration" generated="yes">
<cd:sequence>
- <cd:variable value="enumeration"/>
+ <cd:variable value="doornummering"/>
</cd:sequence>
<cd:arguments>
<cd:nothing interactive="yes"/>
@@ -3069,7 +3069,7 @@
<cd:command name="enumeration" type="environment" generated="yes">
<cd:sequence>
- <cd:variable value="enumeration"/>
+ <cd:variable value="doornummering"/>
</cd:sequence>
</cd:command>
@@ -3089,7 +3089,7 @@
<cd:command name="description" generated="yes">
<cd:sequence>
- <cd:variable value="description"/>
+ <cd:variable value="doordefinitie"/>
</cd:sequence>
<cd:arguments>
<cd:content/>
@@ -3099,7 +3099,7 @@
<cd:command name="description" type="environment" generated="yes">
<cd:sequence>
- <cd:variable value="description"/>
+ <cd:variable value="doordefinitie"/>
</cd:sequence>
<cd:arguments>
<cd:content/>
diff --git a/tex/context/interface/cont-ro.xml b/tex/context/interface/cont-ro.xml
index 5c1415d46..bd91e5223 100644
--- a/tex/context/interface/cont-ro.xml
+++ b/tex/context/interface/cont-ro.xml
@@ -3060,7 +3060,7 @@
<cd:command name="enumeration" generated="yes">
<cd:sequence>
- <cd:variable value="enumeration"/>
+ <cd:variable value="enumerare"/>
</cd:sequence>
<cd:arguments>
<cd:nothing interactive="yes"/>
@@ -3069,7 +3069,7 @@
<cd:command name="enumeration" type="environment" generated="yes">
<cd:sequence>
- <cd:variable value="enumeration"/>
+ <cd:variable value="enumerare"/>
</cd:sequence>
</cd:command>
@@ -3089,7 +3089,7 @@
<cd:command name="description" generated="yes">
<cd:sequence>
- <cd:variable value="description"/>
+ <cd:variable value="descriere"/>
</cd:sequence>
<cd:arguments>
<cd:content/>
@@ -3099,7 +3099,7 @@
<cd:command name="description" type="environment" generated="yes">
<cd:sequence>
- <cd:variable value="description"/>
+ <cd:variable value="descriere"/>
</cd:sequence>
<cd:arguments>
<cd:content/>
diff --git a/tex/context/interface/keys-cz.xml b/tex/context/interface/keys-cz.xml
index 483dba76f..c09234e18 100644
--- a/tex/context/interface/keys-cz.xml
+++ b/tex/context/interface/keys-cz.xml
@@ -1,6 +1,6 @@
<?xml version="1.0"?>
-<cd:interface xmlns:cd="http://www.pragma-ade.com/commands" name="context" language="cz" version="2005.08.19">
+<cd:interface xmlns:cd="http://www.pragma-ade.com/commands" name="context" language="cz" version="2005.08.31">
<cd:variables>
<cd:variable name="one" value="jedna"/>
@@ -404,6 +404,7 @@
<cd:constant name="tab" value="tab"/>
<cd:constant name="sign" value="znak"/>
<cd:constant name="text" value="text"/>
+ <cd:constant name="listtext" value="listtext"/>
<cd:constant name="textwidth" value="sirkatextu"/>
<cd:constant name="textcommand" value="textovyprikaz"/>
<cd:constant name="textsize" value="velikosttextu"/>
@@ -412,6 +413,9 @@
<cd:constant name="textseparator" value="oddelovactextu"/>
<cd:constant name="textstate" value="statustextu"/>
<cd:constant name="title" value="titul"/>
+ <cd:constant name="titlestyle" value="styltitulek"/>
+ <cd:constant name="titlecolor" value="barvatitulek"/>
+ <cd:constant name="titledistance" value="vzdalenosttitulek"/>
<cd:constant name="aligntitle" value="zarovnejtitul"/>
<cd:constant name="tolerance" value="tolerance"/>
<cd:constant name="inbetween" value="mezi"/>
@@ -759,6 +763,8 @@
<cd:variable name="overprint" value="overprint"/>
<cd:variable name="knockout" value="knockout"/>
<cd:variable name="xml" value="xml"/>
+ <cd:variable name="enumeration" value="vycet"/>
+ <cd:variable name="description" value="popis"/>
</cd:variables>
<cd:constants>
diff --git a/tex/context/interface/keys-de.xml b/tex/context/interface/keys-de.xml
index a8e7e8851..ebd9e6708 100644
--- a/tex/context/interface/keys-de.xml
+++ b/tex/context/interface/keys-de.xml
@@ -1,6 +1,6 @@
<?xml version="1.0"?>
-<cd:interface xmlns:cd="http://www.pragma-ade.com/commands" name="context" language="de" version="2005.08.19">
+<cd:interface xmlns:cd="http://www.pragma-ade.com/commands" name="context" language="de" version="2005.08.31">
<cd:variables>
<cd:variable name="one" value="eins"/>
@@ -404,6 +404,7 @@
<cd:constant name="tab" value="tab"/>
<cd:constant name="sign" value="zeichen"/>
<cd:constant name="text" value="text"/>
+ <cd:constant name="listtext" value="listtext"/>
<cd:constant name="textwidth" value="textbreite"/>
<cd:constant name="textcommand" value="textbefehl"/>
<cd:constant name="textsize" value="textgroesse"/>
@@ -412,6 +413,9 @@
<cd:constant name="textseparator" value="textseparator"/>
<cd:constant name="textstate" value="textstatus"/>
<cd:constant name="title" value="titel"/>
+ <cd:constant name="titlestyle" value="titelstil"/>
+ <cd:constant name="titlecolor" value="titelfarbe"/>
+ <cd:constant name="titledistance" value="titelabstand"/>
<cd:constant name="aligntitle" value="titelausrichten"/>
<cd:constant name="tolerance" value="toleranz"/>
<cd:constant name="inbetween" value="zwischen"/>
@@ -759,6 +763,8 @@
<cd:variable name="overprint" value="overprint"/>
<cd:variable name="knockout" value="knockout"/>
<cd:variable name="xml" value="xml"/>
+ <cd:variable name="enumeration" value="nummerierung"/>
+ <cd:variable name="description" value="beschreibung"/>
</cd:variables>
<cd:constants>
diff --git a/tex/context/interface/keys-en.xml b/tex/context/interface/keys-en.xml
index 7f9439fe3..b2d780965 100644
--- a/tex/context/interface/keys-en.xml
+++ b/tex/context/interface/keys-en.xml
@@ -1,6 +1,6 @@
<?xml version="1.0"?>
-<cd:interface xmlns:cd="http://www.pragma-ade.com/commands" name="context" language="en" version="2005.08.19">
+<cd:interface xmlns:cd="http://www.pragma-ade.com/commands" name="context" language="en" version="2005.08.31">
<cd:variables>
<cd:variable name="one" value="one"/>
@@ -404,6 +404,7 @@
<cd:constant name="tab" value="tab"/>
<cd:constant name="sign" value="sign"/>
<cd:constant name="text" value="text"/>
+ <cd:constant name="listtext" value="listtext"/>
<cd:constant name="textwidth" value="textwidth"/>
<cd:constant name="textcommand" value="textcommand"/>
<cd:constant name="textsize" value="textsize"/>
@@ -412,6 +413,9 @@
<cd:constant name="textseparator" value="textseparator"/>
<cd:constant name="textstate" value="textstate"/>
<cd:constant name="title" value="title"/>
+ <cd:constant name="titlestyle" value="titlestyle"/>
+ <cd:constant name="titlecolor" value="titlecolor"/>
+ <cd:constant name="titledistance" value="titledistance"/>
<cd:constant name="aligntitle" value="aligntitle"/>
<cd:constant name="tolerance" value="tolerance"/>
<cd:constant name="inbetween" value="inbetween"/>
@@ -759,6 +763,8 @@
<cd:variable name="overprint" value="overprint"/>
<cd:variable name="knockout" value="knockout"/>
<cd:variable name="xml" value="xml"/>
+ <cd:variable name="enumeration" value="enumeration"/>
+ <cd:variable name="description" value="description"/>
</cd:variables>
<cd:constants>
diff --git a/tex/context/interface/keys-it.xml b/tex/context/interface/keys-it.xml
index 7790cefc4..c3ffeeda0 100644
--- a/tex/context/interface/keys-it.xml
+++ b/tex/context/interface/keys-it.xml
@@ -1,6 +1,6 @@
<?xml version="1.0"?>
-<cd:interface xmlns:cd="http://www.pragma-ade.com/commands" name="context" language="it" version="2005.08.19">
+<cd:interface xmlns:cd="http://www.pragma-ade.com/commands" name="context" language="it" version="2005.08.31">
<cd:variables>
<cd:variable name="one" value="uno"/>
@@ -404,6 +404,7 @@
<cd:constant name="tab" value="tab"/>
<cd:constant name="sign" value="segno"/>
<cd:constant name="text" value="testo"/>
+ <cd:constant name="listtext" value="listtext"/>
<cd:constant name="textwidth" value="ampiezzatesto"/>
<cd:constant name="textcommand" value="comandotesto"/>
<cd:constant name="textsize" value="dimensionetesto"/>
@@ -412,6 +413,9 @@
<cd:constant name="textseparator" value="separatoretesto"/>
<cd:constant name="textstate" value="statotesto"/>
<cd:constant name="title" value="titolo"/>
+ <cd:constant name="titlestyle" value="stiletitolo"/>
+ <cd:constant name="titlecolor" value="coloretitolo"/>
+ <cd:constant name="titledistance" value="distanzatitolo"/>
<cd:constant name="aligntitle" value="allineatitolo"/>
<cd:constant name="tolerance" value="tolleranza"/>
<cd:constant name="inbetween" value="tra"/>
@@ -759,6 +763,8 @@
<cd:variable name="overprint" value="overprint"/>
<cd:variable name="knockout" value="knockout"/>
<cd:variable name="xml" value="xml"/>
+ <cd:variable name="enumeration" value="enumerazione"/>
+ <cd:variable name="description" value="descrizione"/>
</cd:variables>
<cd:constants>
diff --git a/tex/context/interface/keys-nl.xml b/tex/context/interface/keys-nl.xml
index b396316ed..8342f0530 100644
--- a/tex/context/interface/keys-nl.xml
+++ b/tex/context/interface/keys-nl.xml
@@ -1,6 +1,6 @@
<?xml version="1.0"?>
-<cd:interface xmlns:cd="http://www.pragma-ade.com/commands" name="context" language="nl" version="2005.08.19">
+<cd:interface xmlns:cd="http://www.pragma-ade.com/commands" name="context" language="nl" version="2005.08.31">
<cd:variables>
<cd:variable name="one" value="een"/>
@@ -404,6 +404,7 @@
<cd:constant name="tab" value="tab"/>
<cd:constant name="sign" value="teken"/>
<cd:constant name="text" value="tekst"/>
+ <cd:constant name="listtext" value="lijsttekst"/>
<cd:constant name="textwidth" value="tekstbreedte"/>
<cd:constant name="textcommand" value="tekstcommando"/>
<cd:constant name="textsize" value="tekstformaat"/>
@@ -412,6 +413,9 @@
<cd:constant name="textseparator" value="tekstscheider"/>
<cd:constant name="textstate" value="tekststatus"/>
<cd:constant name="title" value="titel"/>
+ <cd:constant name="titlestyle" value="titelletter"/>
+ <cd:constant name="titlecolor" value="titelkleur"/>
+ <cd:constant name="titledistance" value="titelafstand"/>
<cd:constant name="aligntitle" value="titeluitlijnen"/>
<cd:constant name="tolerance" value="tolerantie"/>
<cd:constant name="inbetween" value="tussen"/>
@@ -759,6 +763,8 @@
<cd:variable name="overprint" value="overprint"/>
<cd:variable name="knockout" value="knockout"/>
<cd:variable name="xml" value="xml"/>
+ <cd:variable name="enumeration" value="doornummering"/>
+ <cd:variable name="description" value="doordefinitie"/>
</cd:variables>
<cd:constants>
diff --git a/tex/context/interface/keys-ro.xml b/tex/context/interface/keys-ro.xml
index b237b3be2..c9de476a0 100644
--- a/tex/context/interface/keys-ro.xml
+++ b/tex/context/interface/keys-ro.xml
@@ -1,6 +1,6 @@
<?xml version="1.0"?>
-<cd:interface xmlns:cd="http://www.pragma-ade.com/commands" name="context" language="ro" version="2005.08.19">
+<cd:interface xmlns:cd="http://www.pragma-ade.com/commands" name="context" language="ro" version="2005.08.31">
<cd:variables>
<cd:variable name="one" value="unu"/>
@@ -404,6 +404,7 @@
<cd:constant name="tab" value="tab"/>
<cd:constant name="sign" value="semn"/>
<cd:constant name="text" value="text"/>
+ <cd:constant name="listtext" value="listtext"/>
<cd:constant name="textwidth" value="latimetext"/>
<cd:constant name="textcommand" value="comandatext"/>
<cd:constant name="textsize" value="dimensiunetext"/>
@@ -412,6 +413,9 @@
<cd:constant name="textseparator" value="separatortext"/>
<cd:constant name="textstate" value="staretext"/>
<cd:constant name="title" value="titlu"/>
+ <cd:constant name="titlestyle" value="stiltitlu"/>
+ <cd:constant name="titlecolor" value="culoaretitlu"/>
+ <cd:constant name="titledistance" value="distantatitlu"/>
<cd:constant name="aligntitle" value="alinieretitlu"/>
<cd:constant name="tolerance" value="toleranta"/>
<cd:constant name="inbetween" value="intre"/>
@@ -759,6 +763,8 @@
<cd:variable name="overprint" value="overprint"/>
<cd:variable name="knockout" value="knockout"/>
<cd:variable name="xml" value="xml"/>
+ <cd:variable name="enumeration" value="enumerare"/>
+ <cd:variable name="description" value="descriere"/>
</cd:variables>
<cd:constants>
diff --git a/tex/context/sample/tufte.tex b/tex/context/sample/tufte.tex
index 154dfa3fb..1b54d2780 100644
--- a/tex/context/sample/tufte.tex
+++ b/tex/context/sample/tufte.tex
@@ -10,4 +10,4 @@ smooth, chunk, average, approximate, cluster, aggregate,
outline, summarize, itemize, review, dip into,
flip through, browse, glance into, leaf through, skim,
refine, enumerate, glean, synopsize, winnow the wheat
-from the chaff and separate the sheep from the goats. \ No newline at end of file
+from the chaff and separate the sheep from the goats.