ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* Total sectioning number
@ 2002-12-18 17:17 scarso luigi
  2002-12-19  8:25 ` Hans Hagen
  0 siblings, 1 reply; 2+ messages in thread
From: scarso luigi @ 2002-12-18 17:17 UTC (permalink / raw)


Is there any mode to get the total number of chapters (or sections
inside a chapter etc) as a counter, ie
\newcount\TotalChapterCount \TotalChapterCount=.....  ?

(I need this to make some operations with \textwidth and other
dimensions)

thanks

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: Total sectioning number
  2002-12-18 17:17 Total sectioning number scarso luigi
@ 2002-12-19  8:25 ` Hans Hagen
  0 siblings, 0 replies; 2+ messages in thread
From: Hans Hagen @ 2002-12-19  8:25 UTC (permalink / raw)


At 06:17 PM 12/18/2002 +0100, scarso luigi wrote:
>Is there any mode to get the total number of chapters (or sections
>inside a chapter etc) as a counter, ie
>\newcount\TotalChapterCount \TotalChapterCount=.....  ?
>
>(I need this to make some operations with \textwidth and other
>dimensions)


\starttext

\chapter{test}
\chapter{test}
\chapter{test}

\determinelistcharacteristics
   [chapter]
   [criterium=all]

surprise: there are \utilitylistlength\ chapters

\stoptext

you can use this trick to fetch the number of sections in a chapter etc as 
well

Hans
-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | pragma@wxs.nl
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                        information: http://www.pragma-ade.com/roadmap.pdf
                     documentation: http://www.pragma-ade.com/showcase.pdf
-------------------------------------------------------------------------

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2002-12-19  8:25 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2002-12-18 17:17 Total sectioning number scarso luigi
2002-12-19  8:25 ` Hans Hagen

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).