2

I am trying to create a simple letter format that fits my double-window envelopes. I am able to position the location layer (in blue) successfully, but none of the parameters for the location layer (which should be in red and 1cm from the lefthand side of the paper) are having any effect on the layout.

\usemodule[letter]

\setupletter
  [name={Chris},
   address={My Address Line One\\My Address Line Two\\My Address Line Three},
   toname={John Doe},
   toaddress={Address Line 4\\Address Line 5\\Address Line 6}]

%% This layer is positioned correctly
\defineletterelement[layer][location][example]{\correspondenceparameter{address}\par}
\setupletterlayer[location][alternative=example,y=1.2cm,x=1cm,color=blue,style=sans]

%% This one is not
\defineletterelement[layer][addressee][example]%
    {\correspondenceparameter{toname}\\\correspondenceparameter{toaddress}\par}
\setupletterlayer[addressee][alternative=example,y=6cm,x=1cm,color=red,style=sans]

\setupletterlayer[topmark][y=9.1cm]

%% Delete the word "Date"
\setuplettertext[en][date=]

%% Move the date line so that it starts 9 cm from the top of the page
\setupletterlayer[reference][y=9cm]

\startletter
  [opening={Dear \correspondenceparameter{toname},},
   closing={Sincerely,},
   signature={\correspondenceparameter{name}}]

My letter text here. I can worry about the rest later.

\stopletter

1 Answer 1

3

It is address not addressee (wherever you got this from).

\usemodule[letter]

\setupletter
  [name={Chris},
   address={My Address Line One\\My Address Line Two\\My Address Line Three},
   toname={John Doe},
   toaddress={Address Line 4\\Address Line 5\\Address Line 6}]

%% This layer is positioned correctly
\defineletterelement[layer][location][example]{\correspondenceparameter{address}\par}
\setupletterlayer[location][alternative=example,y=1.2cm,x=1cm,color=blue,style=sans]

%% This one is not
\defineletterelement[layer][address][example]%
    {\correspondenceparameter{toname}\\\correspondenceparameter{toaddress}\par}
\setupletterlayer[address][alternative=example,y=6cm,x=1cm,color=red,style=sans]

\setupletterlayer[topmark][y=9.1cm]

%% Delete the word "Date"
\setuplettertext[en][date=]

%% Move the date line so that it starts 9 cm from the top of the page
\setupletterlayer[reference][y=9cm]

\startletter
  [opening={Dear \correspondenceparameter{toname},},
   closing={Sincerely,},
   signature={\correspondenceparameter{name}}]

My letter text here. I can worry about the rest later.

\stopletter

enter image description here

2
  • I got that from another answer here: tex.stackexchange.com/questions/118561/… -- I will add a note there.
    – Chris
    Commented Jul 19, 2017 at 18:57
  • @Chris That linked question is from 2013. It might well be that back then it actually was addressee. Commented Jul 19, 2017 at 20:40

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .