From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/7654 Path: main.gmane.org!not-for-mail From: Hans Hagen Newsgroups: gmane.comp.tex.context Subject: Re: ConTeXt XML question Date: Sun, 14 Apr 2002 22:15:21 +0200 Sender: owner-ntg-context@let.uu.nl Message-ID: <5.1.0.14.1.20020414221131.039fc308@server-1> References: <5.1.0.14.1.20020412155531.02d66008@server-1> <5.1.0.14.1.20020412171245.03a0a750@server-1> <5.1.0.14.1.20020413202740.05649438@server-1> NNTP-Posting-Host: coloc-standby.netfonds.no Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed X-Trace: main.gmane.org 1035398101 20965 80.91.224.250 (23 Oct 2002 18:35:01 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Wed, 23 Oct 2002 18:35:01 +0000 (UTC) Cc: NTG-ConTeXt Original-To: Tobias Burnus In-Reply-To: <3CB98E83.BE5F85DA@gmx.de> Xref: main.gmane.org gmane.comp.tex.context:7654 X-Report-Spam: http://spam.gmane.org/gmane.comp.tex.context:7654 At 04:13 PM 4/14/2002 +0200, Tobias Burnus wrote: >I try another example (see "XML in ConTeXt", page 13): >------------------------------------- >\version[temporary] > >\defineXMLenvironment [text] {\starttext} {\stoptext} >\defineXMLargument [title] {\chapter[\XMLpar{title}{label}{}]} >\defineXMLgrouped [tt] {\tt} > >\startXMLdata >First chapter >Second chapter >Third Chapter > >\stopXMLdata Ah, then why not init the attribute each time and use the shorter \XMLop (own parameter): \defineXMLargument [title] [label=] {\chapter[\XMLop{label}]} best combine this with: \setuphead[chapter][expansion=yes] An unreadable alternative (just illustrating expansion is): \defineXMLenvironmentpush [title] [label=] {} {\expanded{\chapter[\XMLop{label}]{\XMLflush{title}}}} Hans ------------------------------------------------------------------------- Hans Hagen | PRAGMA ADE | pragma@wxs.nl Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com ------------------------------------------------------------------------- information: http://www.pragma-ade.com/roadmap.pdf documentation: http://www.pragma-ade.com/showcase.pdf -------------------------------------------------------------------------