From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/68674 Path: news.gmane.org!not-for-mail From: Wolfgang Schuster Newsgroups: gmane.comp.tex.context Subject: Re: TOC : Chapter title under its number (separate lines) Date: Tue, 24 May 2011 13:42:41 +0200 Message-ID: <8B201B00-D1EE-45E0-855D-8E76D3F88C50@googlemail.com> References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 (Apple Message framework v1084) Content-Type: multipart/mixed; boundary="===============1553770725==" X-Trace: dough.gmane.org 1306237394 22377 80.91.229.12 (24 May 2011 11:43:14 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 24 May 2011 11:43:14 +0000 (UTC) To: mailing list for ConTeXt users Original-X-From: ntg-context-bounces@ntg.nl Tue May 24 13:43:10 2011 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1QOq0x-0001AY-UU for gctc-ntg-context-518@m.gmane.org; Tue, 24 May 2011 13:43:08 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id EDE58CAD22; Tue, 24 May 2011 13:43:02 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id bMzildX9VIwr; Tue, 24 May 2011 13:43:00 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 3122FCAD46; Tue, 24 May 2011 13:43:00 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id F3B7CCAD22 for ; Tue, 24 May 2011 13:42:58 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id qjhzNfOcaf7v for ; Tue, 24 May 2011 13:42:47 +0200 (CEST) Original-Received: from filter3-nij.mf.surf.net (filter3-nij.mf.surf.net [195.169.124.154]) by balder.ntg.nl (Postfix) with ESMTP id BD5C2CAD46 for ; Tue, 24 May 2011 13:42:47 +0200 (CEST) Original-Received: from mail-fx0-f41.google.com (mail-fx0-f41.google.com [209.85.161.41]) by filter3-nij.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id p4OBgkqH009060 for ; Tue, 24 May 2011 13:42:47 +0200 Original-Received: by fxm18 with SMTP id 18so6364397fxm.14 for ; Tue, 24 May 2011 04:42:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:from:mime-version:content-type:subject:date :in-reply-to:to:references:message-id:x-mailer; bh=cR2e8Z/GFLpoWJlY3l9U+I0Ru3Z2tZg21X6lykGy/L0=; b=S4R5W14Z1dPxCHBKDhi0cLZJAvfoTOfeG0ZzF/Pa7SWA1cQrQhpBTriCVumcw2CG+b 1DWtVpJcerrFsCCK3IqcjbcIFbXQpzPpb1+KxYwcMiCk0gcambyoRseiv6eIti6mtM51 ObjYWK8bLv77QQcezx/143TOoO1o4KKt0oxs8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=from:mime-version:content-type:subject:date:in-reply-to:to :references:message-id:x-mailer; b=mSTjKke53m7LDaH2tdD11VWg/F34kLZc7fT4qFWfk3+PqXHdzXE++sSruWOJB0lK+P nk/LyCGVZ9KZ1cheowgr0ZRy+msZ1+WKmFylhq7RNA3YZ3tJ6eWyxQXh6Mjdch1XoE/1 pFy6vX3Y8w+hO/vXBQ9YTia3N1pkZpWZ+51vA= Original-Received: by 10.223.89.134 with SMTP id e6mr2608104fam.147.1306237366021; Tue, 24 May 2011 04:42:46 -0700 (PDT) Original-Received: from [192.168.2.34] (p5B294589.dip.t-dialin.net [91.41.69.137]) by mx.google.com with ESMTPS id 22sm2700701fay.21.2011.05.24.04.42.43 (version=TLSv1/SSLv3 cipher=OTHER); Tue, 24 May 2011 04:42:44 -0700 (PDT) In-Reply-To: X-Mailer: Apple Mail (2.1084) X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=209.85.161.41; country=US; region=CA; city=Mountain View; postalcode=94043; latitude=37.4192; longitude=-122.0574; metrocode=807; areacode=650; http://maps.google.com/maps?q=37.4192,-122.0574&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 0dELnGKsB - 6cf885e6424c - 20110524 X-Scanned-By: CanIt (www . roaringpenguin . com) on 195.169.124.154 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.12 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 Xref: news.gmane.org gmane.comp.tex.context:68674 Archived-At: --===============1553770725== Content-Type: multipart/alternative; boundary=Apple-Mail-20--634836622 --Apple-Mail-20--634836622 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=windows-1252 Am 24.05.2011 um 00:59 schrieb Mathieu DUPONT: > Hi, >=20 > Is there a simple way to obtain the following result in the table of = content : >=20 > Contents > CHAPTER 1 > Title of chapter 2 > 1.1 Title of section 2 >=20 > (the chapter title underneath its number and left aligned, just like = everything else) >=20 > The following code used to do the job with MkII but it doesn't anymore = with MkIV : >=20 > \setuplabeltext[chapter=3DCHAPTER~] > \setuplist[chapter][label=3Dyes, style=3D{\blank[0cm]}] > =09 > \starttext >=20 > \startfrontmatter > \completecontent > \stopfrontmatter >=20 > \startbodymatter > \chapter{Title of chapter} > \section{Title of section} > \stopbodymatter >=20 > \stoptext=20 >=20 > Instead, I get something like this (I hope it turns out readable = through the email) : >=20 > Contents > CHAPTER 1 > Title of chapter 2 > 1.1 Title of section 2 >=20 > where the 2 lines of the chapter, together with their alignment with = the frame, get tossed to the right... I do get with MkIV the first example like you expect but = =93style=3D{\blank[0cm]}=94 is the wrong way. Such a layout can be easily done with your own = list-command for chapter but the labeltext is tricky: \setuplabeltext[chapter=3DCHAPTER~] % \define[3]\ChapterList % no label! % {#1\crlf#2\wordright{#3}} % \define[3]\ChapterList % fixed label, wrong for appendices! % {\labeltext{chapter}#1\crlf#2\wordright{#3}} \define[3]\ChapterList {\currentlistsymbol\crlf#2\wordright{#3}} \setuplist[chapter][label=3Dyes,alternative=3Dcommand,command=3D\ChapterLi= st] \starttext \startfrontmatter \completecontent \stopfrontmatter \startbodymatter \chapter{Title of chapter} \section{Title of section} \stopbodymatter \stoptext Wolfgang --Apple-Mail-20--634836622 Content-Transfer-Encoding: quoted-printable Content-Type: text/html; charset=windows-1252
Am 24.05.2011 um 00:59 schrieb = Mathieu DUPONT:

Hi,

Is there a simple way to obtain the = following result in the table of content = :

Contents
CHAPTER 1
Title = of chapter                 =        2
1.1    Title of section =               =  2

(the chapter title underneath its = number and left aligned, just like everything = else)

The following code used to do the job = with MkII but it doesn't anymore with MkIV = :

\setuplabeltext[chapter=3DCHAPTER~]
<= div>\setuplist[chapter][label=3Dyes, style=3D{\blank[0cm]}]
=
  Title of chapter         =                2
1.1    Title of = section               =  2

where the 2 lines of the chapter, = together with their alignment with the frame, get tossed to the = right...

I do get with = MkIV the first example like you expect but = =93style=3D{\blank[0cm]}=94
is the wrong way. Such a layout = can be easily done with your own list-command
for chapter but = the labeltext is = tricky:

\setuplabeltext[chapter=3DCHAPTER~]<= /div>

% \define[3]\ChapterList % no = label!
%   = {#1\crlf#2\wordright{#3}}

% = \define[3]\ChapterList % fixed label, wrong for appendices!
% =   = {\labeltext{chapter}#1\crlf#2\wordright{#3}}

\define[3]\ChapterList
  {\currentlistsymbol\crlf#2\= wordright{#3}}

\setuplist[chapter][label=3Dyes,al= ternative=3Dcommand,command=3D\ChapterList]

\star= ttext

\startfrontmatter
\completeconten= t
\stopfrontmatter

\startbodymatter
\chapter{Title of chapter}
\section{Title of = section}
\stopbodymatter

\stoptext

Wolfgang

= --Apple-Mail-20--634836622-- --===============1553770725== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ___________________________________________________________________________________ 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 ___________________________________________________________________________________ --===============1553770725==--