ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Hans Hagen <pragma@wxs.nl>
Subject: Re: beta (processaction & "|")
Date: Wed, 11 Oct 2006 22:02:44 +0200	[thread overview]
Message-ID: <452D4DE4.9010009@wxs.nl> (raw)
In-Reply-To: <452CCDB3.5080902@gmx.net>

Peter Rolf wrote:
> Hans Hagen wrote:
>   
>> Peter Rolf wrote:
>>     
>>> Hans Hagen wrote:
>>>   
>>>       
>>>> Peter Rolf wrote:
>>>>     
>>>>         
>>>>> \processaction[\FOO][
>>>>>   |=>,
>>>>>   unknown=>]
>>>>>   
>>>>>       
>>>>>           
>>>> hm, | and ~ are always special, put \string in fron tof it, or use \letterbar and \lettertilde 
>>>>
>>>>     
>>>>         
>>> hm, same error if I use \string| or \letterbar
>>>   
>>>       
>> do you have a minimal tes file?
>>
>> a solution may be
>>
>> \let\savedbarcommand=|
>>
>> \unexpanded\def|{\savedbarcommand}
>>
>>     
> Yes, this works.
>
> I've tried to create a minimal example, but in the end all points to the
> fact, that "|" is a special character. So even the use of "|" as
> argument of some macro like
>
>  \FOO[data={||abcx}]{..}
>
> is not recommended (without prior catcode change). I use the symbols as
> an abbreviation for different MP graphics, and it wouldn't make sense to
> write \letterbar every time. Looks like I have to choose a different symbol.
>   
still experimental is that you can change the catcodetable (pseudo in 
mkii, native in mkiv) but i won't bring up it's dirty details here


\let\savedbarcommand=|
 
\unexpanded\def|{\savedbarcommand}

this makes them unexpandable but still using ~ and | for such purposes is kind of tricky 

Hans 

-----------------------------------------------------------------
                                          Hans Hagen | PRAGMA ADE
              Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                             | www.pragma-pod.nl
-----------------------------------------------------------------

      reply	other threads:[~2006-10-11 20:02 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-10-09 12:34 Peter Rolf
2006-10-09 13:50 ` Hans Hagen
2006-10-09 14:03   ` Peter Rolf
2006-10-09 18:39     ` Hans Hagen
2006-10-09 20:34       ` Peter Rolf
2006-10-11 10:55       ` Peter Rolf
2006-10-11 20:02         ` Hans Hagen [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=452D4DE4.9010009@wxs.nl \
    --to=pragma@wxs.nl \
    --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).