[NTG-context] problem with \getparameters

luigi scarso luigi.scarso at gmail.com
Thu Feb 23 13:51:22 CET 2012


On Thu, Feb 23, 2012 at 1:39 PM, Wolfgang Schuster
<schuster.wolfgang at googlemail.com> wrote:
>
> Am 23.02.2012 um 13:31 schrieb luigi scarso:
>
>> Hm global  effect.. you can use a namespaced one
>>
>> \enabletrackers[lines.numbers]
>> \starttext
>> Lorem ipsum dolor sit amet, consetetur sadipscing elitr, sed diam nonumy eirmod
>> tempor invidunt ut labore et dolore magna aliquyam erat, sed diam voluptua. At
>> vero eos et accusam et justo duo dolores et ea rebum. Stet clita kasd
>> gubergren, no sea takimata sanctus est Lorem ipsum dolor sit amet.
>> \vrule width\textwidth height 1pt\par
>> \setuplinenumbering[Mine1][width=1cm,start=1]
>
> Better use first \define… and not \setup… which can result in an error for commands which
> use the commandhandler (e.g. \definelayout[<name>][…] vs. \setuplayout[<name>][…]).
yes, infact It was only to show the interference... I'm not sure if
it's a bug or not.

Anyway for this case \setup.. seems to inglobe \define...

\unexpanded\def\definelinenumbering
  {\dosingleempty\dodefinelinenumbering}

\def\dodefinelinenumbering[#1]%
  {\edef\currentlinenumbering{#1}%
   \mkdefinetextlinenumbering}

\unexpanded\def\setuplinenumbering
  {\dodoubleempty\dosetuplinenumbering}

\def\dosetuplinenumbering[#1][#2]%
  {\ifsecondargument
     \def\currentlinenumbering{#1}%
     \getparameters[\??rn#1][#2]%
   \else
     \let\currentlinenumbering\empty
     \getparameters[\??rn][#1]%
   \fi
   \mksetuptextlinenumbering}


>
> Wolfgang
>
> ___________________________________________________________________________________
> If your question is of interest to others as well, please add an entry to the Wiki!
>
> maillist : ntg-context at 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
> ___________________________________________________________________________________



-- 
luigi


More information about the ntg-context mailing list