Re: [NTG-context] Some questions about my document
Hi Pablo, Thank you, it's very clear and it finally corresponds to what I want. The road is long in the learning of this formidable tool ! Fabrice 2017-08-27 12:43 GMT+02:00 Pablo Rodriguez: > On 08/27/2017 12:29 PM, Fabrice Couvreur wrote: > > Hi Pablo, > > > > " You have to define a new conversion set and use it for the prefix > > segments " > > It seems to me that's what I did. > > Hi Fabrice, > > I don’t think so. Two different conversion sets are required: one for > \setupheads[sectionconversionset=numbers] and a different one for > \defineenumeration[remark][prefixconversionset=digits]. > > If there is no different conversion set for the enumeration, you get the > default for the head. > > Here is the full sample: > > \mainlanguage[fr] > \setuphead[chapter][commandbefore={: }] > \setuphead[section][distance=\zeropoint, > commandbefore={\space\endash\space}] > \setuplabeltext[fr][chapter=Chapitre ] > > \definestructureconversionset > [structure] > [n, R, n, n, n] > > \definestructureconversionset > [digits] > [n, n, n, n, n] > > \setupheads[sectionconversionset=structure] > > \defineenumeration > [remark] > [ > text=Remark, > location=serried, > width=fit, > right={.~}, > prefix=yes, > prefixsegments=chapter, > prefixconversionset=digits, > %~ prefixsegments=section > ] > > \setupnumber[remark][way=bychapter] > > > \starttext > \dorecurse{3}{\startchapter > [title={First chapter}] > \dorecurse{3}{\startsection > [title={First section}] > \dorecurse{3}{\startremark \input ward \stopremark} > \stopsection} > \stopchapter} > \stoptext > > I hope it is clear now. Let me know if it isn’t. > > Cheers, > > Pablo > -- > http://www.ousia.tk > > ___ > 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 ___
Re: [NTG-context] Some questions about my document
On 08/27/2017 12:29 PM, Fabrice Couvreur wrote: > Hi Pablo, > > " You have to define a new conversion set and use it for the prefix > segments " > It seems to me that's what I did. Hi Fabrice, I don’t think so. Two different conversion sets are required: one for \setupheads[sectionconversionset=numbers] and a different one for \defineenumeration[remark][prefixconversionset=digits]. If there is no different conversion set for the enumeration, you get the default for the head. Here is the full sample: \mainlanguage[fr] \setuphead[chapter][commandbefore={: }] \setuphead[section][distance=\zeropoint, commandbefore={\space\endash\space}] \setuplabeltext[fr][chapter=Chapitre ] \definestructureconversionset [structure] [n, R, n, n, n] \definestructureconversionset [digits] [n, n, n, n, n] \setupheads[sectionconversionset=structure] \defineenumeration [remark] [ text=Remark, location=serried, width=fit, right={.~}, prefix=yes, prefixsegments=chapter, prefixconversionset=digits, %~ prefixsegments=section ] \setupnumber[remark][way=bychapter] \starttext \dorecurse{3}{\startchapter [title={First chapter}] \dorecurse{3}{\startsection [title={First section}] \dorecurse{3}{\startremark \input ward \stopremark} \stopsection} \stopchapter} \stoptext I hope it is clear now. Let me know if it isn’t. Cheers, Pablo -- http://www.ousia.tk ___ 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 ___
Re: [NTG-context] Some questions about my document
Hi Pablo, " You have to define a new conversion set and use it for the prefix segments " It seems to me that's what I did : \definestructureconversionset [structure] [numbers, Romannumerals, numbers, numbers, numbers] [numbers] \setupheads [sectionconversionset=structure] \defineenumeration [remark] [ text=Remark, location=serried, width=fit, right={.~}, prefix=yes, prefixsegments=chapter, ] \setupnumber[remark][way=bychapter] Only I get (which is normal according to the numbering chosen for the chapters : Romannumerals) Remark I.1. and I want this : Remark 1.1. Fabrice 2017-08-27 11:03 GMT+02:00 Pablo Rodriguez: > On 08/27/2017 12:14 AM, Fabrice Couvreur wrote: > > " I would like to have this : > > > > Chapitre I : Espaces probabilisés > > > > I.1 - Expérience aléatoire et univers " > > > > I did this : > > > > \setuphead[chapter][commandbefore={: }] > > \setuphead[section][distance=\zeropoint,commandbefore={\ > space\endash\space}] > > \setuplabeltext[en][chapter=Chapitre ] > > Hi Fabrice, > > I think it would be better to use French: > > \mainlanguage[fr] > \setuplabeltext[fr][chapter=Chapitre ] > > > But for this > > > > Remark 1.1. > > Remark 1.2 > > Remark 1.3 > > > > I do not find ! > > You have to define a new conversion set and use it for the prefix > segments (I added the section to the numbering): > > \definestructureconversionset > [digits] > [n, n, a, n, n] > [numbers] > > \defineenumeration > [remark] > [ > text=Remark, > location=serried, > width=fit, > right={.~}, > prefix=yes, > prefixsegments=chapter:section, > prefixconversionset=digits, > ] > > I hope it helps, > > Pablo > -- > http://www.ousia.tk > > ___ > 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 ___
Re: [NTG-context] Some questions about my document
On 08/27/2017 12:14 AM, Fabrice Couvreur wrote: > " I would like to have this : > > Chapitre I : Espaces probabilisés > > I.1 - Expérience aléatoire et univers " > > I did this : > > \setuphead[chapter][commandbefore={: }] > \setuphead[section][distance=\zeropoint,commandbefore={\space\endash\space}] > \setuplabeltext[en][chapter=Chapitre ] Hi Fabrice, I think it would be better to use French: \mainlanguage[fr] \setuplabeltext[fr][chapter=Chapitre ] > But for this > > Remark 1.1. > Remark 1.2 > Remark 1.3 > > I do not find ! You have to define a new conversion set and use it for the prefix segments (I added the section to the numbering): \definestructureconversionset [digits] [n, n, a, n, n] [numbers] \defineenumeration [remark] [ text=Remark, location=serried, width=fit, right={.~}, prefix=yes, prefixsegments=chapter:section, prefixconversionset=digits, ] I hope it helps, Pablo -- http://www.ousia.tk ___ 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 ___
Re: [NTG-context] Some questions about my document
" I would like to have this : Chapitre I : Espaces probabilisés I.1 - Expérience aléatoire et univers " I did this : \setuphead[chapter][commandbefore={: }] \setuphead[section][distance=\zeropoint,commandbefore={\space\endash\space}] \setuplabeltext[en][chapter=Chapitre ] But for this Remark 1.1. Remark 1.2 Remark 1.3 I do not find ! Fabrice 2017-08-26 12:27 GMT+02:00 Fabrice Couvreur: > Hi, > I have simplified the code, but I get : > > Remark I.1. > Remark I.2. > Remark I.3. > > instead : > > Remark 1.1. > Remark 1.2 > Remark 1.3 > > Thanks > Fabrice > > % > \definestructureconversionset > [structure] > [numbers, Romannumerals, numbers, numbers, numbers] > [numbers] > > \setupheads [sectionconversionset=structure] > > \defineenumeration > [remark] > [ > text=Remark, > location=serried, > width=fit, > right={.~}, > prefix=yes, > prefixsegments=chapter, > ] > > \setupnumber[remark][way=bychapter] > > \starttext > \startchapter > [title={First chapter}] > \startsection > [title={First section}] > \dorecurse{3}{\startremark \input ward \stopremark} > \stopsection > \stopchapter > \stoptext > % > > 2017-08-24 14:53 GMT+02:00 Fabrice Couvreur : > >> Hello, >> I would like to have this : >> >> >> >> Chapitre I : Espaces probabilisés >> >> I.1 - Expérience aléatoire et univers >> >> Définition 1.1 >> >> Définition 1.2 >> >> >> >> Thank you >> Fabrice >> >> % >> >> \definestructureconversionset >> [structure] >> [numbers, Romannumerals, numbers, numbers, numbers] >> [numbers] >> >> \setupheads [sectionconversionset=structure] >> >> \setupenumerations >> [ >> before={\blank[big]}, >> after={\blank[big]}, >> alternative=serried, >> width=broad, >> distance=0.5em, >> headstyle=bold, >> titlestyle=bold, >> prefix=chapter, >> way=bychapter, >> conversion=numbers] >> >> \defineenumeration >> [definition] >> [ >> text=Définition, >> title=yes, >> style=italic, >> list=all, >> listtext={Définition}] >> >> \starttext >> \startchapter[title=Espaces probabilisés] >> \startsection[title=Expérience aléatoire et univers] >> \startdefinition >> On appelle expérience aléatoire une expérience sur un système dont le >> résultat n'est pas connu d'avance et peut varier si on répète cette >> expérience. >> \stopdefinition >> \startdefinition >> On appelle univers l'ensemble des résultats possibles. Il est noté >> \math{\Omega}. >> \stopdefinition >> \stopchapter >> \stoptext >> >> %% >> > > ___ 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 ___
Re: [NTG-context] Some questions about my document
Hi, I have simplified the code, but I get : Remark I.1. Remark I.2. Remark I.3. instead : Remark 1.1. Remark 1.2 Remark 1.3 Thanks Fabrice % \definestructureconversionset [structure] [numbers, Romannumerals, numbers, numbers, numbers] [numbers] \setupheads [sectionconversionset=structure] \defineenumeration [remark] [ text=Remark, location=serried, width=fit, right={.~}, prefix=yes, prefixsegments=chapter, ] \setupnumber[remark][way=bychapter] \starttext \startchapter [title={First chapter}] \startsection [title={First section}] \dorecurse{3}{\startremark \input ward \stopremark} \stopsection \stopchapter \stoptext % 2017-08-24 14:53 GMT+02:00 Fabrice Couvreur: > Hello, > I would like to have this : > > > > Chapitre I : Espaces probabilisés > > I.1 - Expérience aléatoire et univers > > Définition 1.1 > > Définition 1.2 > > > > Thank you > Fabrice > > % > > \definestructureconversionset > [structure] > [numbers, Romannumerals, numbers, numbers, numbers] > [numbers] > > \setupheads [sectionconversionset=structure] > > \setupenumerations > [ > before={\blank[big]}, > after={\blank[big]}, > alternative=serried, > width=broad, > distance=0.5em, > headstyle=bold, > titlestyle=bold, > prefix=chapter, > way=bychapter, > conversion=numbers] > > \defineenumeration > [definition] > [ > text=Définition, > title=yes, > style=italic, > list=all, > listtext={Définition}] > > \starttext > \startchapter[title=Espaces probabilisés] > \startsection[title=Expérience aléatoire et univers] > \startdefinition > On appelle expérience aléatoire une expérience sur un système dont le > résultat n'est pas connu d'avance et peut varier si on répète cette > expérience. > \stopdefinition > \startdefinition > On appelle univers l'ensemble des résultats possibles. Il est noté > \math{\Omega}. > \stopdefinition > \stopchapter > \stoptext > > %% > ___ 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 ___
[NTG-context] Some questions about my document
Hello, I would like to have this : Chapitre I : Espaces probabilisés I.1 - Expérience aléatoire et univers Définition 1.1 Définition 1.2 Thank you Fabrice % \definestructureconversionset [structure] [numbers, Romannumerals, numbers, numbers, numbers] [numbers] \setupheads [sectionconversionset=structure] \setupenumerations [ before={\blank[big]}, after={\blank[big]}, alternative=serried, width=broad, distance=0.5em, headstyle=bold, titlestyle=bold, prefix=chapter, way=bychapter, conversion=numbers] \defineenumeration [definition] [ text=Définition, title=yes, style=italic, list=all, listtext={Définition}] \starttext \startchapter[title=Espaces probabilisés] \startsection[title=Expérience aléatoire et univers] \startdefinition On appelle expérience aléatoire une expérience sur un système dont le résultat n'est pas connu d'avance et peut varier si on répète cette expérience. \stopdefinition \startdefinition On appelle univers l'ensemble des résultats possibles. Il est noté \math{\Omega}. \stopdefinition \stopchapter \stoptext %% ___ 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 ___