ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
From: Willi Egger <context@boede.nl>
To: NTG-Context ConTeXt users <ntg-context@ntg.nl>
Subject: alternative command for lists
Date: Fri, 3 Aug 2012 12:00:45 +0200	[thread overview]
Message-ID: <811E378A-D090-448D-A4AA-9F0E22DF6C74@boede.nl> (raw)

[-- Attachment #1: Type: text/plain, Size: 335 bytes --]

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.

[-- Attachment #2: test-listcommand.tex --]
[-- Type: application/octet-stream, Size: 1186 bytes --]

% Context file
% Filename: test-listcommand.tex
% 
% 02-08-2012
% Copyright (c) 2012 BOEDE. All rights reserved.
%
% \nopdfcompression
% \enabletrackers[context.trace]
% \enabletrackers[system.jobfiles]


\define[3]\CGJSection{{\bf #3\hskip3em #1. #2}\par}
\define[3]\CGJSubsection{\it #3\hskip3em #1. #2\par}

% \define[3]\CGJsubsection{%
%   \framed
%     [width=\textwidth,align=flushleft,offset=0pt,style=\it]
%     {\hbox to 8mm{#3} #1. #2}}

\setuplist
	[section]
	[before={\blank[line]},
	after={},
	style=\bf,
  numberstyle=\bf,
  textstyle=\bf,
	prefix=no,
  % alternative=command,
  % command=\CGJSection%
   ]
\setuplist
  [subsection]
  [before={},
  after={},
  numberstyle=\it,
  tetxtstyle=\it,
  prefix=no,
  % alternative=command,
  % command=\CGJSubsection%
  ] 

%\showframe

\starttext
\startsubject[title=Index]
  \placelist[section,subsection]
\stopsubject
\page
\dorecurse{3}{%
\startsection[title=Ward]
  \input ward
  \startsubsection[title=Weisman]
    \input weisman
   \stopsubsection
   \startsubsection[title=Bryson]
     \input bryson
    \stopsubsection
    \startsubsection[title=Linden]
      \input linden
     \stopsubsection
\stopsection}

\stoptext

[-- Attachment #3: Type: text/plain, Size: 485 bytes --]

___________________________________________________________________________________
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
___________________________________________________________________________________

             reply	other threads:[~2012-08-03 10:00 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-03 10:00 Willi Egger [this message]
2012-08-03 10:25 ` luigi scarso
2012-08-03 11:05 ` Hans Hagen

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=811E378A-D090-448D-A4AA-9F0E22DF6C74@boede.nl \
    --to=context@boede.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).