Hello, The number of the sections is 1 2 3 ... How to make it 3 5 6 ... ? Thank you Fabrice
On 2017-09-12 11:06, Fabrice Couvreur wrote:
Hello, The number of the sections is 1 2 3 ... How to make it 3 5 6 ... ? Thank you Fabrice
___________________________________________________________________________________ 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___________________________________________________________________________________
There are at least two ways. You can create two hidden sections before your first section, effectively adding two to the section number, or you can explicitly set the section number, which allows increments and decrements. See Pablo’s reply to a similar query at https://www.mail-archive.com/ntg-context@ntg.nl/msg78173.html, and see the relevant wiki pages at setupheadnumber http://wiki.contextgarden.net/Command/setupheadnumber and definehead http://wiki.contextgarden.net/Command/definehead. -- Rik
You can enable manual numbering \setuphead[section][ownnumber=yes] \starttext \section{3}{Section 1} \section{5}{Section 1} \section{6}{Section 1} \stoptext or use a custom conversion \defineconversion[drunk][3,5,6] \setuphead[section][conversion=drunk] \starttext \dorecurse{3}{\expanded{\section{Section \recurselevel}}} \stoptext Wolfgang
Fabrice Couvreur mailto:fabrice1.couvreur@gmail.com 12. September 2017 um 17:06 Hello, The number of the sections is 1 2 3 ... How to make it 3 5 6 ... ? Thank you Fabrice ___________________________________________________________________________________ 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ___________________________________________________________________________________
Hi,
Thank you Wolgang for your solution
Thanks also to Rik
Fabrice
2017-09-12 19:59 GMT+02:00 Wolfgang Schuster
You can enable manual numbering
\setuphead[section][ownnumber=yes]
\starttext
\section{3}{Section 1}
\section{5}{Section 1}
\section{6}{Section 1}
\stoptext
or use a custom conversion
\defineconversion[drunk][3,5,6]
\setuphead[section][conversion=drunk]
\starttext
\dorecurse{3}{\expanded{\section{Section \recurselevel}}}
\stoptext
Wolfgang
Fabrice Couvreur
12. September 2017 um 17:06 Hello, The number of the sections is 1 2 3 ... How to make it 3 5 6 ... ? Thank you Fabrice ____________________________________________________________ _______________________ 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ____________________________________________________________ _______________________
____________________________________________________________ _______________________ 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://context.aanhet.net archive : https://bitbucket.org/phg/context-mirror/commits/ wiki : http://contextgarden.net ____________________________________________________________ _______________________
Hello,
BTW, I needed to add a section numbered by zero some time ago;
there is a solution which uses "conversion" parameter.
When one needs to add a zero based section "manually" (ad hoc), there is another solution, too:
----
\starttext
\bgroup
\setuphead[section][ownnumber=yes]
\section{0}{Zero}
\subsection{SSecA}
\setupheadnumber[section][0]
\egroup
%
\section{Sec}
\subsection{SSecB}
\section{Sec2}
\stoptext
----
Best regards,
Lukas
On Tue, 12 Sep 2017 19:59:30 +0200, Wolfgang Schuster
You can enable manual numbering
\setuphead[section][ownnumber=yes]
\starttext
\section{3}{Section 1}
\section{5}{Section 1}
\section{6}{Section 1}
\stoptext
or use a custom conversion
\defineconversion[drunk][3,5,6]
\setuphead[section][conversion=drunk]
\starttext
\dorecurse{3}{\expanded{\section{Section \recurselevel}}}
\stoptext
Wolfgang
-- Ing. Lukáš Procházka | mailto:LPr@pontex.cz Pontex s. r. o. | mailto:pontex@pontex.cz | http://www.pontex.cz | IDDS:nrpt3sn Bezová 1658 147 14 Praha 4 Mob.: +420 702 033 396
participants (4)
-
Fabrice Couvreur
-
Procházka Lukáš Ing.
-
Rik Kabel
-
Wolfgang Schuster