ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Wolfgang Schuster <schuster.wolfgang@gmail.com>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Cc: Michael Ash <mash@econs.umass.edu>
Subject: Re: Some questions about the letter module
Date: Wed, 17 Jul 2013 22:08:46 +0200	[thread overview]
Message-ID: <0395100E-71DC-4F57-BBDF-EC0CA5E119EE@gmail.com> (raw)
In-Reply-To: <CAKTWfUNnW35z4uQNMRwWV-YjUAVO7VxEuta2qTHZvk4phgiXfg@mail.gmail.com>


[-- Attachment #1.1: Type: text/plain, Size: 3474 bytes --]


Am 15.07.2013 um 18:34 schrieb Michael Ash <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:
> to center the footer.  
You can use the align key but you have to use a valid value, e.g. middle.

\setupletterlayer[foot][align=middle]
> 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=10pt]
> 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=]
> 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=4cm]
> to left-justify the date.
When you want only the date in the reference line without the label use alternative “e” (you don’t even have to clear the label because it isn’t used).

\setupletterlayer[reference][alternative=e]

\setupletter[reference=\currentdate]
> to control the foldmarks (for US-letter-size paper, omit, etc.)
You can disable the marks with \setupletteroptions[marking=no], the position can be changed with \setupletterlayer[topmark][y=7cm] and \setupletterlayer[topmark][y=14cm].

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

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="  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=\textwidth,height=\textheight]

\starttext

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

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

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

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

\flushlayer[test]

\setlayer[test][preset=lefttop]{LT 2}

\setlayer[test][preset=righttop]{RT 2}

\setlayer[test][preset=leftbottom]{LB 2}

\setlayer[test][preset=rightbottom]{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=blue,style=sans].

Wolfgang


[-- Attachment #1.2: Type: text/html, Size: 5451 bytes --]

[-- Attachment #2: Type: text/plain, Size: 485 bytes --]

___________________________________________________________________________________
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
___________________________________________________________________________________

  reply	other threads:[~2013-07-17 20:08 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-07-12 14:11 Michael Ash
2013-07-12 14:26 ` Michael Ash
2013-07-12 16:44   ` Hans Hagen
2013-07-15 16:34 ` Michael Ash
2013-07-17 20:08   ` Wolfgang Schuster [this message]
     [not found]   ` <23497_1374091731_51E6F9D3_23497_15321_1_0395100E-71DC-4F57-BBDF-EC0CA5E119EE@gmail.com>
2013-07-18  1:12     ` Michael Ash
2013-07-18 12:57       ` Wolfgang Schuster
2013-07-19  0:06       ` Can this layout be done in Context? Russell Urquhart

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=0395100E-71DC-4F57-BBDF-EC0CA5E119EE@gmail.com \
    --to=schuster.wolfgang@gmail.com \
    --cc=mash@econs.umass.edu \
    --cc=ntg-context@ntg.nl \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).