From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/90736 Path: news.gmane.org!not-for-mail From: Newsgroups: gmane.comp.tex.context Subject: Re: Help with \setuplist number width (for appendices) Date: Wed, 25 Mar 2015 10:59:51 +0000 Message-ID: <91F9F9EF-0CF3-4C01-8538-15AF65B67240@csiro.au> References: Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============1160293221==" X-Trace: ger.gmane.org 1427281257 10983 80.91.229.3 (25 Mar 2015 11:00:57 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 25 Mar 2015 11:00:57 +0000 (UTC) To: Original-X-From: ntg-context-bounces@ntg.nl Wed Mar 25 12:00:42 2015 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([5.39.185.229]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Yaj3B-0004sX-Nu for gctc-ntg-context-518@m.gmane.org; Wed, 25 Mar 2015 12:00:41 +0100 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id E3D6C10227 for ; Wed, 25 Mar 2015 12:00:40 +0100 (CET) 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 RZDyXDBgj31F for ; Wed, 25 Mar 2015 12:00:39 +0100 (CET) Original-Received: from balder.ntg.nl (localhost [IPv6:::1]) by balder.ntg.nl (Postfix) with ESMTP id 076BC10230 for ; Wed, 25 Mar 2015 12:00:06 +0100 (CET) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id ECA17101F9 for ; Wed, 25 Mar 2015 12:00:01 +0100 (CET) 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 Ew0vh-Zmc2UR for ; Wed, 25 Mar 2015 12:00:00 +0100 (CET) Original-Received: from filter5-til.mf.surf.net (filter5-til.mf.surf.net [194.171.167.221]) by balder.ntg.nl (Postfix) with ESMTP id DE4F0101E8 for ; Wed, 25 Mar 2015 12:00:00 +0100 (CET) Original-Received: from act-MTAout1.csiro.au (act-mtaout1.csiro.au [IPv6:2405:b000:e00:257::7:37]) by filter5-til.mf.surf.net (8.14.3/8.14.3/Debian-9.4) with ESMTP id t2PAxt1s020311 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NOT) for ; Wed, 25 Mar 2015 11:59:59 +0100 DKIM-Signature: v=1; a=rsa-sha256; c=simple/simple; d=csiro.au; i=@csiro.au; q=dns/txt; s=email; t=1427281199; x=1458817199; h=from:to:subject:date:message-id:references:in-reply-to: mime-version; bh=lT7SLloScynBZ7ypnSQzQEKiBqB32WjT8JabY2u+GlA=; b=Hj3dO5XjUcMQAiL/fHcxdII3eDwCsNMZTf2zkUX/fkdrlcGJps8TguzN oz7T13LF0UP5Z5EqVf5PcqQIJsui3zHNHvLzemWMTMSvsYr59Mcmjgr7u qZvOPU/ZSmXaKcR; X-SBRS: 4.0 X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: A+EeDgCZkRJVjACwBSSwhIATAJKcgCJcgkAhAYFNyUWBQQKBVjwQAQEBAQEBAQIOAQEBJ0KEFQEFgQkCAQg/BzIUEQIEE4gwyGoBAQgBAQEBAQEBG4shhH0WgwGBFgWaP5QshBBvgkMBAQE X-IPAS-Result: A+EeDgCZkRJVjACwBSSwhIATAJKcgCJcgkAhAYFNyUWBQQKBVjwQAQEBAQEBAQIOAQEBJ0KEFQEFgQkCAQg/BzIUEQIEE4gwyGoBAQgBAQEBAQEBG4shhH0WgwGBFgWaP5QshBBvgkMBAQE X-IronPort-AV: E=Sophos;i="5.11,465,1422882000"; d="scan'208,217";a="46684338" Original-Received: from exhtca02-cdc.nexus.csiro.au ([IPv6:2405:b000:601:13::247:22]) by act-ironport-int.csiro.au with ESMTP/TLS/AES256-SHA; 25 Mar 2015 21:59:52 +1100 Original-Received: from EXMBX05-CDC.nexus.csiro.au ([fe80::682c:6b57:ae86:1a30]) by ExHTCA02-CDC.nexus.csiro.au ([fe80::2c4b:396:7406:b161%12]) with mapi id 14.03.0210.002; Wed, 25 Mar 2015 21:59:52 +1100 Thread-Topic: [NTG-context] Help with \setuplist number width (for appendices) Thread-Index: AQHQZurRtrUWJF3fj0mfFgbn/uDogQ== In-Reply-To: Accept-Language: en-AU, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-originating-ip: [2405:b000:b00:212::64:21] X-Bayes-Prob: 0.0001 (Score 0, tokens from: ntg-context@ntg.nl, base:default, @@RPTN) X-CanIt-Geo: ip=2405:b000:e00:257::7:37; country=AU; latitude=-27.0000; longitude=133.0000; http://maps.google.com/maps?q=-27.0000,133.0000&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 0WO7KXVIT - 4f7c618faa6e - 20150325 (trained as not-spam) Received-SPF: pass (filter5-til.mf.surf.net: domain of prvs=5194af10b=Robin.Kirkham@csiro.au designates 2405:b000:e00:257::7:37 as permitted sender) receiver=filter5-til.mf.surf.net; client-ip=2405:b000:e00:257::7:37; envelope-from=; helo=act-MTAout1.csiro.au; identity=mailfrom X-Scanned-By: CanIt (www . roaringpenguin . com) X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.16 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: ntg-context-bounces@ntg.nl Original-Sender: "ntg-context" Xref: news.gmane.org gmane.comp.tex.context:90736 Archived-At: --===============1160293221== Content-Language: en-US Content-Type: multipart/alternative; boundary="_000_91F9F9EF0CF34C01853815AF65B67240csiroau_" --_000_91F9F9EF0CF34C01853815AF65B67240csiroau_ Content-Type: text/plain; charset="Windows-1252" Content-Transfer-Encoding: quoted-printable Am 23.03.2015 um 10:29 schrieb > >: Dear List, I=92m implementing a predefined document style. This requires chapters numb= ered 1, 2, 3 =85 and appendices numbered Appendix A, Appendix B, Appendix C= , =85 both in the actual heads and also the table of contents. The style also requires the chapter numbers in the table of contents to be = set in a 12mm column. The MWE below does all this, but for the appendices t= he number overflows the 12mm width, which is ugly of course. So I need to s= pecify either a width with some stretch so the list layout will adapt, or s= omehow be able to specify a different width for the appendix entries. Any help appreciated, Robin \setuplist[chapter][ width=3D12mm, % but want 30mm for appendices label=3Dyes, alternative=3Dc] \define[1]\ChapterlistNumber {\dowithnextbox {\ifdim\nextboxwd<12mm \simplealignedbox{12mm}{flushleft}{\flushnextbox}% \else \simplealignedbox{30mm}{flushleft}{\flushnextbox}% \fi} \hbox{#1}} \setuplist [chapter] [width=3D0pt, label=3Dyes, alternative=3Dc, numbercommand=3D\ChapterlistNumber] Wolfgang Thanks Wolfgang! I actually tried something a bit like this but couldn=92t= get it to work. The key is to set the width to 0pt in the \setuplist. Best wishes from Melbourne, Robin --_000_91F9F9EF0CF34C01853815AF65B67240csiroau_ Content-Type: text/html; charset="Windows-1252" Content-ID: <7833A9E50121D445B24B8C21ED42DE11@csiro.au> Content-Transfer-Encoding: quoted-printable
Am 23.03.2015 um 10:29 schrieb <Robin.Kirkham@csiro.au> <Robin.Kirkham@csiro.au>:

Dear List,

I=92m implementing a predefined document style. This requires chapters numb= ered 1, 2, 3 =85 and appendices numbered Appendix A, Appendix B, Appendix C= , =85 both in the actual heads and also the table of contents.

The style also requires the chapter numbers in the table of contents to be = set in a 12mm column. The MWE below does all this, but for the appendices t= he number overflows the 12mm width, which is ugly of course. So I need to s= pecify either a width with some stretch so the list layout will adapt, or somehow be able to specify a dif= ferent width for the appendix entries.

Any help appreciated,

Robin

\setuplist[chapter][
  width=3D12mm,         %= but want 30mm for appendices
  label=3Dyes,
  alternative=3Dc]

\define[= 1]\ChapterlistNumber
 {\= dowithnextbox
 &n= bsp;  {\ifdim\nextboxwd<12mm
 &n= bsp;     \simplealignedbox{12mm}{flushleft}{\flush= nextbox}%
 &n= bsp;   \else
 &n= bsp;     \simplealignedbox{30mm}{flushleft}{\flush= nextbox}%
 &n= bsp;   \fi}
 &n= bsp;  \hbox{#1}}

\setupli= st
 [c= hapter]
 [w= idth=3D0pt,
 &n= bsp;label=3Dyes,
 &n= bsp;alternative=3Dc,
 &n= bsp;numbercommand=3D\ChapterlistNumber]

Wolfgang=

Thanks Wolfgang!  I actually tried something a bit like this but = couldn=92t get it to work. The key is to set the width to 0pt in the \setup= list.

Best wishes from Melbourne,

Robin

--_000_91F9F9EF0CF34C01853815AF65B67240csiroau_-- --===============1160293221== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: base64 Content-Disposition: inline X19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX18KSWYgeW91ciBxdWVzdGlvbiBpcyBvZiBpbnRlcmVz dCB0byBvdGhlcnMgYXMgd2VsbCwgcGxlYXNlIGFkZCBhbiBlbnRyeSB0byB0aGUgV2lraSEKCm1h aWxsaXN0IDogbnRnLWNvbnRleHRAbnRnLm5sIC8gaHR0cDovL3d3dy5udGcubmwvbWFpbG1hbi9s aXN0aW5mby9udGctY29udGV4dAp3ZWJwYWdlICA6IGh0dHA6Ly93d3cucHJhZ21hLWFkZS5ubCAv IGh0dHA6Ly90ZXguYWFuaGV0Lm5ldAphcmNoaXZlICA6IGh0dHA6Ly9mb3VuZHJ5LnN1cGVsZWMu ZnIvcHJvamVjdHMvY29udGV4dHJldi8Kd2lraSAgICAgOiBodHRwOi8vY29udGV4dGdhcmRlbi5u ZXQKX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19fX19f X19fX19fX19fX19fX19fX19fX19fX19fX19fX18= --===============1160293221==--