From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/40766 Path: news.gmane.org!not-for-mail From: "Wolfgang Schuster" Newsgroups: gmane.comp.tex.context Subject: Re: Table of contents customization Date: Tue, 29 Apr 2008 11:36:33 +0200 Message-ID: <115224fb0804290236t4009a30dm9491234d8f469b3c@mail.gmail.com> References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable X-Trace: ger.gmane.org 1209461884 30238 80.91.229.12 (29 Apr 2008 09:38:04 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 29 Apr 2008 09:38:04 +0000 (UTC) To: "mailing list for ConTeXt users" Original-X-From: ntg-context-bounces@ntg.nl Tue Apr 29 11:38:40 2008 connect(): Connection refused Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from ronja.vet.uu.nl ([131.211.172.88] helo=ronja.ntg.nl) by lo.gmane.org with esmtp (Exim 4.50) id 1JqmIJ-00013h-Mf for gctc-ntg-context-518@m.gmane.org; Tue, 29 Apr 2008 11:38:39 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 11D6F1FBEB; Tue, 29 Apr 2008 11:37:57 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 00130-01-9; Tue, 29 Apr 2008 11:37:13 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 20B891FB7F; Tue, 29 Apr 2008 11:37:13 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 0A7BF1FB6D for ; Tue, 29 Apr 2008 11:37:11 +0200 (CEST) Original-Received: from ronja.ntg.nl ([127.0.0.1]) by localhost (smtp.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id 00695-01-2 for ; Tue, 29 Apr 2008 11:36:34 +0200 (CEST) Original-Received: from yw-out-1718.google.com (yw-out-1718.google.com [74.125.46.155]) by ronja.ntg.nl (Postfix) with ESMTP id ADC391FB7F for ; Tue, 29 Apr 2008 11:36:34 +0200 (CEST) Original-Received: by yw-out-1718.google.com with SMTP id 5so883062ywm.74 for ; Tue, 29 Apr 2008 02:36:33 -0700 (PDT) Original-Received: by 10.150.218.11 with SMTP id q11mr4813646ybg.82.1209461793814; Tue, 29 Apr 2008 02:36:33 -0700 (PDT) Original-Received: by 10.151.113.9 with HTTP; Tue, 29 Apr 2008 02:36:33 -0700 (PDT) In-Reply-To: Content-Disposition: inline X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.9 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl X-Virus-Scanned: amavisd-new at ntg.nl Xref: news.gmane.org gmane.comp.tex.context:40766 Archived-At: On Tue, Apr 29, 2008 at 11:23 AM, No=E9 Cuneo wrote: > Hi all, > > I've been using ConTeXT for quite a while now, and I am trying to > build my own customized environnment. > > I have some trouble customizing my content table. I tried everything I > could, including reading the manual twice over, and I still can't > figure out why none of my ideas will work! > > In fact, my configuration looks like this: > > \setupcombinedlist[content][level=3D4,alternative=3Dc] > \setuplist[chapter][width=3D7mm,style=3Dbold] > \setuplist[section][width=3D10mm,margin=3D10mm] > \setuplist[subsection] > [width=3D13mm,style=3Dslanted,pagestyle=3Dnormal,margin=3D21mm] > > What I would like is the number to be separated from the page name by > a ".", which would give something like: > > 1. Chapter name................. 32 > > I tried \setupcombinedlist[content][level=3D4,alternative=3Dc, > separator=3D{.}], but it doesn't work. Although 'separator' is > documented as the separator between the number and the pagename, it > appears to be the separator between the number and subnumbers, like, > with separator=3D{ppp}: > > 1 MyChapter ............ > 1ppp1 Mysection.......... > > Which is not quite what I expect! > > So i tried setting something like > > \def\mycommand#1{#1.} > \setupcombinedlist[content][level=3D4,alternative=3Dc, > numbercommand=3D{\mycommand}] > > Which works, except for the fact that when there is no number (like in > my frontmatter), the "." is shown anyway... So I naturally tried: > > \def\mycommand#1{\doifnotempty{#1}{#1.}} > > Which doesn't work! I still get something like > > . Preamble > 1. ChapterOne > 1.1 Section > > So even if no number is given, the doifnotempty block still is executed! > > I tried a lot of combinations, like > > \def\mycommand#1{\doifdefined{#1}{#1.}} or > \def\mycommand#1{\doifnot{#1}{}{#1.}} > > But none of these will compile... > > So at this point, I don't see any solution, which is why I really > would appreciate any suggestion! > > Thank you very much! \setuplist [chapter,section,subsection] [stopper=3D{.}] Greetings Wolfgang ___________________________________________________________________________= ________ If your question is of interest to others as well, please add an entry to t= he Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-cont= ext webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : https://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________= ________