summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/context/third/letter/interface
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2009-02-16 00:02:48 +0000
committerKarl Berry <karl@freefriends.org>2009-02-16 00:02:48 +0000
commit438ce6e2dc55311d9d2b72b6fd6fe2e7a7760846 (patch)
treee329ac0f73a537ddc6b85e71bfe6e112b3c51403 /Master/texmf-dist/tex/context/third/letter/interface
parentfd5baa85b6dca448cdbe64aadf5c74ba9a0a58a6 (diff)
context-letter update (15feb09)
git-svn-id: svn://tug.org/texlive/trunk@12168 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/context/third/letter/interface')
-rw-r--r--Master/texmf-dist/tex/context/third/letter/interface/default.nli136
-rw-r--r--Master/texmf-dist/tex/context/third/letter/interface/default.nri31
-rw-r--r--Master/texmf-dist/tex/context/third/letter/interface/knuth.nli11
-rw-r--r--Master/texmf-dist/tex/context/third/letter/interface/pragma.nli25
4 files changed, 93 insertions, 110 deletions
diff --git a/Master/texmf-dist/tex/context/third/letter/interface/default.nli b/Master/texmf-dist/tex/context/third/letter/interface/default.nli
index 11f945610d5..4809c7ebd70 100644
--- a/Master/texmf-dist/tex/context/third/letter/interface/default.nli
+++ b/Master/texmf-dist/tex/context/third/letter/interface/default.nli
@@ -1,6 +1,6 @@
%D \module
%D [ file=default,
-%D version=2009.02.09,
+%D version=2009.02.14,
%D title=\CONTEXT\ Letter Interface,
%D subtitle=Default Interface,
%D author=Wolfgang Schuster,
@@ -11,57 +11,8 @@
%M \loadsetups[t-letter.xml]
-%D \subject{Constants and Variables}
-
\unprotect
-%D I define a few additional constants and variables, I will move them
-%D to the base some time.
-
-\startinterface all
- \setinterfaceconstant {opening} {opening}
- \setinterfaceconstant {closing} {closing}
- \setinterfaceconstant {signature} {signature}
- \setinterfaceconstant {dispatch} {dispatch}
- \setinterfaceconstant {appendices} {appendices}
- \setinterfaceconstant {fromaddress} {fromaddress}
- \setinterfaceconstant {frombank} {frombank}
- \setinterfaceconstant {frommail} {frommail}
- \setinterfaceconstant {fromfax} {fromfax}
- \setinterfaceconstant {fromlogo} {fromlogo}
- \setinterfaceconstant {fromname} {fromname}
- \setinterfaceconstant {fromphone} {fromphone}
- \setinterfaceconstant {fromurl} {fromurl}
- \setinterfaceconstant {toname} {toname}
- \setinterfaceconstant {toaddress} {toaddress}
- \setinterfaceconstant {enclosure} {enclosure}
- \setinterfaceconstant {copy} {copy}
- \setinterfaceconstant {postscript} {postscript}
- \setinterfaceconstant {attention} {attention}
- \setinterfaceconstant {distribution} {distribution}
- \setinterfaceconstant {salutation} {salutation}
- \setinterfaceconstant {addressee} {addressee}
-\stopinterface
-
-\startinterface all
- \setinterfacevariable {e} {e}
- \setinterfacevariable {data} {data}
- \setinterfacevariable {sender} {sender}
- \setinterfacevariable {dispatch} {dispatch}
- \setinterfacevariable {enclosure} {enclosure}
- \setinterfacevariable {copy} {copy}
- \setinterfacevariable {nobreak} {nobreak}
- \setinterfacevariable {endgraf} {endgraf}
- \setinterfacevariable {memo} {memo}
- \setinterfacevariable {addressee} {addressee}
- \setinterfacevariable {french} {french}
- \setinterfacevariable {simplified} {simplified}
- \setinterfacevariable {fullblock} {fullblock}
- \setinterfacevariable {hanging} {hanging}
- \setinterfacevariable {modified} {modified}
- \setinterfacevariable {semiblock} {semiblock}
-\stopinterface
-
%D \subject{Reference line}
%D
%D Dimen value to save the height of the reference line.
@@ -107,12 +58,12 @@
\setupletterstyle
[\v!reference]
[\c!hoffset=\backspace,
- \c!voffset=\dimexpr\letterstylevalue\v!address\c!voffset+\letterstylevalue\v!address\c!height+\plusthree\c!mm\relax,
+ \c!voffset=\dimexpr\letterstylevalue{\v!address\v!layer}\c!voffset+\letterstylevalue{\v!address\v!frame}\c!height+\plusthree\c!mm\relax,
\c!width=\textwidth]
\setupletterstyle
[\v!firstpage]
- [\c!topspace=\dimexpr\letterstylevalue\v!reference\c!voffset+\letter!height!reference+\plustwo\lineheight\relax]
+ [\c!topspace=\dimexpr\letterstylevalue{\v!reference\v!layer}\c!voffset+\letterstylevalue\v!reference\c!spaceafter+\letter!height!reference\relax]
\stopsetups
@@ -141,7 +92,7 @@
[\v!reference]
[\v!layer]
[\c!hoffset=125.7mm,
- \c!voffset=\letterstylevalue\v!address\c!voffset]
+ \c!voffset=\letterstylevalue{\v!address\v!layer}\c!voffset]
\setupletterstyle
[\v!reference]
@@ -206,7 +157,7 @@
[\v!reference]
[\v!layer]
[\c!hoffset=125.7mm,
- \c!voffset=\letterstylevalue\v!address\c!voffset]
+ \c!voffset=\letterstylevalue{\v!address\v!layer}\c!voffset]
\setupletterstyle
[\v!reference]
@@ -273,10 +224,36 @@
%D
%D \showsetup{startletter}
+% \def\startletter
+% {\bgroup\dodoubleempty\dostartletter}
+%
+% \def\dostartletter[#1][#2]%
+% {\ifsecondargument
+% \getparameters[\????ld][#1]%
+% \doifundefinedelse{\????ld\????ld#2}
+% {\setvalue{\????ld\c!toaddress}{#2}}
+% {\setvalue{\????ld\c!toaddress}{\getvalue{\????ld\????ld#2}}}%
+% \else\iffirstargument
+% \doifassignmentelse{#1}
+% {\getparameters[\????ld][#1]}
+% {\doifundefinedelse{\????ld\????ld#1}
+% {\setvalue{\????ld\c!toaddress}{#1}}
+% {\setvalue{\????ld\c!toaddress}{\getvalue{\????ld\????ld#1}}}}%
+% \fi\fi
+% \def\stopletter
+% {\directsetup{\v!letter:\v!place}\egroup}%
+% \dostartbuffer[lettercontent][startletter][stopletter]}
+
+\long\def\dosetbuffer[#1]#2\endbuffer % added \long
+ {\begingroup
+ \setcurrentbuffer{#1}%
+ \mksetbuffer{#2}%
+ \endgroup}
+
\def\startletter
{\bgroup\dodoubleempty\dostartletter}
-\def\dostartletter[#1][#2]%
+\long\def\dostartletter[#1][#2]#3\stopletter
{\ifsecondargument
\getparameters[\????ld][#1]%
\doifundefinedelse{\????ld\????ld#2}
@@ -289,31 +266,30 @@
{\setvalue{\????ld\c!toaddress}{#1}}
{\setvalue{\????ld\c!toaddress}{\getvalue{\????ld\????ld#1}}}}%
\fi\fi
- \def\stopletter
- {\directsetup{\v!letter:\v!place}\egroup\setupsubpagenumber[\c!state=\v!start]}%
- \dostartbuffer[lettercontent][startletter][stopletter]}
-
-%D Patched version of the \tex{flushbufferline} macro for \MKII,
-%D the changes are definition as long and removing of \tex{string}
-%D in the argument of the last write block.
-
-\long\def\flushbufferline#1%
- {\iftmpblockstarted
- \ifsegmentatebuffer
- \ifemptybufferline
- \immediate\write\tmpblocks{\string\stopbufferparagraph }%
- \immediate\write\tmpblocks{\string\startbufferparagraph}%
- \else
- \immediate\write\tmpblocks{#1}%
- \fi
- \else
- \immediate\write\tmpblocks{#1}%
- \fi
- \else
- \doifsomething{#1}
- {\tmpblockstartedtrue
- \immediate\write\tmpblocks{#1}}%
- \fi}
+ \setbuffer[lettercontent]#3\endbuffer
+ \directsetup{\v!letter:\v!place}\egroup}
+
+% %D Patched version of the \tex{flushbufferline} macro for \MKII,
+% %D the changes are definition as long and removing of \tex{string}
+% %D in the argument of the last write block.
+%
+% \long\def\flushbufferline#1%
+% {\iftmpblockstarted
+% \ifsegmentatebuffer
+% \ifemptybufferline
+% \immediate\write\tmpblocks{\string\stopbufferparagraph }%
+% \immediate\write\tmpblocks{\string\startbufferparagraph}%
+% \else
+% \immediate\write\tmpblocks{#1}%
+% \fi
+% \else
+% \immediate\write\tmpblocks{#1}%
+% \fi
+% \else
+% \doifsomething{#1}
+% {\tmpblockstartedtrue
+% \immediate\write\tmpblocks{#1}}%
+% \fi}
%D \macros
%D {startlettercontent}
diff --git a/Master/texmf-dist/tex/context/third/letter/interface/default.nri b/Master/texmf-dist/tex/context/third/letter/interface/default.nri
index edbf61f7d99..c417951987e 100644
--- a/Master/texmf-dist/tex/context/third/letter/interface/default.nri
+++ b/Master/texmf-dist/tex/context/third/letter/interface/default.nri
@@ -1,6 +1,6 @@
%D \module
%D [ file=default,
-%D version=2008.12.21,
+%D version=2009.02.14,
%D title=\CONTEXT\ Resume Interface,
%D subtitle=Default Interface,
%D author=Wolfgang Schuster,
@@ -11,11 +11,6 @@
\unprotect
-\startinterface all
- \setinterfacevariable {casual} {casual}
- \setinterfacevariable {classic} {classic}
-\stopinterface
-
%D The resume provides no own commands to write the information
%D for your curriculum vitae but you can use \CONTEXT's own
%D description, paragraph or table commands.
@@ -57,15 +52,31 @@
%D \stopcontent
%D \stoptyping
+% \def\startresume
+% {\bgroup\dosingleempty\dostartresume}
+%
+% \def\dostartresume[#1]%
+% {\iffirstargument
+% \getparameters[\????rd][#1]%
+% \fi
+% \def\stopresume{\directsetup{\v!resume:\v!place}\egroup\setupsubpagenumber[\c!state=\v!start]}%
+% \dostartbuffer[resumecontent][startresume][stopresume]}
+
+\long\def\dosetbuffer[#1]#2\endbuffer % added \long
+ {\begingroup
+ \setcurrentbuffer{#1}%
+ \mksetbuffer{#2}%
+ \endgroup}
+
\def\startresume
{\bgroup\dosingleempty\dostartresume}
-\def\dostartresume[#1]%
+\long\def\dostartresume[#1]#2\stopresume
{\iffirstargument
\getparameters[\????rd][#1]%
\fi
- \def\stopresume{\directsetup{\v!resume:\v!place}\egroup\setupsubpagenumber[\c!state=\v!start]}%
- \dostartbuffer[resumecontent][startresume][stopresume]}
+ \setbuffer[resumecontent]#2\endbuffer
+ \directsetup{\v!resume:\v!place}\egroup}
\def\startresumecontent
{\dostartbuffer[resumecontent][startresumecontent][stopresumecontent]}
@@ -85,7 +96,7 @@
\executeifdefined{\v!resume:\v!foot:\@@@@rsfootalternative}\donothing
\stopsetups
-\startsetups[\v!letter:\v!nexthead]
+\startsetups[\v!resume:\v!nexthead]
\executeifdefined{\v!resume:\v!nexthead:\@@@@rsnextheadalternative}\donothing
\stopsetups
diff --git a/Master/texmf-dist/tex/context/third/letter/interface/knuth.nli b/Master/texmf-dist/tex/context/third/letter/interface/knuth.nli
index 3234b7ebc7e..a4b4b17c85b 100644
--- a/Master/texmf-dist/tex/context/third/letter/interface/knuth.nli
+++ b/Master/texmf-dist/tex/context/third/letter/interface/knuth.nli
@@ -1,6 +1,6 @@
%D \module
%D [ file=knuth,
-%D version=2008.11.29,
+%D version=2009.01.23,
%D title=\CONTEXT\ Letter Interface,
%D subtitle=Lettformat Interface, % Donald Knuth's own letter format
%D author=Wolfgang Schuster,
@@ -37,6 +37,7 @@
\startsetups[\v!letter:\v!opening]
\obeylines
+ \def\par{\letterstylevalue\v!opening\c!separator}
\getbuffer[address]
\stopsetups
@@ -51,9 +52,15 @@
\leftskip=4in
\obeylines
- \def\par{\normalpar\vskip1cm\let\par\normalpar}
+ \def\par{\normalpar\vskip1cm\def\par{\normalpar\nowhitespace}}
\getbuffer[closing]
\stopsetups
+\startsetups[\v!letter:\v!nexthead]
+
+ \getvalue{\v!letter:\v!nexthead:\v!knuth}
+
+\stopsetups
+
\protect \endinput
diff --git a/Master/texmf-dist/tex/context/third/letter/interface/pragma.nli b/Master/texmf-dist/tex/context/third/letter/interface/pragma.nli
index f149c1ff7e0..eb4338c6bcd 100644
--- a/Master/texmf-dist/tex/context/third/letter/interface/pragma.nli
+++ b/Master/texmf-dist/tex/context/third/letter/interface/pragma.nli
@@ -1,6 +1,6 @@
%D \module
%D [ file=pragma,
-%D version=2008.02.17,
+%D version=2009.02.12,
%D title=\CONTEXT\ Letter Extension,
%D subtitle=Pragma Style,
%D author=Wolfgang Schuster,
@@ -14,6 +14,10 @@
\useletterstyle [pragma] % prefined layout
\useletterextension[pragma] % example text
+\setupletterstyle
+ [\v!reference]
+ [\c!alternative=\v!none]
+
\setvariables
[letter:head]
[graphic=]
@@ -29,22 +33,7 @@
\setvariables
[letter:data]
- [address=,
- subject=,
- date=,
- concerns=,
- residence=,
- reference=,
- opening=,
- initials=,
- prefix=,
- suffix=,
- informalname=,
- formalname=,
- content={\getbuffer[texletter]},
- author=,
- greeting=,
- appendices=]
+ [content={\getbuffer[texletter]}]
\startsetups[letter:address]
\def\\{\endgraf}\getvariable{letter:data}{address}
@@ -90,7 +79,7 @@
[\v!address]
[\v!layer]
[\c!line=\getvariable{letter:address}{line},
- \c!hoffset=\dimexpr\backspace-\linewidth-\getvariable{letter:address}{hoffset}\relax,
+ \c!hoffset=\dimexpr\backspace-\linewidth+\getvariable{letter:address}{hoffset}\relax,
\c!height=\getvariable{letter:address}{noflines}\lineheight]
\setupletterstyle