[NTG-context] alternative command for lists

2012-08-03 Thread Willi Egger
Hi all,

At the moment I am busy to build a custom TOC. I stumble overt the fact, that 
ConTeXt seems to forget all parameters set in \setuplist once you issue 
alternative=command, command=…

Could anyone of you enlighten me whether I miss something?

Kind regards

Willi 

P.S. Please refer to the attached minimal example.


test-listcommand.tex
Description: Binary data
___
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
___

Re: [NTG-context] alternative command for lists

2012-08-03 Thread luigi scarso
On Fri, Aug 3, 2012 at 12:00 PM, Willi Egger cont...@boede.nl wrote:

 Hi all,

 At the moment I am busy to build a custom TOC. I stumble overt the fact,
 that ConTeXt seems to forget all parameters set in \setuplist once you
 issue alternative=command, command=…

 Could anyone of you enlighten me whether I miss something?

 Kind regards

 Willi

 P.S. Please refer to the attached minimal example.

 Hm I think I don't understand... if you issue your command, then it means
that you will provide all the other parameters, so  those ones  specified
in \setuplist are ignored.
-- 
luigi
___
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
___

Re: [NTG-context] alternative command for lists

2012-08-03 Thread Hans Hagen

On 3-8-2012 12:00, Willi Egger wrote:

Hi all,

At the moment I am busy to build a custom TOC. I stumble overt the fact, that 
ConTeXt seems to forget all parameters set in \setuplist once you issue 
alternative=command, command=…

Could anyone of you enlighten me whether I miss something?

Kind regards

Willi

P.S. Please refer to the attached minimal example.


indeed command is pretty basic ... btw, this is the future:

% there will be some helpers

\unprotect

\def\listboxproperties   {\strc_lists_get_reference_attribute}
\def\listrenderingsetup  {\the\t_lists_every_renderingtext}
\def\listrenderingsynchronize{\the\t_lists_every_renderingsynchronize}

\protect

% now you can say:

\definelistalternative
  [willi:1]
  [renderingsetup=willi:1]

\startsetups[willi:1]
\listparameter{before}
\vbox \listboxproperties{all} {
\forgetall
\dontleavehmode
\listrenderingsynchronize
\bgroup
\useliststyleandcolor{pagestyle}{pagecolor}
\currentlistentrypagenumber
\egroup
\hskip3em
\bgroup
\useliststyleandcolor{numberstyle}{numbercolor}
\currentlistsymbol
\egroup
.\space
\bgroup
\useliststyleandcolor{textstyle}{textcolor}
\currentlistentrytitle
\egroup
\par
}
\par
\listparameter{after}
\stopsetups

\setuplist
  [section]
  [before={\blank[line]},
   after=,
   style=\bf,
   numberstyle=\bf,
   textstyle=\bs,
   prefix=no,
   alternative=willi:1]

so, you *do* have access to \listparameter as well as 
\listrenderingparameter


the main tricky thing to keep in mind is the interation related 
properties and some synchronization


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
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
___