From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/83449 Path: news.gmane.org!not-for-mail From: Wolfgang Schuster Newsgroups: gmane.comp.tex.context Subject: Re: Some questions about the letter module Date: Wed, 17 Jul 2013 22:08:46 +0200 Message-ID: <0395100E-71DC-4F57-BBDF-EC0CA5E119EE@gmail.com> References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 (Mac OS X Mail 6.5 \(1508\)) Content-Type: multipart/mixed; boundary="===============1227629075==" X-Trace: ger.gmane.org 1374091761 861 80.91.229.3 (17 Jul 2013 20:09:21 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 17 Jul 2013 20:09:21 +0000 (UTC) Cc: Michael Ash To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Wed Jul 17 22:09:24 2013 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([5.39.185.229]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1UzY2O-0008AE-14 for gctc-ntg-context-518@m.gmane.org; Wed, 17 Jul 2013 22:09:24 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 9A492101EE; Wed, 17 Jul 2013 22:09:17 +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 7Stw4gNdID5E; Wed, 17 Jul 2013 22:09:06 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [IPv6:::1]) by balder.ntg.nl (Postfix) with ESMTP id 12701101E4; Wed, 17 Jul 2013 22:09:06 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id CC0B8101E4 for ; Wed, 17 Jul 2013 22:09:04 +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 m9X2-ypYs0h9 for ; Wed, 17 Jul 2013 22:08:44 +0200 (CEST) Original-Received: from filter4-ams.mf.surf.net (filter4-ams.mf.surf.net [192.87.102.72]) by balder.ntg.nl (Postfix) with ESMTP id 93EC0101E0 for ; Wed, 17 Jul 2013 22:08:44 +0200 (CEST) Original-Received: from mail-ea0-x233.google.com (mail-ea0-x233.google.com [IPv6:2a00:1450:4013:c01::233]) by filter4-ams.mf.surf.net (8.14.3/8.14.3/Debian-9.4) with ESMTP id r6HK8n98007584 for ; Wed, 17 Jul 2013 22:08:49 +0200 Original-Received: by mail-ea0-f179.google.com with SMTP id b15so1270056eae.38 for ; Wed, 17 Jul 2013 13:08:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=content-type:mime-version:subject:from:in-reply-to:date:cc :message-id:references:to:x-mailer; bh=AYYyVMJCpL14NM51hWiwBoHfL6UGHErc08TrHN1aCHM=; b=fuj4dH5vutXfp9j0gmE2jhF2unBV08DqLX1QHO7/8gvXGMsi3+lfsZWGXHI450G5m/ W+8x62D2v2pfGx/QlAhvVcgUWr/xZT9V2xitg1Kycg0plf8YdWcKJjsJpOg9lT752VcG Zvnu/o4/r8Yo0Ji3Yxv8X0lL6Eky4whh7aGSebgmv3N1tALEASE1vV7jbXK50l6LDMIu UmGZzz2+Q572sskqUkPoMiamt32f2o/ZNxWnbfXGYJyjTNm4/mGlNuyxmZDEYXxJt5KK rCk3u2EKSVDiTf0uRU1gegVggoxyGIZux8it8XRxlbGWQ7xgm7kSNawEACah0KsU+K43 RVFQ== X-Received: by 10.14.251.202 with SMTP id b50mr7916719ees.85.1374091729289; Wed, 17 Jul 2013 13:08:49 -0700 (PDT) Original-Received: from keima.localdomain (nrbg-4dbe77c8.pool.mediaWays.net. [77.190.119.200]) by mx.google.com with ESMTPSA id b7sm13371786eef.16.2013.07.17.13.08.47 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Wed, 17 Jul 2013 13:08:48 -0700 (PDT) In-Reply-To: X-Mailer: Apple Mail (2.1508) X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=2a00:1450:4013:c01::233; country=IE X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 01K1w8NMA - a8a0f87039cc - 20130717 (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 X-Spam-Report: 5.0 points; * 3.2 RCVD_ILLEGAL_IP Received: contains illegal IP address * 0.0 HTML_MESSAGE BODY: HTML included in message * 1.8 MIME_QP_LONG_LINE RAW: Quoted-printable line longer than 76 chars Xref: news.gmane.org gmane.comp.tex.context:83449 Archived-At: --===============1227629075== Content-Type: multipart/alternative; boundary="Apple-Mail=_D42E0CE4-2639-4584-B70B-CE3C8526C6D6" --Apple-Mail=_D42E0CE4-2639-4584-B70B-CE3C8526C6D6 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=windows-1252 Am 15.07.2013 um 18:34 schrieb Michael Ash : > Dear all, >=20 > (This is a repeat post. I apologize if that's rude, but I would = appreciate some assistance with the letter module or a pointer to = documentation. Thanks.) >=20 >=20 > 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.=20 >=20 > I have several questions: > to center the footer. =20 You can use the align key but you have to use a valid value, e.g. = middle. \setupletterlayer[foot][align=3Dmiddle] > to lower the footer (closer to the bottom of the page) You can control the distance between the margins and the footer block = with the x and y keys for \setupletterlayer. \setupletterlayer[foot][y=3D10pt] > to delete the word "Date" above the date. There is no key for \setupletterstyle etc. to disable/enable the label = but you can clear the label text. \setuplettertext[en][date=3D] > to put the date above the recipient address (and how in general do I = adjust the vertical space here). Move the layer up with the \setupletterlayer command. \setupletterlayer[reference][y=3D4cm] > to left-justify the date. When you want only the date in the reference line without the label use = alternative =93e=94 (you don=92t even have to clear the label because it = isn=92t used). \setupletterlayer[reference][alternative=3De] \setupletter[reference=3D\currentdate] > to control the foldmarks (for US-letter-size paper, omit, etc.) You can disable the marks with \setupletteroptions[marking=3Dno], the = position can be changed with \setupletterlayer[topmark][y=3D7cm] and = \setupletterlayer[topmark][y=3D14cm]. > I have consulted http://wiki.contextgarden.net/Letter but there are = many things I don't understand. What is the meaning of = "alternative=3Dexample"; With the alternative key you select one of the predefined or used = defined styles for the reference, footer etc. blocks. > what is the option "preset=3D" in \setuplayer[foot] ? When you want to change the origin for a layer from the top left margin = to the bottom left you have to change the value of the location and = corner keys. As there are few often used combination for the four = corners Hans predefined the with the \definelayerpreset command. These = predefined setups can be loaded with the preset key which saves some = typing. Below is a short example where I set first the arguments myself = and later use the predefined setups. \definelayer[test][width=3D\textwidth,height=3D\textheight] \starttext \setlayer[test][corner=3D{left,top},location=3D{right,bottom}]{LT 1} \setlayer[test][corner=3D{right,top},location=3D{left,bottom}]{RT 1} \setlayer[test][corner=3D{left,bottom},location=3D{right,top}]{LB 1} \setlayer[test][corner=3D{right,bottom},location=3D{left,top}]{RB 1} \flushlayer[test] \setlayer[test][preset=3Dlefttop]{LT 2} \setlayer[test][preset=3Drighttop]{RT 2} \setlayer[test][preset=3Dleftbottom]{LB 2} \setlayer[test][preset=3Drightbottom]{RB 2} \flushlayer[test] \stoptext > 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. All block elements provide color and style keys which can be used to set = the font and color for them, e.g. = \setupletterlayer[foot][color=3Dblue,style=3Dsans]. Wolfgang --Apple-Mail=_D42E0CE4-2639-4584-B70B-CE3C8526C6D6 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=windows-1252 mash@econs.umass.edu>:
Dear = all,

(This is a repeat = post. I apologize if that's rude, but I would appreciate some assistance = with the letter module or a pointer to documentation. = Thanks.)


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.  
You can = use the align key but you have to use a valid value, e.g. = middle.

\setupletterlayer[foot][align=3Dmiddle]
  1. to lower the  footer (closer to the bottom of the = page)
You can control the = distance between the margins and the footer block with the x and y keys = for = \setupletterlayer.

\setupletterlayer[foot][y=3D10= pt]
  1. to delete the word "Date" above the = date.
There is no key for = \setupletterstyle etc. to disable/enable the label but you can clear the = label = text.

\setuplettertext[en][date=3D]
  1. to put the date above the recipient address (and how in = general do I adjust the vertical space = here).
Move the layer up with the = \setupletterlayer = command.

\setupletterlayer[reference][y=3D4cm]
  1. to left-justify the = date.
When you want only the date = in the reference line without the label use alternative =93e=94 (you = don=92t even have to clear the label because it isn=92t = used).

\setupletterlayer[reference][alternative=3D= e]

\setupletter[reference=3D\currentdate]
  1. to control the foldmarks (for US-letter-size paper, = omit, etc.)
You can disable the = marks with \setupletteroptions[marking=3Dno], the position can be = changed with \setupletterlayer[topmark][y=3D7cm] = and \setupletterlayer[topmark][y=3D14cm].

I have consulted http://wiki.contextgarden.net/Letter but = there are many things I don't understand.   What is the meaning =  of = "alternative=3Dexample";

With = the alternative key you select one of the predefined or used defined = styles for the reference, footer etc. blocks.

what is the option = "preset=3D"  in \setuplayer[foot] ?

When you want to = change the origin for a layer from the top left margin to the bottom = left you have to change the value of the location and corner keys. As = there are  few often used combination for the four corners Hans = predefined the with the \definelayerpreset command. These predefined = setups can be loaded with the preset key which saves some typing. Below = is a short example where I set first the arguments myself and later use = the predefined = setups.

\definelayer[test][width=3D\textwidt= h,height=3D\textheight]

\starttext

=
\setlayer[test][corner=3D{left,top},location=3D{right,bottom}]{= LT = 1}

\setlayer[test][corner=3D{right,top},location=3D= {left,bottom}]{RT = 1}

\setlayer[test][corner=3D{left,bottom},locatio= n=3D{right,top}]{LB = 1}

\setlayer[test][corner=3D{right,bottom},locati= on=3D{left,top}]{RB = 1}

\flushlayer[test]

\se= tlayer[test][preset=3Dlefttop]{LT = 2}

\setlayer[test][preset=3Drighttop]{RT = 2}

\setlayer[test][preset=3Dleftbottom]{LB = 2}

\setlayer[test][preset=3Drightbottom]{RB = 2}

\flushlayer[test]

\st= optext


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.

All block elements provide color and = style keys which can be used to set the font and color for them, e.g. = \setupletterlayer[foot][color=3Dblue,style=3Dsans].

Wolfgang

= --Apple-Mail=_D42E0CE4-2639-4584-B70B-CE3C8526C6D6-- --===============1227629075== 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 ___________________________________________________________________________________ --===============1227629075==--