From: Wolfgang Schuster <schuster.wolfgang@googlemail.com>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: Re: letter/correspondence module
Date: Fri, 3 Jul 2009 13:30:15 +0200 [thread overview]
Message-ID: <938656E8-7692-4E69-91E6-E18952F95357@gmail.com> (raw)
In-Reply-To: <6E2A4AA4-7E44-4166-978C-458DBAC50500@gmail.com>
Am 02.07.2009 um 15:56 schrieb Wolfgang Schuster:
>> I'm only writing letters in one language at a time, so will others.
>> It was only a suggestion to take the key as label as a fallback -
>> mostly it will be easy enough, and you don't need to define a
>> proper label.
>
> I have to check if this can be done (in a good way) and if I like
> this fallback method.
I had now time to think about and my answer is I won't support
keys in \setupletter as label names because it did not produce
the output I expect but what I can do is to modify the \setlettervalue
command in the following way.
\usemodule[letter]
\def\setlettervalue#1{\dodoubleempty\dosetlettervalue[#1]}
\unprotected\def\dosetlettervalue[#1][#2]#3%
{\ifsecondargument
\setuplabeltext[\currentmainlanguage][letter:#1=#2]%
%\else
% \setuplabeltext[\currentmainlanguage][letter:#1=#1]%
\fi
\setvalue{\????ld#1}{#3}}
% \setlettervalue{key}{value}
% \setlettervalue{key}[labeltext]{value}
\starttext
\setupletterstyle[reference][list={durchwahl,raum,misc,date}]
\setlettervalue{durchwahl}[Durchwahl]{0000/123456789}
\setlettervalue{raum}{1. Stock Zimmer 21}
\setlettervalue{misc}[]{another entry}
\startletter
\input ward
\stopletter
\stoptext
Wolfgang
___________________________________________________________________________________
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 : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
prev parent reply other threads:[~2009-07-03 11:30 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-06-28 21:12 Henning Hraban Ramm
2009-06-29 7:56 ` Henning Hraban Ramm
2009-06-29 9:51 ` Wolfgang Schuster
2009-06-29 15:31 ` Henning Hraban Ramm
2009-06-29 16:38 ` Wolfgang Schuster
2009-07-01 20:33 ` Henning Hraban Ramm
2009-07-01 20:55 ` Henning Hraban Ramm
2009-07-02 13:56 ` Wolfgang Schuster
2009-07-03 11:07 ` Henning Hraban Ramm
2009-07-03 11:35 ` Wolfgang Schuster
2009-07-03 11:30 ` Wolfgang Schuster [this message]
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=938656E8-7692-4E69-91E6-E18952F95357@gmail.com \
--to=schuster.wolfgang@googlemail.com \
--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).