From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/30289 Path: news.gmane.org!not-for-mail From: Stuart Jansen Newsgroups: gmane.comp.tex.context Subject: ToC chapter/appendix labelling Date: Tue, 15 Aug 2006 08:05:33 -0600 Organization: Guru Labs, L.C. Message-ID: <1155650733.2823.6.camel@vision.buscaluz.org> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1226179190==" X-Trace: sea.gmane.org 1155650775 3852 80.91.229.2 (15 Aug 2006 14:06:15 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 15 Aug 2006 14:06:15 +0000 (UTC) Original-X-From: ntg-context-bounces@ntg.nl Tue Aug 15 16:06:10 2006 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 ciao.gmane.org with esmtp (Exim 4.43) id 1GCzYW-0006LT-PS for gctc-ntg-context-518@m.gmane.org; Tue, 15 Aug 2006 16:06:08 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id DABD01FDDF; Tue, 15 Aug 2006 16:06:07 +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 04015-03; Tue, 15 Aug 2006 16:06:02 +0200 (CEST) Original-Received: from ronja.vet.uu.nl (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id 7B73B1FDE1; Tue, 15 Aug 2006 16:06:01 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by ronja.ntg.nl (Postfix) with ESMTP id ABC361FDE1 for ; Tue, 15 Aug 2006 16:05:56 +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 01586-08-3 for ; Tue, 15 Aug 2006 16:05:51 +0200 (CEST) Original-Received: from mail.gurulabs.com (mail.gurulabs.com [67.137.148.7]) by ronja.ntg.nl (Postfix) with SMTP id 967811FDDF for ; Tue, 15 Aug 2006 16:05:49 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by mail.gurulabs.com (Postfix) with ESMTP id 0555B14BA8B for ; Tue, 15 Aug 2006 08:05:49 -0600 (MDT) X-Virus-Scanned: amavisd-new at gurulabs.com Original-Received: from mail.gurulabs.com ([127.0.0.1]) by localhost (mail.gurulabs.com [127.0.0.1]) (amavisd-new, port 10025) with ESMTP id 8n-FlKDA-rCp for ; Tue, 15 Aug 2006 08:05:43 -0600 (MDT) Original-Received: from h4607e89a.area7.spcsdns.net (h4607e89a.area7.spcsdns.net [70.7.232.154]) by mail.gurulabs.com (Postfix) with ESMTP for ; Tue, 15 Aug 2006 08:05:43 -0600 (MDT) Original-To: ntg-context@ntg.nl X-Mailer: Evolution 2.6.3 (2.6.3-1.fc5.5) X-Virus-Scanned: amavisd-new at ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.7 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:30289 Archived-At: --===============1226179190== Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="=-NOM0Y6wuUpnTIpTzRZJw" --=-NOM0Y6wuUpnTIpTzRZJw Content-Type: text/plain Content-Transfer-Encoding: quoted-printable I'm trying to achieve a specific table of contents layout. The problem I'm running into is adding the word "Chapter" before the chapter number and "Appendix" before the appendix letter. Below is what I've accomplished so far, any tips would be greatly appreciated. ----- \def\mychapterlistnumber#1{\vbox{% \doifnumberelse{#1}{Chapter}{Appendix} #1\crlf}} \def\mysectionlistnumber#1{\emspace\emspace} \def\mysectionlisttext#1{% \doifelse{#1}{Lab Tasks}{\hskip-1em\bf#1\hfilll}{#1}} \setuplist[chapter][width=3D1em,numberstyle=3Dbold,% numbercommand=3D\mychapterlistnumber,textstyle=3Dbold] \setuplist[section][width=3D2em,% numbercommand=3D\mysectionlistnumber,% textcommand=3D\mysectionlisttext] \starttext \bgroup{}Table of Contents\egroup\par \startcolumns[n=3D2,distance=3D.3in,balance=3Dno] \bgroup \placelist[chapter,section][criterium=3Dall,alternative=3Db] \egroup \stopcolumns \page \chapter{Foo} \section{Bar} \input knuth \startappendices \chapter{Corge} \section{Grault} \input knuth \stopappendices \stoptext ----- --=20 Stuart Jansen Guru Labs, L.C. --=-NOM0Y6wuUpnTIpTzRZJw Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.5 (GNU/Linux) iD8DBQBE4dStwTOJ4P81PNARAifQAKCBx97bTtinpfWuTmbhG2GNq60WJwCeK4DO VSBagow3PhF9kk2sWvN8zx8= =o4ba -----END PGP SIGNATURE----- --=-NOM0Y6wuUpnTIpTzRZJw-- --===============1226179190== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ ntg-context mailing list ntg-context@ntg.nl http://www.ntg.nl/mailman/listinfo/ntg-context --===============1226179190==--