From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/83371 Path: news.gmane.org!not-for-mail From: Michael Ash Newsgroups: gmane.comp.tex.context Subject: Some questions about the letter module Date: Fri, 12 Jul 2013 10:11:46 -0400 Message-ID: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============0158039730==" X-Trace: ger.gmane.org 1373638346 22418 80.91.229.3 (12 Jul 2013 14:12:26 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 12 Jul 2013 14:12:26 +0000 (UTC) To: ntg-context@ntg.nl Original-X-From: ntg-context-bounces@ntg.nl Fri Jul 12 16:12:28 2013 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Uxe5E-0005YL-IS for gctc-ntg-context-518@m.gmane.org; Fri, 12 Jul 2013 16:12:28 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id A981A101E9; Fri, 12 Jul 2013 16:12:27 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id lG18UjmaiSrW; Fri, 12 Jul 2013 16:12:25 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [IPv6:::1]) by balder.ntg.nl (Postfix) with ESMTP id 1872B101E5; Fri, 12 Jul 2013 16:12:25 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 70E8F101E5 for ; Fri, 12 Jul 2013 16:12:23 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id IJsM4kpTcURy for ; Fri, 12 Jul 2013 16:12:21 +0200 (CEST) Original-Received: from filter1-utr.mf.surf.net (filter1-utr.mf.surf.net [195.169.124.152]) by balder.ntg.nl (Postfix) with ESMTP id 2EDBC101E0 for ; Fri, 12 Jul 2013 16:12:11 +0200 (CEST) Original-Received: from mailhub1.oit.umass.edu (mailhub1.oit.umass.edu [128.119.103.53]) by filter1-utr.mf.surf.net (8.14.3/8.14.3/Debian-9.4) with ESMTP id r6CEC7Kg002347 for ; Fri, 12 Jul 2013 16:12:08 +0200 Original-Received: from mailhub1.oit.umass.edu (localhost.localdomain [127.0.0.1]) by localhost (Postfix) with SMTP id 13660140B29 for ; Fri, 12 Jul 2013 10:12:06 -0400 (EDT) Original-Received: from mail-ve0-f180.google.com (mail-ve0-f180.google.com [209.85.128.180]) (using TLSv1 with cipher RC4-SHA (128/128 bits)) (Client CN "smtp.gmail.com", Issuer "Google Internet Authority" (not verified)) (Authenticated sender: maash) by mailhub1.oit.umass.edu (Postfix) with ESMTPSA id BCB8C140B35 for ; Fri, 12 Jul 2013 10:12:05 -0400 (EDT) Original-Received: by mail-ve0-f180.google.com with SMTP id pa12so8300202veb.11 for ; Fri, 12 Jul 2013 07:12:06 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=mime-version:from:date:message-id:subject:to:content-type; bh=QEmMc0Tj9lH4A8wyTuMGpQmxOT3BqRvt7KJNI4nyo0Q=; b=JwFkKOH+J32TPyu66uAZy6HsHl6nHQzYepQnASf2bRWtrXut2CkSKAlv6SRjD1qazx +LgNQbGAIrLjm3DVobqE8jWQxj84BHhxysloAZqOdqijIQ4cdevLBBSYLGIqTqEtWD8o gbvWPgNC1RbAsVmPdD26t85S3hjc2687WduZpZ2SiStidPUSLL8RHG8XNs2Iej0QTSH+ wAoptls/+lyyTNZuJiLcSqO9Fth1q/fJ3Kt7MQEDW9HjwgaI8sTOqaMvZNnlvD5BGdXr LTwj+0VXbvkdKiEmjyJ1ttpVCUxA2NpZl/l5S2uqcYTBWUuRBzwgd7zSzYtFIH3ncY5Q OKbg== X-Received: by 10.52.17.196 with SMTP id q4mr20589159vdd.2.1373638326417; Fri, 12 Jul 2013 07:12:06 -0700 (PDT) Original-Received: by 10.52.121.116 with HTTP; Fri, 12 Jul 2013 07:11:46 -0700 (PDT) X-PMX-Version: 6.0.0.2142326, Antispam-Engine: 2.7.2.2107409, Antispam-Data: 2013.7.12.140023 X-PMX-Spam: Gauge=IIIIIIII, Probability=8%, Report=' BODYTEXTH_SIZE_10000_LESS 0, CTYPE_MULTIPART_NO_QUOTE 0, DATE_TZ_NA 0, URI_1ST_CAP_SUBDIR 0, WEBMAIL_SOURCE 0, __ANY_URI 0, __C230066_P5 0, __CP_URI_IN_BODY 0, __CT 0, __CTYPE_HAS_BOUNDARY 0, __CTYPE_MULTIPART 0, __CTYPE_MULTIPART_ALT 0, __HAS_FROM 0, __HAS_HTML 0, __HAS_MSGID 0, __MIME_HTML 0, __MIME_VERSION 0, __PHISH_SPEAR_HTTP_RECEIVED 0, __SANE_MSGID 0, __SUBJ_ALPHA_END 0, __TO_MALFORMED_2 0, __TO_NO_NAME 0, __URI_NO_WWW 0, __YOUTUBE_RCVD 0' X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=128.119.103.53; country=US; region=MA; city=Amherst; postalcode=01003; latitude=42.3804; longitude=-72.5231; metrocode=543; areacode=413; http://maps.google.com/maps?q=42.3804,-72.5231&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 07JXqc7gH - 2a2911fefed0 - 20130712 (trained as not-spam) X-Scanned-By: CanIt (www . roaringpenguin . com) X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.14 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ntg-context-bounces@ntg.nl Original-Sender: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:83371 Archived-At: --===============0158039730== Content-Type: multipart/alternative; boundary=bcaec50409fe7f031904e1511866 --bcaec50409fe7f031904e1511866 Content-Type: text/plain; charset=ISO-8859-1 Dear all, I am using the letter module that came with context. A sample of a basic letter is below; I have put in "dummy" for the logo and the signature, but these are working fine when I include the files. I have several questions: 1. to center the footer. 2. to lower the footer (closer to the bottom of the page) 3. to delete the word "Date" above the date. 4. to put the date *above *the recipient address (and how in general do I adjust the vertical space here). 5. to left-justify the date. 6. to control the foldmarks (for US-letter-size paper, omit, etc.) I have consulted http://wiki.contextgarden.net/Letter but there are many things I don't understand. What is the meaning of "alternative=example"; what is the option "preset=" in \setuplayer[foot] ? Also is there a better way to manage color? I \definecolor, \startcolor, \stopcolor, but maybe there is a better way to indicate that certain sections of the letter should be in a color. Thanks. Thank you very much for your guidance. Yours, Michael \usemodule[letter] \setuppapersize[letter][letter] \definecolor[maroon][h=990033] \setuplanguage [en] [date={dd, month, year}] \setupletteroptions [language=english, bodyfont={rm,12pt}, ] % Define logo for the first page \defineletterelement[layer][head][example]% {\framed[background=logohead,height=25mm,frame=off,align=left]% {\externalfigure[dummy]}} % We put our logo in the head \setupletterlayer[head] [alternative=example, x=9mm, y=10mm ] \defineletterelement[layer][foot][example]% {\startcolor[maroon] \ss \tfx The University of Massachusetts is an Affirmative Action/Equal Opportunity Institution. \stopcolor} \setupletterlayer[foot][ align=centerbottom, alternative=example] \setupletter[ name={Michael Ash}, dept={Department of Economics}, building={Thompson Hall}, street={200 Hicks Way}, city={Amherst, MA 01003-9277}, phone={+1-413-545-2590}, fax={+1-413-545-2921}, email={mash@econs.umass.edu} ] \defineletterelement[layer][location][example]% {\setuptabulate[bodyfont=normal] \startcolor[maroon] \starttabulate[|lw(.4\textwidth)|rw(.55\textwidth)|] \NC \tfa \sc University of Massachusetts \NC \NR \NC \tfa \sc Amherst \NC \correspondenceparameter{dept} \NR \NC \NC \NR \NC\correspondenceparameter{building} \NC tel \correspondenceparameter{phone} \NR \NC\correspondenceparameter{street} \NC fax \correspondenceparameter{fax}\NC\NR \NC\correspondenceparameter{city} \NC \correspondenceparameter{email} \NC\NR \stoptabulate \stopcolor} \setupletterlayer[location] [alternative=example, x=42mm, y=4mm ] \starttext \startletter[ toname={Professor Addressee}, toaddress={123 West Home Ave.\\Chicago, IL 60614}, opening={Dear Dr. Addressee,}, subject={A test letter}, closing={Best regards,}, signature={\externalfigure[dummy]\\Michael Ash} ] Thank you very much for the invitation I am truly honored by the opportunity and delighted to attend. I look forward to meeting you. Thank you again for the invitation. \stopletter \stoptext --bcaec50409fe7f031904e1511866 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Dear all,

I am using the letter module that came with context. = =A0 A sample of a basic letter is below; I have put in "dummy" fo= r the logo and the signature, but these are working fine when I include the= files.=A0

I have several questions:
  1. to center t= he footer. =A0
  2. to lower the =A0footer (closer to the bottom of the = page)
  3. to delete the word "Date" above the date.
  4. to put the date=A0above the recipient address (and how in general do= I adjust the vertical space here).
  5. to left-justify the date.
  6. to control the foldmarks (for US-lett= er-size paper, omit, etc.)
I have consulted=A0http://wiki.contextgarden.net/Let= ter=A0but there are many things I don't understand. =A0 What is the= meaning =A0of "alternative=3Dexample"; what is the option "= preset=3D" =A0in \setuplayer[foot] ?

Also is there a better way to manage color? =A0I \defin= ecolor, \startcolor, \stopcolor, but maybe there is a better way to indicat= e that certain sections of the letter should be in a color. =A0Thanks.

Thank you very much for your guidance.

Yours,
Michael


<= br>





\usemodule[letter]
\setuppapersize[letter][le= tter]
\definecolor[maroon][h=3D990033]

\= setuplanguage [en] [date=3D{dd, month, year}]=A0

\= setupletteroptions
[language=3Denglish,
bodyfont=3D{rm,12pt},
]
=

% Define logo for the first page
\definelette= relement[layer][head][example]%
{\framed[background=3Dlogohead,he= ight=3D25mm,frame=3Doff,align=3Dleft]%
{\externalfigure[dummy]}}

% We put our logo i= n the head
\setupletterlayer[head]
[alternative=3Dexamp= le,
x=3D9mm,
y=3D10mm
]

<= div> \defineletterelement[layer][foot][example]%
=A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0 {\startcolor[maroon] \ss =A0\tfx The University of Mass= achusetts is an Affirmative Action/Equal Opportunity Institution. \stopcolo= r}
=A0 =A0\setupletterlayer[foot][
=A0 =A0 =A0align=3Dcenterbottom,
=A0 =A0 =A0alternative=3Dex= ample]

\setupletter[
name=3D{Michael Ash= },
dept=3D{Department of Economics},
building=3D{Thomps= on Hall},
street=3D{200 Hicks Way},
city=3D{Amherst, MA 01003-9277},
<= div>phone=3D{+1-413-545-2590},
fax=3D{+1-413-545-2921},
email=3D{mash@econs.umass.edu}=
]
=A0 =A0
=A0 =A0\defineletterelement[layer][location][= example]%
=A0 =A0 =A0 =A0{\setuptabulate[bodyfont=3Dnormal]
=
=A0 =A0 =A0 =A0 =A0\startcolor[maroon]
=A0 =A0 =A0 =A0\start= tabulate[|lw(.4\textwidth)|rw(.55\textwidth)|]
=A0 =A0 =A0 =A0\NC \tfa \sc University of Massachusetts =A0 =A0 =A0 \N= C =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 \NR
=
=A0 =A0 =A0 =A0\NC \tfa \sc Amherst =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 =A0 =A0 =A0 =A0 \NC =A0\correspondenceparameter{dept} \NR
=A0= =A0 =A0 =A0\NC =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0= =A0 =A0 \NC =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 =A0 = =A0 \NR
=A0 =A0 =A0 =A0\NC\correspondenceparameter{building} \NC =A0tel \corre= spondenceparameter{phone} \NR
=A0 =A0 =A0 =A0\NC\correspondencepa= rameter{street} \NC fax \correspondenceparameter{fax}\NC\NR
=A0 = =A0 =A0 =A0\NC\correspondenceparameter{city} \NC \correspondenceparameter{e= mail} \NC\NR
=A0 =A0\stoptabulate
=A0\stopcolor}

=A0\setupletterlayer[location]
=A0[alternative=3Dexample,
<= div>=A0x=3D42mm,
=A0y=3D4mm
=A0]
=A0 =A0

\starttext
=A0 =A0
=A0 =A0\startletter[
=A0 =A0 =A0 =A0toname= =3D{Professor Addressee},
=A0 =A0 =A0 =A0toaddress=3D{123 West Ho= me Ave.\\Chicago, IL 60614},
=A0 =A0 =A0 =A0opening=3D{Dear Dr. A= ddressee,},
=A0 =A0 =A0 =A0subject=3D{A test letter},
=A0 =A0 =A0 =A0closing=3D{Best regards,},
=A0 =A0 =A0 =A0sig= nature=3D{\externalfigure[dummy]\\Michael Ash}
=A0 =A0 =A0 =A0]


=A0 =A0 =A0Thank you very much for t= he invitation I am truly honored by the
=A0 =A0 =A0opportunity and delighted to attend. I look forward to meet= ing
=A0 =A0 =A0you. =A0Thank you again for the invitation.
<= div>

=A0 =A0\stopletter

\stoptext
--bcaec50409fe7f031904e1511866-- --===============0158039730== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ --===============0158039730==--