[NTG-context] Problem with exponent

2023-04-28 Thread Fabrice Couvreur via ntg-context
Hi,
I want to write x'² . Only, I get x²'.
Thanks
Fabrice

\starttext
\m{{x'}²+{y'}²}
\stoptext
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Table of contents not appearing.

2023-04-21 Thread Fabrice Couvreur via ntg-context
An extra parenthesis in a section title seems to be the problem but I'm not
sure. I compiled the file line by line and it works now.
Thanks
Fabrice

Le ven. 21 avr. 2023 à 14:37, Hans Hagen via ntg-context 
a écrit :

> On 4/21/2023 5:05 PM, Fabrice Couvreur via ntg-context wrote:
> > It's chapter_5 that's the problem, but how do you know what's causing
> > the table of contents not to appear ?
> depends on the error : the toc comes from the tuc file so if that one is
> not made ...
>
> -
>Hans Hagen | PRAGMA ADE
>Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
> -
>
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Table of contents not appearing.

2023-04-21 Thread Fabrice Couvreur via ntg-context
It's chapter_5 that's the problem, but how do you know what's causing the
table of contents not to appear ?

Le ven. 21 avr. 2023 à 14:42, Fabrice Couvreur 
a écrit :

> Hi Hans,
> Alright, I'll compile by integrating one component at a time to figure out
> which one is causing the problem.
> Thanks.
> Fabrice
>
> Le jeu. 20 avr. 2023 à 15:52, Hans Hagen via ntg-context <
> ntg-context@ntg.nl> a écrit :
>
>> On 4/20/2023 6:59 PM, Fabrice Couvreur via ntg-context wrote:
>> > Hi,
>> > I don't see why the table of contents does not appear. On the other
>> > hand, the 12 chapters are present.
>>
>> \startproduct[terminale-manual]
>>
>>  \startfrontmatter
>>  \starttitle[title=Table des matières]
>>  \placelist
>> [chapter,section,subsection,subsubsection]
>> [criterium=all,
>> interaction=all,
>>  alternative=c]
>>  \stoptitle
>>  \stopfrontmatter
>>
>>  \startbodymatter
>>  \chapter{xxx}
>>  \stopbodymatter
>>
>> \stopproduct
>>
>> shows a table of contents so it must be something in your components
>>
>> > Fabrice
>> >
>> >
>> > \startproduct[terminale-manual]
>> >
>> >\project[terminale-environment]
>> >\startfrontmatter
>> >
>> >  \setuppagenumbering
>> > [location=]
>> >
>> >  \definefont
>> >[ChapterTextStyle]
>> >[SansBold*default sa 2.2]
>> >
>> >  \setuphead
>> >[title]
>> >[style=ChapterTextStyle,
>> > align=flushright]
>> >
>> >  \setuplist
>> > [chapter]
>> > [style=bold,
>> >  alternative=b,
>> >  width=1em]
>> >
>> >  \setuplist
>> > [section]
>> > [margin=1em,
>> >  width=1.75em]
>> >
>> >  \setuplist
>> > [subsection]
>> > [margin=2.75em,
>> >  width=2.25em,
>> > distance=\spaceamount]
>> >
>> >
>> >  \starttitle[title=Table des matières]
>> >
>> >   \placelist
>> > [chapter,section,subsection,subsubsection]
>> > [criterium=all,
>> > interaction=all,
>> >  alternative=c]
>> >
>> >\stoptitle
>> >
>> >  \stopfrontmatter
>> >
>> >  \startbodymatter
>> >\component[chapitre_1]
>> >\component[chapitre_2]
>> >\component[chapitre_3]
>> >\component[chapitre_4]
>> >\component[chapitre_5]
>> >\component[chapitre_6]
>> >\component[chapitre_7]
>> >\component[chapitre_8]
>> >\component[chapitre_9]
>> >\component[chapitre_10]
>> >\component[chapitre_11]
>> >\component[chapitre_12]
>> >  \stopbodymatter
>> >
>> > \stopproduct
>> >
>> >
>> >
>> ___
>> > If your question is of interest to others as well, please add an entry
>> to the Wiki!
>> >
>> > maillist : ntg-context@ntg.nl /
>> https://www.ntg.nl/mailman/listinfo/ntg-context
>> > webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
>> > archive  : https://bitbucket.org/phg/context-mirror/commits/
>> > wiki : https://contextgarden.net
>> >
>> ___
>>
>> --
>>
>> -
>>Hans Hagen | PRAGMA ADE
>>Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
>> tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
>> -
>>
>>
>> ___
>> If your question is of interest to others as well, please add an entry to
>> the Wiki!
>>
>> maillist : ntg-context@ntg.nl /
>> https://www.ntg.nl/mailman/listinfo/ntg-context
>> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
>> archive  : https://bitbucket.org/phg/context-mirror/commits/
>> wiki : https://contextgarden.net
>>
>> ___
>>
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Table of contents not appearing.

2023-04-21 Thread Fabrice Couvreur via ntg-context
Hi Hans,
Alright, I'll compile by integrating one component at a time to figure out
which one is causing the problem.
Thanks.
Fabrice

Le jeu. 20 avr. 2023 à 15:52, Hans Hagen via ntg-context 
a écrit :

> On 4/20/2023 6:59 PM, Fabrice Couvreur via ntg-context wrote:
> > Hi,
> > I don't see why the table of contents does not appear. On the other
> > hand, the 12 chapters are present.
>
> \startproduct[terminale-manual]
>
>  \startfrontmatter
>  \starttitle[title=Table des matières]
>  \placelist
> [chapter,section,subsection,subsubsection]
> [criterium=all,
> interaction=all,
>  alternative=c]
>  \stoptitle
>  \stopfrontmatter
>
>  \startbodymatter
>  \chapter{xxx}
>  \stopbodymatter
>
> \stopproduct
>
> shows a table of contents so it must be something in your components
>
> > Fabrice
> >
> >
> > \startproduct[terminale-manual]
> >
> >\project[terminale-environment]
> >\startfrontmatter
> >
> >  \setuppagenumbering
> > [location=]
> >
> >  \definefont
> >[ChapterTextStyle]
> >[SansBold*default sa 2.2]
> >
> >  \setuphead
> >[title]
> >[style=ChapterTextStyle,
> > align=flushright]
> >
> >  \setuplist
> > [chapter]
> > [style=bold,
> >  alternative=b,
> >  width=1em]
> >
> >  \setuplist
> > [section]
> > [margin=1em,
> >  width=1.75em]
> >
> >  \setuplist
> > [subsection]
> > [margin=2.75em,
> >  width=2.25em,
> > distance=\spaceamount]
> >
> >
> >  \starttitle[title=Table des matières]
> >
> >   \placelist
> > [chapter,section,subsection,subsubsection]
> > [criterium=all,
> > interaction=all,
> >  alternative=c]
> >
> >\stoptitle
> >
> >  \stopfrontmatter
> >
> >  \startbodymatter
> >\component[chapitre_1]
> >\component[chapitre_2]
> >\component[chapitre_3]
> >\component[chapitre_4]
> >\component[chapitre_5]
> >\component[chapitre_6]
> >\component[chapitre_7]
> >\component[chapitre_8]
> >\component[chapitre_9]
> >\component[chapitre_10]
> >\component[chapitre_11]
> >\component[chapitre_12]
> >  \stopbodymatter
> >
> > \stopproduct
> >
> >
> >
> ___
> > If your question is of interest to others as well, please add an entry
> to the Wiki!
> >
> > maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> > webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> > archive  : https://bitbucket.org/phg/context-mirror/commits/
> > wiki : https://contextgarden.net
> >
> ___
>
> --
>
> -
>Hans Hagen | PRAGMA ADE
>Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
> -
>
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Table of contents not appearing.

2023-04-20 Thread Fabrice Couvreur via ntg-context
Hi,
I don't see why the table of contents does not appear. On the other hand,
the 12 chapters are present.
Thanks
Fabrice


\startproduct[terminale-manual]

  \project[terminale-environment]
  \startfrontmatter

\setuppagenumbering
   [location=]

\definefont
  [ChapterTextStyle]
  [SansBold*default sa 2.2]

\setuphead
  [title]
  [style=ChapterTextStyle,
   align=flushright]

\setuplist
   [chapter]
   [style=bold,
alternative=b,
width=1em]

\setuplist
   [section]
   [margin=1em,
width=1.75em]

\setuplist
   [subsection]
   [margin=2.75em,
width=2.25em,
   distance=\spaceamount]


\starttitle[title=Table des matières]

 \placelist
   [chapter,section,subsection,subsubsection]
   [criterium=all,
   interaction=all,
alternative=c]

  \stoptitle

\stopfrontmatter

\startbodymatter
  \component[chapitre_1]
  \component[chapitre_2]
  \component[chapitre_3]
  \component[chapitre_4]
  \component[chapitre_5]
  \component[chapitre_6]
  \component[chapitre_7]
  \component[chapitre_8]
  \component[chapitre_9]
  \component[chapitre_10]
  \component[chapitre_11]
  \component[chapitre_12]
\stopbodymatter

\stopproduct
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] About \blackrule

2023-04-20 Thread Fabrice Couvreur via ntg-context
Hi Wolfgang,
Thanks a lot.
Fabrice

Le mer. 19 avr. 2023 à 15:05, Wolfgang Schuster via ntg-context <
ntg-context@ntg.nl> a écrit :

> Fabrice Couvreur via ntg-context schrieb am 19.04.2023 um 17:01:
>
> Hi,
> The idea is to have a black square whose height is that of the number 3.
> Thanks
> Fabrice
>
> \setupbodyfont[12pt,pagella]
> \starttext
>  \blackrule[width=0.71em,height=0.71em]37254H
>
>
> \blackrule[width=\wdofstring{3},height=\htofstring{3},depth=\dpofstring{3}]
>
> Wolfgang
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] About \blackrule

2023-04-19 Thread Fabrice Couvreur via ntg-context
Hi,
The idea is to have a black square whose height is that of the number 3.
Thanks
Fabrice

\setupbodyfont[12pt,pagella]
\starttext
 \blackrule[width=0.71em,height=0.71em]37254H
\stoptext
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Userdata environment

2023-04-03 Thread Fabrice Couvreur via ntg-context
Hi,
I have already created a thread on the subject and Wolgang, Marco and Taco
have replied but the userdata environment is not yet clear to me. I would
like, if possible, to write a definition, a property or a theorem on the
left and illustrate it in the right margin with an example. In the code
below, the second example is on the second page and not next to the second
definition.
Thanks.
Fabrice


\
useMPlibrary[dum]

\setuppapersize[A4]

\mainlanguage
  [fr]

\setuppagenumbering
 [alternative=doublesided]

\setuplayout
  [width=12cm,
   rightmargin=60mm]


\setupenumerations
  [before={\blank},
   after={\blank},
   alternative=serried,
   distance=0.5em,
   title=yes,
   titleleft=,
   titleright=,
   titlestyle=normal,
   headcommand=\groupedcommand{}{.},
   numbercommand=\groupedcommand{}{},
   titlecommand=\groupedcommand{(}{)},
   width=fit]

\defineenumeration
   [definition]
   [text=Définition,
number=no,
style=italic]

\defineenumeration
   [exemple]
   [text=Exemple,
number=no,
style=normal]

\definemargindata[marginfigure][inright]
\setupmargindata [marginfigure][command=\vbox,align=middle,stack=yes]

\defineuserdata [margintext] [alternative=margintext]

\defineuserdataalternative [margintext] [renderingsetup=userdata:margintext]

\startsetups [userdata:margintext]
  \margindata
[inright]
[
 style={\switchtobodyfont[10pt]},
 width=\rightmarginwidth,
 align={flushleft,broad}
]
{\startexemple
 \getinlineuserdata
 \stopexemple}
  \stopsetups

\showframe
\starttext
\startchapter[title={First Chapter},ownnumber=1]
\startdefinition
 \input ward
\stopdefinition
\startuserdata [margintext]
  \input ward
\stopuserdata
\startdefinition
  \input ward
\stopdefinition
\startuserdata [margintext]
  \input knuth
\stopuserdata
\stopchapter
\stoptext


___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Problem with latest version ?

2023-01-06 Thread Fabrice Couvreur via ntg-context
Hi,
>From my side, after the last update, it works.
Thank you Hans.
Fabrice

Le ven. 6 janv. 2023 à 14:17, Gavin via ntg-context  a
écrit :

> Hi Hans,
>
> > On Jan 5, 2023, at 5:49 AM, Hans Hagen via ntg-context <
> ntg-context@ntg.nl> wrote:
> > On 1/5/2023 11:40 AM, Gavin via ntg-context wrote:
> >> ...I can try with the latest LMTX later today. The test file works with
> TeXLive 2022
> >> Gavin
> >> TEST FILE:
> >> \usemodule[tikz]
> >> \usemodule[pgfplots] % PGFPlots module for graphs
> >> \starttext
> >> \starttikzpicture
> >> \draw (0, 0) circle (3cm);
> >> \stoptikzpicture
> >> \starttikzpicture
> >>  \startaxis
> >>\addplot+[domain=0:360]
> >>{sin(x)};
> >>  \stopaxis
> >> \stoptikzpicture
> >> \stoptext
> > fixed in next upload (later today)
>
> I downloaded yesterday's upload. It did not work for me. I did a clean
> instal.
>
> ConTeXt  ver: 2023.01.04 11:35 LMTX  fmt: 2023.1.6  int: english/english
> ...
> tex error on line 14 in file ./TikZTest.tex: Control sequence expected
> instead of undefined
> 
>\startaxis
> 
>  \startaxis
>
>
> -Gavin
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Problem with latest version ?

2023-01-04 Thread Fabrice Couvreur via ntg-context
The problem seems to come from pgfplots ...

Le mer. 4 janv. 2023 à 17:35, Fabrice Couvreur 
a écrit :

>
> Hi,
> I just installed the latest version of LMTX and also updated to texlive
> 2022 and I get this error message which was not the case before.
> Thank you.
> Fabrice
>
>
> Running `lmtX' on `complexes_2' with
> ``/home/fabrice/LMTX/tex/texmf-linux-64/bin/mtxrun --autogenerate --script
> context --autopdf --purgeall complexes_2''
>
> resolvers   | formats | executing runner 'run luametatex format':
> /home/fabrice/LMTX/tex/texmf-linux-64/bin/luametatex
> --jobname="./complexes_2.tex"
> --fmt=/home/fabrice/LMTX/tex/texmf-cache/luametatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e/formats/luametatex/cont-en.fmt
> --lua=/home/fabrice/LMTX/tex/texmf-cache/luametatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e/formats/luametatex/cont-en.lui
>  --c:autopdf --c:currentrun=1 --c:fulljobname="./complexes_2.tex"
> --c:input="./complexes_2.tex" --c:kindofrun=1 --c:maxnofruns=9 --c:purgeall
> --c:texmfbinpath="/home/fabrice/LMTX/tex/texmf-linux-64/bin"
> system  >
> system  > ConTeXt  ver: 2023.01.04 11:35 LMTX  fmt: 2023.1.4  int:
> english/english
> system  >
> system  > 'cont-new.mkxl' loaded
> open source > level 1, order 1, name
> '/home/fabrice/LMTX/tex/texmf-context/tex/context/base/mkxl/cont-new.mkxl'
> system  > beware: some patches loaded from cont-new.mkiv
> close source> level 1, order 1, name
> '/home/fabrice/LMTX/tex/texmf-context/tex/context/base/mkxl/cont-new.mkxl'
> system  > files > jobname './complexes_2', input
> './complexes_2.tex', result './complexes_2'
> fonts   > latin modern fonts are not preloaded
> languages   > language 'en' is active
> open source > level 1, order 2, name './complexes_2.tex'
> open source > level 2, order 3, name 'exercises.mkiv'
> open source > level 3, order 4, name 'terminale-modules.tex'
> open source > level 4, order 5, name
> '/home/fabrice/LMTX/tex/texmf-context/tex/context/base/mkiv/symb-imp-mvs.mkiv'
> close source> level 4, order 5, name
> '/home/fabrice/LMTX/tex/texmf-context/tex/context/base/mkiv/symb-imp-mvs.mkiv'
> fonts   > symbols > library 'mvs' loaded
> open source > level 4, order 6, name
> '/home/fabrice/LMTX/tex/texmf-context/tex/context/base/mkiv/colo-imp-xwi.mkiv'
> close source> level 4, order 6, name
> '/home/fabrice/LMTX/tex/texmf-context/tex/context/base/mkiv/colo-imp-xwi.mkiv'
> colors  > system 'xwi' is loaded
> modules > 'tikz' is loaded
> open source > level 4, order 7, name
> '/home/fabrice/LMTX/tex/texmf-context/tex/context/modules/mkxl/m-tikz.mkxl'
> open source > level 5, order 8, name 'pgfutil-common.tex'
> open source > level 6, order 9, name 'pgfutil-common-lists.tex'
> close source> level 6, order 9, name 'pgfutil-common-lists.tex'
> close source> level 5, order 9, name 'pgfutil-common.tex'
> open source > level 5, order 10, name 'pgfutil-context.def'
> close source> level 5, order 10, name 'pgfutil-context.def'
> open source > level 5, order 11, name 'pgfrcs.code.tex'
> close source> level 5, order 11, name 'pgfrcs.code.tex'
> open source > level 5, order 12, name 'pgfsys.code.tex'
> open source > level 6, order 13, name 'pgfkeys.code.tex'
> open source > level 7, order 14, name 'pgfkeysfiltered.code.tex'
> close source> level 7, order 14, name 'pgfkeysfiltered.code.tex'
> close source> level 6, order 14, name 'pgfkeys.code.tex'
> open source > level 6, order 15, name 'pgf.cfg'
> close source> level 6, order 15, name 'pgf.cfg'
> Driver file for pgf: pgfsys-pdftex.def
>
> open source > level 6, order 16, name 'pgfsys-pdftex.def'
> open source > level 7, order 17, name 'pgfsys-common-pdf.def'
> close source> level 7, order 17, name 'pgfsys-common-pdf.def'
> close source> level 6, order 17, name 'pgfsys-pdftex.def'
> close source> level 5, order 17, name 'pgfsys.code.tex'
> open source > level 5, order 18, name 'pgfkeys.code.tex'
> close source> level 5, order 18, name 'pgfkeys.code.tex'
> open source > level 5, order 19, name 'pgfsyssoftpath.code.tex'
> close source> level 5, order 19, name 'pgfsyssoftpath.code.tex'
> open source > level 5, order 20, name 'pgfsysprotocol.code.tex'
> close source> level 5, order 20, name 'pgfsysprotocol.code.tex'
> open source > level 5, order 21, name 'pgfcore.code.tex'
> open source > level 6, order 22, name 'pgfmath.code.tex'
> open source > level 7, order 23, name 'pgfmathcalc.code.tex'
> open source > level 8, order 24, name 'pgfmathutil.code.tex'
> fonts   > beware: no fonts are loaded yet, using 'lm mono' in box
> close source> level 8, order 24, name 'pgfmathutil.code.tex'
> open source > level 8, order 25, name 'pgfmathparser.code.tex'
> close source> level 8, order 25, name 'pgfmathparser.code.tex'
> open source

[NTG-context] Problem with latest version ?

2023-01-04 Thread Fabrice Couvreur via ntg-context
Hi,
I just installed the latest version of LMTX and also updated to texlive
2022 and I get this error message which was not the case before.
Thank you.
Fabrice


Running `lmtX' on `complexes_2' with
``/home/fabrice/LMTX/tex/texmf-linux-64/bin/mtxrun --autogenerate --script
context --autopdf --purgeall complexes_2''

resolvers   | formats | executing runner 'run luametatex format':
/home/fabrice/LMTX/tex/texmf-linux-64/bin/luametatex
--jobname="./complexes_2.tex"
--fmt=/home/fabrice/LMTX/tex/texmf-cache/luametatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e/formats/luametatex/cont-en.fmt
--lua=/home/fabrice/LMTX/tex/texmf-cache/luametatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e/formats/luametatex/cont-en.lui
 --c:autopdf --c:currentrun=1 --c:fulljobname="./complexes_2.tex"
--c:input="./complexes_2.tex" --c:kindofrun=1 --c:maxnofruns=9 --c:purgeall
--c:texmfbinpath="/home/fabrice/LMTX/tex/texmf-linux-64/bin"
system  >
system  > ConTeXt  ver: 2023.01.04 11:35 LMTX  fmt: 2023.1.4  int:
english/english
system  >
system  > 'cont-new.mkxl' loaded
open source > level 1, order 1, name
'/home/fabrice/LMTX/tex/texmf-context/tex/context/base/mkxl/cont-new.mkxl'
system  > beware: some patches loaded from cont-new.mkiv
close source> level 1, order 1, name
'/home/fabrice/LMTX/tex/texmf-context/tex/context/base/mkxl/cont-new.mkxl'
system  > files > jobname './complexes_2', input
'./complexes_2.tex', result './complexes_2'
fonts   > latin modern fonts are not preloaded
languages   > language 'en' is active
open source > level 1, order 2, name './complexes_2.tex'
open source > level 2, order 3, name 'exercises.mkiv'
open source > level 3, order 4, name 'terminale-modules.tex'
open source > level 4, order 5, name
'/home/fabrice/LMTX/tex/texmf-context/tex/context/base/mkiv/symb-imp-mvs.mkiv'
close source> level 4, order 5, name
'/home/fabrice/LMTX/tex/texmf-context/tex/context/base/mkiv/symb-imp-mvs.mkiv'
fonts   > symbols > library 'mvs' loaded
open source > level 4, order 6, name
'/home/fabrice/LMTX/tex/texmf-context/tex/context/base/mkiv/colo-imp-xwi.mkiv'
close source> level 4, order 6, name
'/home/fabrice/LMTX/tex/texmf-context/tex/context/base/mkiv/colo-imp-xwi.mkiv'
colors  > system 'xwi' is loaded
modules > 'tikz' is loaded
open source > level 4, order 7, name
'/home/fabrice/LMTX/tex/texmf-context/tex/context/modules/mkxl/m-tikz.mkxl'
open source > level 5, order 8, name 'pgfutil-common.tex'
open source > level 6, order 9, name 'pgfutil-common-lists.tex'
close source> level 6, order 9, name 'pgfutil-common-lists.tex'
close source> level 5, order 9, name 'pgfutil-common.tex'
open source > level 5, order 10, name 'pgfutil-context.def'
close source> level 5, order 10, name 'pgfutil-context.def'
open source > level 5, order 11, name 'pgfrcs.code.tex'
close source> level 5, order 11, name 'pgfrcs.code.tex'
open source > level 5, order 12, name 'pgfsys.code.tex'
open source > level 6, order 13, name 'pgfkeys.code.tex'
open source > level 7, order 14, name 'pgfkeysfiltered.code.tex'
close source> level 7, order 14, name 'pgfkeysfiltered.code.tex'
close source> level 6, order 14, name 'pgfkeys.code.tex'
open source > level 6, order 15, name 'pgf.cfg'
close source> level 6, order 15, name 'pgf.cfg'
Driver file for pgf: pgfsys-pdftex.def

open source > level 6, order 16, name 'pgfsys-pdftex.def'
open source > level 7, order 17, name 'pgfsys-common-pdf.def'
close source> level 7, order 17, name 'pgfsys-common-pdf.def'
close source> level 6, order 17, name 'pgfsys-pdftex.def'
close source> level 5, order 17, name 'pgfsys.code.tex'
open source > level 5, order 18, name 'pgfkeys.code.tex'
close source> level 5, order 18, name 'pgfkeys.code.tex'
open source > level 5, order 19, name 'pgfsyssoftpath.code.tex'
close source> level 5, order 19, name 'pgfsyssoftpath.code.tex'
open source > level 5, order 20, name 'pgfsysprotocol.code.tex'
close source> level 5, order 20, name 'pgfsysprotocol.code.tex'
open source > level 5, order 21, name 'pgfcore.code.tex'
open source > level 6, order 22, name 'pgfmath.code.tex'
open source > level 7, order 23, name 'pgfmathcalc.code.tex'
open source > level 8, order 24, name 'pgfmathutil.code.tex'
fonts   > beware: no fonts are loaded yet, using 'lm mono' in box
close source> level 8, order 24, name 'pgfmathutil.code.tex'
open source > level 8, order 25, name 'pgfmathparser.code.tex'
close source> level 8, order 25, name 'pgfmathparser.code.tex'
open source > level 8, order 26, name 'pgfmathfunctions.code.tex'
open source > level 9, order 27, name 'pgfmathfunctions.basic.code.tex'
close source> level 9, order 27, name 'pgfmathfunctions.basic.code.tex'
open source > level 9, order 28, name

Re: [NTG-context] Page break with placement of a figure at the bottom of the page

2022-11-17 Thread Fabrice Couvreur via ntg-context
Hi Bruce and Pablo,
I'm sorry for the late reply but I'm running out of time right now. Thanks
for trying to solve the problem. I think the problem comes from the
pyramid.png file.
Fabrice

Le dim. 13 nov. 2022 à 14:37, Pablo Rodriguez via ntg-context <
ntg-context@ntg.nl> a écrit :

> On 11/13/22 11:32, Fabrice Couvreur via ntg-context wrote:
> > Hi Pablo,
> > Indeed but I posted these two files in a previous post.
>
> Hi Fabrice,
>
> the output from your ie_3.tex is too big for the list, so
> https://pdf.ousia.tk/ie_3.pdf contains it.
>
> I see no problem there, but I think that the output from
> https://mailman.ntg.nl/pipermail/ntg-context/2022/107191.html may come
> from a different source.
>
> BTW, I couldn’t find "ie_3.tex" in
> https://mailman.ntg.nl/pipermail/ntg-context/2022.txt.gz (which seems to
> be generated with messages previous to current date).
>
> If you sent the files before, it is fine to include a link to the
> relevant message in the list (such as the first link included in this
> message).
>
> BTW, it might be worth considering a GitHub or GitLab repository for not
> minimal samples. There files may be stored (and the whole repository
> might be deleted when not needed).
>
> I hope it helps,
>
> Pablo
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Page break with placement of a figure at the bottom of the page

2022-11-16 Thread Fabrice Couvreur via ntg-context
Hi Bruce and Pablo,
I'm sorry for the late reply but I'm running out of time right now. Thanks
for trying to solve the problem. I think the problem comes from the
pyramid.png file.
Fabrice

Le mer. 16 nov. 2022 à 14:55, Fabrice Couvreur 
a écrit :

> Hi Bruce and Pablo,
> I'm sorry for the late reply but I'm running out of time right now. Thanks
> for trying to solve the problem. I think the problem comes from the
> pyramid.png file.
> Fabrice
>
> Le dim. 13 nov. 2022 à 14:37, Pablo Rodriguez via ntg-context <
> ntg-context@ntg.nl> a écrit :
>
>> On 11/13/22 11:32, Fabrice Couvreur via ntg-context wrote:
>> > Hi Pablo,
>> > Indeed but I posted these two files in a previous post.
>>
>> Hi Fabrice,
>>
>> the output from your ie_3.tex is too big for the list, so
>> https://pdf.ousia.tk/ie_3.pdf contains it.
>>
>> I see no problem there, but I think that the output from
>> https://mailman.ntg.nl/pipermail/ntg-context/2022/107191.html may come
>> from a different source.
>>
>> BTW, I couldn’t find "ie_3.tex" in
>> https://mailman.ntg.nl/pipermail/ntg-context/2022.txt.gz (which seems to
>> be generated with messages previous to current date).
>>
>> If you sent the files before, it is fine to include a link to the
>> relevant message in the list (such as the first link included in this
>> message).
>>
>> BTW, it might be worth considering a GitHub or GitLab repository for not
>> minimal samples. There files may be stored (and the whole repository
>> might be deleted when not needed).
>>
>> I hope it helps,
>>
>> Pablo
>>
>> ___
>> If your question is of interest to others as well, please add an entry to
>> the Wiki!
>>
>> maillist : ntg-context@ntg.nl /
>> https://www.ntg.nl/mailman/listinfo/ntg-context
>> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
>> archive  : https://bitbucket.org/phg/context-mirror/commits/
>> wiki : https://contextgarden.net
>>
>> ___
>>
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Page break with placement of a figure at the bottom of the page

2022-11-13 Thread Fabrice Couvreur via ntg-context
Hi Pablo,
Indeed but I posted these two files in a previous post.
Fabrice

Le dim. 13 nov. 2022 à 09:24, Pablo Rodriguez via ntg-context <
ntg-context@ntg.nl> a écrit :

> On 11/12/22 15:09, Fabrice Couvreur via ntg-context wrote:
> > Hi Pablo and Bruce,
> > Please try to figure out what is not working.
> > I'm sorry but I forgot in my previous post files.
>
> Hi Fabrice,
>
> I get empty files when compiling premiere-modules.tex and
> premiere-macros.tex and error message with tikz-style.tex.
>
> I guess a fourth file invoking the other three files may be missing here.
>
> Pablo
>
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
\environment[template.mkiv]

\definemargindata[marginfigure][inright]

\useMPlibrary[dum]

\setupmargindata [marginfigure][command=\vbox,align=middle,stack=yes]

\setvariables
[headertext]
[title={Interrogation écrite},
 number={3},
 day={8},
 month={11},
 year={2022},
 location={Premières},
 time={55 minutes}]

\showgrid
\startcomponent[ie_3]
  \startex
Nous considérons la suite \u définie sur \N par son premier terme \m{u_0=-2} et la relation de récurrence
\startformula
  \text{pour tout} \; n \in \N, \; u_{n+1}=\sqrt{3+u_n}.
\stopformula
Les termes de cette suite sont itérés par la fonction \m{f\,\colon x \longmapsto \sqrt{x+3}} qui est définie sur \intervalfo{-3}{+\infty}, et dont la représentation graphique \m{C_f} est donnée ci-après.
\startlinecorrection[blank]
  \startmidaligned
\externalfigure[spirale.pdf]
  \stopmidaligned
\stoplinecorrection
Représenter graphiquement les cinq premiers termes de cette suite.
  \stopex
  \startex
La suite \u est arithmétique de raison \m{r=-7} et de premier terme \m{u_0=5}.
\startitemize[n]
  \startitem
Calculer \m{u_{16}}.
  \stopitem
  \startitem
Calculer la somme
\startformula
  \sum_{k=0}^{k=16}u_k=u_0+u_1+u_2+\cdots + u_{15}+u_{16}.
\stopformula
  \stopitem
\stopitemize
  \stopex
  \startex
  On considère la suite arithmétique \u, définie sur \N, telle que \m{u_{12}=52} et \m{u_{23}=107}.
  \startitemize[n]
\startitem
  Calculer la raison \m{r} de la suite.
\stopitem
\startitem
  Déterminer le terme initial \m{u_0}.
\stopitem
\startitem
  Déterminer \m{u_n} en fonction de \m{n}, puis calculer \m{u_{55}}.
\stopitem
\startitem
  Donner le sens de variation de \u.
\stopitem
\startitem
  Conjecturer la limite éventuelle de la suite \u.
\stopitem
  \stopitemize
  \stopex
  \startex
   On s'intéresse à des pyramides construites avec des allumettes comme ci-après .

  En poursuivant ainsi, on obtient des pyramides à autant d'étages que l'on souhaite à condition, bien sûr, d'avoir assez d'allumettes.
\startlinecorrection[blank]
  \startmidaligned
\startcombination[3*1]
  {\externalfigure[pyramide_1.pdf]}{\tfx 1 étage}
  {\externalfigure[pyramide_2.pdf]}{\tfx 2 étages}
  {\externalfigure[pyramide_3.pdf]}{\tfx 3 étages}
\stopcombination
  \stopmidaligned
\stoplinecorrection
Le 1\high{\tfxx er} étage est formé de 3 allumettes, le 2\high{\tfxx e} de 7 allumettes, et le 3\high{\tfxx e} de 11 allumettes.
\startitemize[n]
  \startitem
   De combien d'allumettes est formé le 4\high{\tfxx e} étage ? Le 5\high{\tfxx e} ?
  \stopitem
  \startitem
Pour tout entier naturel \m{n\geqslant 1}, on note \m{u_n} le nombre d'allumettes du \m{n-\text{ième}} étage. Ainsi, nous avons \m{u_1=3}.

Justifier que la suite \u est arithmétique en précisant sa raison.
  \stopitem
  \startitem
Déterminer le calcul explicite de \m{u_n} en fonction de \m{n}, \m{u_1} et \m{r}.
  \stopitem
  \placerecipe{}{ \externalfigure[pyramide.png][scale=850]}
  \startitem
Déterminer le nombre d'allumettes du 10\high{\tfxx e} étage.
  \stopitem
  \startitem
Combien d'allumettes au total ont été nécessaires pour réaliser la construction jusqu'au 10\high{\tfxx e} étage ?
  \stopitem
   
  \startitem
On considère la fonction {\tt \darkred pyramide()} ci-contre programmée en langage Python.

À quoi correspond le nombre renvoyé par {\tt \darkred pyramide(3)} ?
  \stopitem
\stopi

Re: [NTG-context] Page break with placement of a figure at the bottom of the page

2022-11-12 Thread Fabrice Couvreur via ntg-context
Hi Pablo and Bruce,
Please try to figure out what is not working.
I'm sorry but I forgot in my previous post files.
Fabrice

Le sam. 12 nov. 2022 à 12:28, Pablo Rodriguez via ntg-context <
ntg-context@ntg.nl> a écrit :

> On 11/11/22 21:58, Bruce Horrocks via ntg-context wrote:
> >> On 10 Nov 2022, at 17:06, Fabrice Couvreur via ntg-context wrote:
> >>
> >> Hi,
> >> Sorry to come back to you, but it seems to me that there is enough
> space here.
> >> Fabrice
> >
> > For some reason your PNG images came through in extremely low
> > resolution. Without having the ConTeXt source it's hard to say for sure
> > what's happening - for example, I would have expected the text on the
> > second page to be at the bottom of the first even if there wasn't room
> > for the image - because that was what was happening in your first
> example.
>
> Hi Fabrice and Bruce,
>
> I agree that the source would be helpful to say what may be hard for
> ConTeXt.
>
> In any case, ConTeXt has a hard time with pagebreaks when you combine
> elements that need both horizontal and vertical calculation, such as in:
>
>   \starttext
>   \dorecurse{64}
>   {\input knuth\footnote{\input zapf}
>
>   \startitemize[a, columns, eight, packed]
>   \dorecurse{64}{\item\currentitemnumber}
>   \stopitemize}
>   \stoptext
>
> There is a similar issue with paragraph notes.
>
> Pablo
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>

\startenvironment[premiere-modules]

  \usesymbols[mvs] 
  \usecolors[xwi]
  \usemodule[tikz]
  \usemodule[pgfplots]
  \usepgfplotslibrary[fillbetween]
  \pgfplotsset{compat=newest}
  \usetikzlibrary[arrows]
  \usetikzlibrary[automata]
  \usetikzlibrary[calc]
  \usetikzlibrary[backgrounds]
  \usetikzlibrary[intersections]
  \usetikzlibrary[patterns]
  \usetikzlibrary[bending]
  \usetikzlibrary[arrows.meta]
  \usetikzlibrary[shapes.geometric]
  \usetikzlibrary[plotmarks]
  \usetikzlibrary[shapes]
  \usetikzlibrary[trees]
  \usetikzlibrary[animations]
  \usetikzlibrary[quotes]
  \usetikzlibrary[mindmap]
  \usetikzlibrary[matrix,decorations.pathreplacing,fit,positioning]

\stopenvironment\startenvironment[premiere-macros]

  \unexpanded\def\R{\math{\mathbb{R}}\autoinsertnextspace}

  \protected\def\N{\doifnextcharelse{*}\MyNstarred\MyNnormal}

  \def\MyNstarred*{\m{\mathbb{N}^*}\autoinsertnextspace}
  \def\MyNnormal  {\m{\mathbb{N}  }\autoinsertnextspace}

  \define[1]\cscript
 {\start\switchtobodyfont[stixtwo]\m{{\mathscript{#1}}}\stop} 


  %\protected\def\card#1{\m{\mfunction{Card}\thinspace(#1)}}

  \define[1]\card
 {\m{\mathtexttf{Card}\thinspace(#1)}\autoinsertnextspace}

  \define[1]\norm
{\math{\left\Vert#1\right\Vert}}

  \define\esp{\math{\mathcal{E}}\autoinsertnextspace}

  \define\espv{\math{\vec{\mathcal{E}}}\autoinsertnextspace}

  \define\repere
 {\m{\left(O\,;\vec{i}, \vec{j}\right)}\autoinsertnextspace}

  \define\base
 {\m{\left(\vec{i}, \vec{j}, \vec{k}\right)}\autoinsertnextspace}

 \protected\def\vector#1{%
   \starttikzpicture[baseline=(arg.base),>=stealth,thick]
   \node[inner xsep=0pt] (arg) {\m{#1}};
   \draw[->,shorten >=-2pt] (arg.north west) -- (arg.north east);
   \stoptikzpicture%
  }

  
  \definemathmatrix [pmatrix][matrix:parentheses][simplecommand=MATRIX]

  \unexpanded\def\intervalff#1#2{\math{\left[#1\nonscript\,;#2\right]}}
  
  \unexpanded\def\intervaloo#1#2{\math{\left]#1\nonscript\,;#2\right[}}
  
  \unexpanded\def\intervalfo#1#2{\math{\left[#1\nonscript\,;#2\right[}}
  
  \unexpanded\def\intervalof#1#2{\math{\left]#1\nonscript\,;#2\right]}}

  \define[1]\vabs{\math{\left\vert#1\right\vert}}

  \define\u{\math{\left(u_n\right)}\autoinsertnextspace}

  \define\v{\math{\left(v_n\right)}\autoinsertnextspace}

  \define\w{\math{\left(w_n\right)}\autoinsertnextspace}

  \unexpanded\def\euros#1{#1\,\symbol[europe][EUR]}

  \protected\def\point#1#2#3{\math{#1\left(#2\,;#3\right)}}

  \protected\def\coord#1#2{\math{\left(#1\,;#2\right)}}

  \define[2]\prod{\m{\vector{#1}\cdot\vector{#2}}}

   \protected\def\e#1{\math{{\rm e}^{#1}}\autoinsertnextspace}
  
\stopenvironment\startenvironment[tikz-style]

  \pgfplotsset{
/pgfplots/layers/Bowpark/.define layer set={
axis background,axis grid,main,axis ticks,axis lines,axis tick labels,
axis descriptions,axis fore

Re: [NTG-context] Page break with placement of a figure at the bottom of the page

2022-11-10 Thread Fabrice Couvreur via ntg-context
Hi,
Sorry to come back to you, but it seems to me that there is enough space
here.
Fabrice

Le jeu. 10 nov. 2022 à 18:04, Fabrice Couvreur 
a écrit :

> Hi,
> Sorry to come back to you, but it seems to me that there is enough space
> here.
> Fabrice
>
> Le jeu. 10 nov. 2022 à 17:45, Fabrice Couvreur <
> fabrice1.couvr...@gmail.com> a écrit :
>
>> Hi,
>> Sorry to come back to you, but it seems to me that there is enough space
>> here.
>> Fabrice
>>
>> Le jeu. 10 nov. 2022 à 11:59, Fabrice Couvreur <
>> fabrice1.couvr...@gmail.com> a écrit :
>>
>>> Sorry to come back to you, but it seems to me that there is enough space
>>> here.
>>>
>>> Le jeu. 10 nov. 2022 à 11:36, Fabrice Couvreur <
>>> fabrice1.couvr...@gmail.com> a écrit :
>>>
>>>> Hi Bruce and Pablo,
>>>> Thank you very much, your explanations are very clear.
>>>> Cordially
>>>> Fabrice
>>>>
>>>> Le mer. 9 nov. 2022 à 19:39, Bruce Horrocks via ntg-context <
>>>> ntg-context@ntg.nl> a écrit :
>>>>
>>>>> On 9 Nov 2022, at 18:22, Pablo Rodriguez via ntg-context <
>>>>> ntg-context@ntg.nl> wrote:
>>>>> >
>>>>> > On 11/9/22 17:51, Fabrice Couvreur via ntg-context wrote:
>>>>> >> Hi,
>>>>> >> I find that for some time (but maybe the problem comes from me !),
>>>>> the
>>>>> >> placement of a figure at the bottom of the page causes a page break
>>>>> when
>>>>> >> it seems to me that there is enough space, which poses some
>>>>> problems in
>>>>> >> the pagination of my documents.
>>>>> >
>>>>> > Hi Fabrice,
>>>>> >
>>>>> > your figure requires about 7¼ lines (one line before, six for the
>>>>> image
>>>>> > itself, and some extra space after it).
>>>>> >
>>>>> > Your layout for the first page only allows 43 lines and sample text
>>>>> ends
>>>>> > on line 37.
>>>>> >
>>>>> > Replace \showframe with \showgrid and you will see that there might
>>>>> be
>>>>> > not enough space to fit the image in the first page.
>>>>> >
>>>>> > Add "bottomspace=7.25mm" to the layout for the first page and the
>>>>> image
>>>>> > will fit in the first page.
>>>>> >
>>>>> > Just in case it might help,
>>>>>
>>>>> Or Pablo's answer shown another way... change the end of the example
>>>>> to:
>>>>>
>>>>> \starttext
>>>>> \dorecurse{11}{\input ward}
>>>>> \placerecipe{}{\externalfigure[dum]}
>>>>> \dorecurse{5}{\input ward} %% extra
>>>>> \stoptext
>>>>>
>>>>> and the extra text shows how much space the image requires. Holding a
>>>>> ruler up to the screen you can see that it won't fit.
>>>>>
>>>>> The problem seems to be that the image is reserving space for a
>>>>> caption even though there isn't a caption. A work-around is to change
>>>>> \setupfloat to the following:
>>>>>
>>>>>  \setupfloat
>>>>>  [recipe]
>>>>>  [default={right,none,high}]
>>>>>
>>>>> and then the image fits as you want it to.
>>>>> —
>>>>> Bruce Horrocks
>>>>> Hampshire, UK
>>>>>
>>>>>
>>>>> ___
>>>>> If your question is of interest to others as well, please add an entry
>>>>> to the Wiki!
>>>>>
>>>>> maillist : ntg-context@ntg.nl /
>>>>> https://www.ntg.nl/mailman/listinfo/ntg-context
>>>>> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
>>>>> archive  : https://bitbucket.org/phg/context-mirror/commits/
>>>>> wiki : https://contextgarden.net
>>>>>
>>>>> ___
>>>>>
>>>>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Page break with placement of a figure at the bottom of the page

2022-11-10 Thread Fabrice Couvreur via ntg-context
Hi Bruce and Pablo,
Thank you very much, your explanations are very clear.
Cordially
Fabrice

Le mer. 9 nov. 2022 à 19:39, Bruce Horrocks via ntg-context <
ntg-context@ntg.nl> a écrit :

> On 9 Nov 2022, at 18:22, Pablo Rodriguez via ntg-context <
> ntg-context@ntg.nl> wrote:
> >
> > On 11/9/22 17:51, Fabrice Couvreur via ntg-context wrote:
> >> Hi,
> >> I find that for some time (but maybe the problem comes from me !), the
> >> placement of a figure at the bottom of the page causes a page break when
> >> it seems to me that there is enough space, which poses some problems in
> >> the pagination of my documents.
> >
> > Hi Fabrice,
> >
> > your figure requires about 7¼ lines (one line before, six for the image
> > itself, and some extra space after it).
> >
> > Your layout for the first page only allows 43 lines and sample text ends
> > on line 37.
> >
> > Replace \showframe with \showgrid and you will see that there might be
> > not enough space to fit the image in the first page.
> >
> > Add "bottomspace=7.25mm" to the layout for the first page and the image
> > will fit in the first page.
> >
> > Just in case it might help,
>
> Or Pablo's answer shown another way... change the end of the example to:
>
> \starttext
> \dorecurse{11}{\input ward}
> \placerecipe{}{\externalfigure[dum]}
> \dorecurse{5}{\input ward} %% extra
> \stoptext
>
> and the extra text shows how much space the image requires. Holding a
> ruler up to the screen you can see that it won't fit.
>
> The problem seems to be that the image is reserving space for a caption
> even though there isn't a caption. A work-around is to change \setupfloat
> to the following:
>
>  \setupfloat
>  [recipe]
>  [default={right,none,high}]
>
> and then the image fits as you want it to.
> —
> Bruce Horrocks
> Hampshire, UK
>
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Page break with placement of a figure at the bottom of the page

2022-11-09 Thread Fabrice Couvreur via ntg-context
Hi,
I find that for some time (but maybe the problem comes from me !), the
placement of a figure at the bottom of the page causes a page break when it
seems to me that there is enough space, which poses some problems in the
pagination of my documents.
Thanks.
Fabrice

\useMPlibrary[dum]
\definelayout
   [1]
   [topspace=10mm,
header=15mm,
headerdistance=10mm,
height=middle,
width=middle,
location=middle]

\setuplayout
  [topspace=10mm,
header=0pt,
headerdistance=0pt,
height=middle,
width=middle,
location=middle]

\definefloat
[recipe]
[figure]

 \setupfloat
 [recipe]
 [default={right,none}]

 \showframe
\starttext
\dorecurse{11}{\input ward}
\placerecipe{}{\externalfigure[dum]}
\stoptext
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Create the values of a sequence with Lua

2022-10-31 Thread Fabrice Couvreur via ntg-context
Hi,
The idea is to fill the array with the sequence defined by
p(0) = 0.3 and p(n + 1) = 0.3 + 0.7*p(n)
The problem is that I don't really master Lua but I will learn when I have
some time!
Thanks for your help.
Fabrice

\starttext
\startluacode
context.startxtable({"align={middle,lohi},width=2cm,bodyfont=9pt"})
p = {}
p[0] = 0.3
for i=0,19 do
p[i+1] = 0.3+0.7*p[i]^2 end
context.startxrow()
for i=0,19 do
context.startxcell() context(i) context.stopxcell()
context.startxcell() context(i+1) context.stopxcell()
context.startxcell() context("%0.8f",p[i] ) context.stopxcell()
context.stopxrow()
end
context.stopxtable()
\stopluacode
\stoptext
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] About macro numberstriped ()

2022-10-02 Thread Fabrice Couvreur via ntg-context
Hi Mikael,
Great job !
Thanks
Fabrice

Le dim. 2 oct. 2022 à 15:37, Mikael Sundqvist via ntg-context <
ntg-context@ntg.nl> a écrit :

> Hi,
>
> On Sun, Oct 2, 2022 at 3:26 PM Hans Hagen via ntg-context
>  wrote:
> >
> > On 10/2/2022 3:13 PM, Fabrice Couvreur via ntg-context wrote:
> > > Ok, it works very well. Without wanting to insist, how to have the same
> > > hatching with two different figures ?
> > see upcoming mail from Mikael
>
> Oh, OK, here it goes. Hans will probably rename things if he adds this.
>
> \startMPpage[offset=1dk]
>
> vardef Stripe(expr p, a, d) =
> save thestripe ; picture thestripe ; thestripe := nullpicture ;
> save diag ; numeric diag ; diag := 0.55*( abs((urcorner boundingbox p)
> - (llcorner boundingbox p)) ) ;
> thestripe := image (
> draw (-diag,0) -- (diag, 0) &&
> for i = d step d until diag:
> (-diag, i) -- (diag, i) &&
> (-diag,-i) -- (diag,-i) &&
> endfor nocycle
> withpen currentpen ;
> ) ;
> thestripe := thestripe shifted center boundingbox p ;
> thestripe := thestripe rotatedaround(center boundingbox p, a) ;
> clip thestripe to p ;
> thestripe
> enddef ;
>
>
> path p ; p := fullcircle scaled 3cm && (unitsquare scaled 2cm shifted
> (4cm,4cm)) && cycle ;
> fill p withcolor darkred ;
> draw Stripe(p,30,.2cm) withcolor darkgreen ;
>
> path q ; q := fullsquare randomized 0.3 scaled 3cm yshifted 5cm ;
> fill q withcolor yellow ;
> draw Stripe(q,70,.3cm) withcolor red ;
>
> draw Stripe(p && q && cycle, -20, .5cm) withcolor "orange" ;
>
> draw p ;
> draw q ;
>
> \stopMPpage
>
> /Mikael
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] About macro numberstriped ()

2022-10-02 Thread Fabrice Couvreur via ntg-context
Ok, it works very well. Without wanting to insist, how to have the same
hatching with two different figures ?
Thanks.
Fabrice

Le dim. 2 oct. 2022 à 13:38, Hans Hagen via ntg-context 
a écrit :

> On 10/2/2022 1:02 PM, Fabrice Couvreur via ntg-context wrote:
> > I just tried but I got an empty file...
> > Do we agree that I have to replace the two lines with the other two ?
> > Regarding what you proposed, how to get the same type of hatching in
> > both figures ?
> no, we disagree here; add them after the min/max lines
>
> Hans
>
> -
>Hans Hagen | PRAGMA ADE
>Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
> -
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] About macro numberstriped ()

2022-10-02 Thread Fabrice Couvreur via ntg-context
I just tried but I got an empty file...
Do we agree that I have to replace the two lines with the other two ?
Regarding what you proposed, how to get the same type of hatching in both
figures ?

 \startMPcode
path p, q, r, b ;
p  := unitsquare xyscaled (4cm,4cm) ;
z[0] = (2cm,0cm) ;
z[1] = (2cm,4cm) ;
z[2] = (0cm,2cm) ;
q := llcorner p--z[0]--z[1]--z[2]--cycle ;
r := unitsquare xyscaled (1cm,1cm) shifted(0,3cm) ;
b := (0cm,0cm) -- lrcorner r -- lrcorner p -- cycle;

 draw r
 withpattern image (
 draw (llcorner unitsquare -- urcorner unitsquare) scaled 5mm ;
 % how to get the corner dots
 )
 withpatternscale 1/4
 withpen pencircle scaled 1bp
 withcolor green
 ;
draw b
 withpattern image (
 draw (llcorner unitsquare -- urcorner unitsquare) scaled 5mm ;
 % how to get the corner dots
 )
 withpatternscale 1/16
 withpen pencircle scaled 1bp
 withcolor green
 ;


draw b  withpen pencircle scaled 1bp  withcolor darkgreen;
draw r  withpen pencircle scaled 1bp  withcolor darkgreen;
draw p;

label.llft("B", p) ;
label.lrt("C", p) ;
label.ulft("A", p) ;
label.urt("D", p) ;
label.urt("F", lrcorner r) ;
label.lft("E", llcorner r) ;
label.top("G", urcorner r) ;

  \stopMPcode

Le dim. 2 oct. 2022 à 11:52, Hans Hagen via ntg-context 
a écrit :

> On 10/2/2022 11:20 AM, Floris van Manen via ntg-context wrote:
> >
> >
> > On 02/10/2022 10:55, Fabrice Couvreur via ntg-context wrote:
> >> Initially, there was a bug with maro numberstriped() and Hans
> >> suggested another sensible approach to me, but you don't get the same
> >> shape of the hatches depending on the dimensions of the squares.
> >
> > some unexpected side effect show up when the unitsquare is xyscaled to a
> > rectangle like (2.5cm,1cm)
> > it seems related to the angle chosen
> >
> > e.g.
> >
> >
> >
> > \startMPcode
> >
> > path p, q, r, b ;
> > p  := unitsquare xyscaled (4cm,4cm) ;
> > q := unitsquare xyscaled (1cm,1cm) shifted(0,3cm) ;
> > r := unitsquare xyscaled (2.5cm,1cm) shifted(1cm,3cm) ;
> > b := unitsquare xyscaled (3cm,3cm) shifted(1cm,0) ;
> >
> > draw r anglestriped (1,35,2) withcolor red;
> > draw q anglestriped (1,35,2) withcolor green;
> > draw b anglestriped (1,35,2) withcolor cyan;
> > draw p;
> > draw q;
> > draw b;
> > draw r;
> >
> > label.llft("D", p) ;
> > label.lrt("C", p) ;
> > label.ulft("A", p) ;
> > label.urt("B", p) ;
> > label.urt("P", lrcorner r) ;
> > label.lft("Q", llcorner r) ;
> > label.top("M", urcorner r) ;
> >
> > \stopMPcode
>
> for that you can patch mp-tool.mpxl (l 676):
>
>  maximum := max (xpart llcorner mask, xpart urcorner mask, ypart
> llcorner mask, ypart urcorner mask) ;
>  minimum := min (xpart llcorner mask, xpart urcorner mask, ypart
> llcorner mask, ypart urcorner mask) ;
>  % a hack:
> maximum := maximum + max(xpart urcorner shape, ypart urcorner shape);
> minimum := minimum - max(xpart urcorner shape, ypart urcorner shape);
>
> a bit overkill but it seems to work
>
> Hans
>
> -
>Hans Hagen | PRAGMA ADE
>Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
> -
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] About macro numberstriped ()

2022-10-02 Thread Fabrice Couvreur via ntg-context
Not only, it is also true with the code below :

\startMPcode
path p, q, r, b ;
p  := unitsquare xyscaled (4cm,4cm) ;
z[0] = (2cm,0cm) ;
z[1] = (2cm,4cm) ;
z[2] = (0cm,2cm) ;
q := llcorner p--z[0]--z[1]--z[2]--cycle ;
r := unitsquare xyscaled (1cm,1cm) shifted(0,3cm) ;
b := (0cm,0cm) -- lrcorner r -- lrcorner p -- cycle;

draw r anglestriped (1,45,2) withcolor green;
draw b anglestriped (1,45,2) withcolor green;

draw b withcolor darkgreen;
draw r withcolor darkgreen;
draw p;

label.llft("B", p) ;
label.lrt("C", p) ;
label.ulft("A", p) ;
label.urt("D", p) ;
label.urt("F", lrcorner r) ;
label.lft("E", llcorner r) ;
label.top("G", urcorner r) ;

  \stopMPcode

Le dim. 2 oct. 2022 à 11:21, Floris van Manen via ntg-context <
ntg-context@ntg.nl> a écrit :

>
>
> On 02/10/2022 10:55, Fabrice Couvreur via ntg-context wrote:
> > Initially, there was a bug with maro numberstriped() and Hans suggested
> > another sensible approach to me, but you don't get the same shape of the
> > hatches depending on the dimensions of the squares.
>
> some unexpected side effect show up when the unitsquare is xyscaled to a
> rectangle like (2.5cm,1cm)
> it seems related to the angle chosen
>
> e.g.
>
>
>
> \startMPcode
>
> path p, q, r, b ;
> p  := unitsquare xyscaled (4cm,4cm) ;
> q := unitsquare xyscaled (1cm,1cm) shifted(0,3cm) ;
> r := unitsquare xyscaled (2.5cm,1cm) shifted(1cm,3cm) ;
> b := unitsquare xyscaled (3cm,3cm) shifted(1cm,0) ;
>
> draw r anglestriped (1,35,2) withcolor red;
> draw q anglestriped (1,35,2) withcolor green;
> draw b anglestriped (1,35,2) withcolor cyan;
> draw p;
> draw q;
> draw b;
> draw r;
>
> label.llft("D", p) ;
> label.lrt("C", p) ;
> label.ulft("A", p) ;
> label.urt("B", p) ;
> label.urt("P", lrcorner r) ;
> label.lft("Q", llcorner r) ;
> label.top("M", urcorner r) ;
>
> \stopMPcode
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] About macro numberstriped ()

2022-10-02 Thread Fabrice Couvreur via ntg-context
Hi,
Initially, there was a bug with maro numberstriped() and Hans suggested
another sensible approach to me, but you don't get the same shape of the
hatches depending on the dimensions of the squares.
Your solution works perfectly but I'm trying to understand the action of
the parameters:
the first ?
the second represents the angle in degrees that the segments make
the third represents the gap between two segments
Thanks
Fabrice

Le sam. 1 oct. 2022 à 21:46, Mikael Sundqvist via ntg-context <
ntg-context@ntg.nl> a écrit :

> Hi,
>
> Is this what you are looking for?
>
> On Sat, Oct 1, 2022 at 7:43 PM Fabrice Couvreur via ntg-context
>  wrote:
> >
> > Hi Hans,
> > When the rectangles are not identical, how to have the same type of
> hatching in both ?
> > Thanks.
> > Fabrice
> >
> >
> > \starttext
> >  \startlinecorrection[blank]
> >   \startmidaligned
> > \switchtobodyfont[9pt]
> > \startMPcode
> >   path p, q, r, b ;
> >   p  := unitsquare xyscaled (4cm,4cm) ;
> >   z[0] = (2cm,0cm) ;
> >   z[1] = (2cm,4cm) ;
> >   z[2] = (0cm,2cm) ;
> >   q := llcorner p--z[0]--z[1]--z[2]--cycle ;
> >   r := unitsquare xyscaled (1cm,1cm) shifted(0,3cm) ;
> >   b := unitsquare xyscaled (3cm,3cm) shifted(1cm,0) ;
> >
>
> draw r anglestriped (1,45,2) withcolor cyan;
> draw b anglestriped (1,45,2) withcolor cyan;
>
> >
> >draw p;
> >draw b;
> >draw r;
> >
> >  label.llft("D", p) ;
> >  label.lrt("C", p) ;
> >  label.ulft("A", p) ;
> >  label.urt("B", p) ;
> >  label.urt("P", lrcorner r) ;
> >  label.lft("Q", llcorner r) ;
> > label.top("M", urcorner r) ;
> >
> >   \stopMPcode
> >   \stopmidaligned
> > \stoplinecorrection
> > \stoptext
> >
> >
>
> /Mikael
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] About macro numberstriped ()

2022-10-01 Thread Fabrice Couvreur via ntg-context
Hi Hans,
When the rectangles are not identical, how to have the same type of
hatching in both ?
Thanks.
Fabrice


\starttext
 \startlinecorrection[blank]
  \startmidaligned
\switchtobodyfont[9pt]
\startMPcode
  path p, q, r, b ;
  p  := unitsquare xyscaled (4cm,4cm) ;
  z[0] = (2cm,0cm) ;
  z[1] = (2cm,4cm) ;
  z[2] = (0cm,2cm) ;
  q := llcorner p--z[0]--z[1]--z[2]--cycle ;
  r := unitsquare xyscaled (1cm,1cm) shifted(0,3cm) ;
  b := unitsquare xyscaled (3cm,3cm) shifted(1cm,0) ;

  draw r
 withpattern image (
 draw (llcorner unitsquare -- urcorner unitsquare) scaled 5mm ;
 % how to get the corner dots
   )
   withpatternscale 1/8
   withpen pencircle scaled 1pt
   withcolor cyan;
   ;
 draw b
   withpattern image (
 draw (llcorner unitsquare -- urcorner unitsquare) scaled 5mm ;
 % how to get the corner dots
   )
   withpatternscale 1/16
   withpen pencircle scaled 1pt
   withcolor cyan;
   ;

   draw p;
   draw b;
   draw r;

 label.llft("D", p) ;
 label.lrt("C", p) ;
 label.ulft("A", p) ;
 label.urt("B", p) ;
 label.urt("P", lrcorner r) ;
 label.lft("Q", llcorner r) ;
label.top("M", urcorner r) ;

  \stopMPcode
  \stopmidaligned
\stoplinecorrection
\stoptext



Le mer. 28 sept. 2022 à 21:05, Henning Hraban Ramm via ntg-context <
ntg-context@ntg.nl> a écrit :

> Am 28.09.22 um 15:29 schrieb Hans Hagen via ntg-context:
> > On 9/28/2022 3:11 PM, Fabrice Couvreur via ntg-context wrote:
> >> PS : What is the exact meaning of the word "blobs" because my English
> >> is average ?
> > in order to get 'lines' you need to fill the two opposing corners with
> > "blobs of ink"
>
> Otherwise, a BLOB is a “binary large object”, e.g. if you save image
> data to a database.
>
> Hraban
>
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] About macro numberstriped ()

2022-09-28 Thread Fabrice Couvreur via ntg-context
Hi Hans,
Thank you for this solution which is an approach that I did not know.
Fabrice

PS : What is the exact meaning of the word "blobs" because my English is
average ?

Le mar. 27 sept. 2022 à 22:04, Hans Hagen via ntg-context <
ntg-context@ntg.nl> a écrit :

> On 9/27/2022 7:49 PM, Fabrice Couvreur via ntg-context wrote:
> > Hello,
> > I notice a strange behavior of the macro numberstriped ( ).
> > Thanks.
> > Fabrice
> >
> > \starttext
> >   \switchtobodyfont[9pt]
> >   \startMPcode
> >
> >path p, q, r, b ;
> >p  := unitsquare xyscaled (4cm,4cm) ;
> >z[0] = (2cm,0cm) ;
> >z[1] = (2cm,4cm) ;
> >z[2] = (0cm,2cm) ;
> >q := llcorner p--z[0]--z[1]--z[2]--cycle ;
> >r := unitsquare xyscaled (1cm,1cm) shifted(0,3cm) ;
> >b := unitsquare xyscaled (3cm,3cm) shifted(1cm,0) ;
> >draw p ;
> >draw r withcolor red;
> >draw r numberstriped (.25,20,5) withcolor magenta ;
> >draw b numberstriped (.25,20,5) withcolor magenta ;
> >label.llft("D", p) ;
> >label.lrt("C", p) ;
> >label.ulft("A", p) ;
> >label.urt("B", p) ;
> >label.urt("P", lrcorner r) ;
> >label.lft("Q", llcorner r) ;
> >label.top("M", urcorner r) ;
> >
> >\stopMPcode
> > \stoptext
> you need to find a volunteer to make the pattern have the two corner  blobs
>
> \starttext
>
> \startMPcode
>  path p, q, r, b ;
>  path p ; p  := unitsquare xyscaled (4cm,4cm) ;
>  draw p ;
>  draw p
>  withpattern image (
>  draw (llcorner unitsquare -- urcorner unitsquare) scaled 5mm ;
>  % how to get the corner dots
>  )
>  withpatternscale 1/16
>  withpen pencircle scaled 1mm
>  ;
> \stopMPcode
>
> \stoptext
>
>
> -
>Hans Hagen | PRAGMA ADE
>Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
> -
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] About macro numberstriped ()

2022-09-27 Thread Fabrice Couvreur via ntg-context
Hello,
I notice a strange behavior of the macro numberstriped ( ).
Thanks.
Fabrice

\starttext
 \switchtobodyfont[9pt]
 \startMPcode

  path p, q, r, b ;
  p  := unitsquare xyscaled (4cm,4cm) ;
  z[0] = (2cm,0cm) ;
  z[1] = (2cm,4cm) ;
  z[2] = (0cm,2cm) ;
  q := llcorner p--z[0]--z[1]--z[2]--cycle ;
  r := unitsquare xyscaled (1cm,1cm) shifted(0,3cm) ;
  b := unitsquare xyscaled (3cm,3cm) shifted(1cm,0) ;
  draw p ;
  draw r withcolor red;
  draw r numberstriped (.25,20,5) withcolor magenta ;
  draw b numberstriped (.25,20,5) withcolor magenta ;
  label.llft("D", p) ;
  label.lrt("C", p) ;
  label.ulft("A", p) ;
  label.urt("B", p) ;
  label.urt("P", lrcorner r) ;
  label.lft("Q", llcorner r) ;
  label.top("M", urcorner r) ;

  \stopMPcode
\stoptext
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Size of all subscripts

2022-08-22 Thread Fabrice Couvreur via ntg-context
Hello
How to reduce the size of all subscripts in math mode ?
Thanks
Fabrice

\usemodule[tikz]
 \protected\def\vector#1{%
 \starttikzpicture[baseline=(arg.base),>=stealth]
 \node[inner xsep=0pt] (arg) {\m{#1}};
 \draw[thick,->,shorten >=-1pt] (arg.north west) -- (arg.north east);
\stoptikzpicture%
}
\starttext
 \m{z_{\vector{U}}}
\stoptext
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Special numbering

2022-08-17 Thread Fabrice Couvreur via ntg-context
Hi  Aditya,
Thanks for your help, it works perfectly.
Fabrice

Le mer. 17 août 2022 à 17:48, Aditya Mahajan via ntg-context <
ntg-context@ntg.nl> a écrit :

> On Wed, 17 Aug 2022, Fabrice Couvreur via ntg-context wrote:
>
> > Hello,
> > how to get this
> > Définition 1.1.
> > Proposition 1.2.
> > Définition 1.3.
> > Proposition 1.4.
> >
> > Thanks
> > Fabrice
> >
> > \setupenumerations
> >   [before={\blank},
> >after={\blank},
> >alternative=serried,
> >distance=0.5em,
> >title=yes,
> >titleleft=,
> >titleright=,
> >titlestyle=normal,
> >prefix=yes,
> >prefixsegments=chapter,
> >way=bychapter,
> >headcommand=\groupedcommand{}{.},
> >numbercommand=\groupedcommand{}{},
> >titlecommand=\groupedcommand{(}{)},
> >width=broad]
> >
> > \defineenumeration
> >[definition]
> >[text=Définition,
> > number=yes,
> > style=italic]
> >
> > \defineenumeration
> >[proposition]
> >[text=Proposition,
> > number=yes,
>
> Add:
>
>   counter=definition,
>
> > style=italic]
>
>
> Now, definition and proposition share the same counter.
>
>
> Aditya___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> https://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : https://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Special numbering

2022-08-17 Thread Fabrice Couvreur via ntg-context
Hello,
how to get this
Définition 1.1.
Proposition 1.2.
Définition 1.3.
Proposition 1.4.

Thanks
Fabrice

\setupenumerations
  [before={\blank},
   after={\blank},
   alternative=serried,
   distance=0.5em,
   title=yes,
   titleleft=,
   titleright=,
   titlestyle=normal,
   prefix=yes,
   prefixsegments=chapter,
   way=bychapter,
   headcommand=\groupedcommand{}{.},
   numbercommand=\groupedcommand{}{},
   titlecommand=\groupedcommand{(}{)},
   width=broad]

\defineenumeration
   [definition]
   [text=Définition,
number=yes,
style=italic]

\defineenumeration
   [proposition]
   [text=Proposition,
number=yes,
style=italic]

\starttext
\startchapter
  [title={First chapter}]
  \dorecurse{2}{
\startdefinition

\stopdefinition
\startproposition

\stopproposition}
\stopchapter
\stoptext
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Numbercommand and title

2022-08-12 Thread Fabrice Couvreur via ntg-context
Hello,
How to make the period after the number be after the second parenthesis
when there is a title like this  Définition 1.1 (Title). ?
Thanks
Fabrice


\definestructureconversionset [structure] [n, R, n, n, n] [n]

\defineconversionset [digit] [] [n]

\setupheads[sectionconversionset=structure]

\setupenumerations
  [before={\blank},
   after={\blank},
   alternative=serried,
   distance=0.5em,
   title=yes,
   titleleft=,
   titleright=,
   titlestyle=normal,
   numbercommand=\groupedcommand{}{.},
   titlecommand=\groupedcommand{(}{)},
   width=broad,
   way=bychapter,
   prefix=yes,
   prefixsegments=chapter,
   prefixconversionset=digit,]

\defineenumeration
   [definition]
   [text=Définition,
number=yes,
style=italic]

\starttext
\startchapter
  [title={First Chapter}]
  \startdefinition
[title={My first définition}]
\input{ward}
  \stopdefinition
  \startdefinition
\input ward
  \stopdefinition
  \startdefinition
[title={My third définition}]
\input ward
  \stopdefinition
\stopchapter
\stopchapter
\stoptext
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Font too small with a macro

2022-04-23 Thread Fabrice Couvreur via ntg-context
Hi,
I didn't know that \exp was already defined.
Thanks
Fabrice

Le sam. 23 avr. 2022 à 15:28, Mikael Sundqvist via ntg-context <
ntg-context@ntg.nl> a écrit :

> On Sat, Apr 23, 2022 at 12:11 PM Fabrice Couvreur via ntg-context
>  wrote:
> >
> > Hello,
> > If I compile with context the expected result is correct but with lmtx
> the font under the square root is smaller.
> > Thank you
> > Fabrice
> >
> > \protected\def\exp{\text{\normal exp}}
> >
> > \starttext
> > \startformula
> >\sqrt{\exp(x)}=\exp\left(\frac{x}{2}\right).
> > \stopformula
> > \stoptext
>
> Hi,
>
> without your redefinition of \exp it looks fine (exp is already
> defined). Does that solve your problem, or are you doing something
> else, and this exp was just an example?
>
> Best, Mikael
>
> ___
> 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
___


[NTG-context] Font too small with a macro

2022-04-23 Thread Fabrice Couvreur via ntg-context
Hello,
If I compile with context the expected result is correct but with lmtx the
font under the square root is smaller.
Thank you
Fabrice

\protected\def\exp{\text{\normal exp}}

\starttext
\startformula
   \sqrt{\exp(x)}=\exp\left(\frac{x}{2}\right).
\stopformula
\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] the resolver databases are not present or outdated

2022-03-05 Thread Fabrice Couvreur via ntg-context
Hello,
Some files no longer compile, I tried updating lmtx but I get this.
Thank you
Fabrice

viserion@archlinux LMTX]$ install install.sh
install: opérande de fichier cible manquant après 'install.sh'
Saisissez « install --help » pour plus d'informations.
[viserion@archlinux LMTX]$ sh install.sh
mtxrun  | forcing cache reload
resolvers   | resolving | looking for regular 'texmfcnf.lua' on given
path '/home/viserion/texmf/web2c' from specification 'home:texmf/web2c'
resolvers   | resolving | looking for regular 'texmfcnf.lua' on given
path '/home/viserion/texmf-local/web2c' from specification
'selfautoparent:/texmf-local/web2c'
resolvers   | resolving | looking for regular 'texmfcnf.lua' on given
path '/home/viserion/texmf-context/web2c' from specification
'selfautoparent:/texmf-context/web2c'
resolvers   | resolving | looking for regular 'texmfcnf.lua' on given
path '/home/viserion/texmf-dist/web2c' from specification
'selfautoparent:/texmf-dist/web2c'
resolvers   | resolving | looking for regular 'texmfcnf.lua' on given
path '/home/viserion/texmf/web2c' from specification
'selfautoparent:/texmf/web2c'
resolvers   | resolving | looking for fallback 'contextcnf.lua' on
given path '/home/viserion/texmf/web2c' from specification
'home:texmf/web2c'
resolvers   | resolving | looking for fallback 'contextcnf.lua' on
given path '/home/viserion/texmf-local/web2c' from specification
'selfautoparent:/texmf-local/web2c'
resolvers   | resolving | looking for fallback 'contextcnf.lua' on
given path '/home/viserion/texmf-context/web2c' from specification
'selfautoparent:/texmf-context/web2c'
resolvers   | resolving | looking for fallback 'contextcnf.lua' on
given path '/home/viserion/texmf-dist/web2c' from specification
'selfautoparent:/texmf-dist/web2c'
resolvers   | resolving | looking for fallback 'contextcnf.lua' on
given path '/home/viserion/texmf/web2c' from specification
'selfautoparent:/texmf/web2c'
resolvers   | resolving |
resolvers   | resolving | warning: no lua configuration files found
resolvers   | resolving | no texmf paths are defined (using TEXMF)
resolvers   | resolving |
mtxrun  | the resolver databases are not present or outdated
mtx-install | provide valid server and instance
___
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] new upload

2022-01-15 Thread Fabrice Couvreur via ntg-context
Hi Hans
I just updated lmtx and this macro does not work although it did before. On
the other hand, no problem with context.
Thanks.
Fabrice

 \protected\def\e#1{\math{{\rm e}^{#1}}\autoinsertnextspace}

\starttext
\startformula
\e{a+b}
\stopformula
\stoptext


Le sam. 15 janv. 2022 à 16:14, Hans Hagen via ntg-context <
ntg-context@ntg.nl> a écrit :

> On 1/15/2022 3:52 PM, Alexandre Christe via ntg-context wrote:
> > Just came across a weird behavior with the latest upload.
> >
> > The following doesn't print as it should
> > \startformula 4^{2x} - 4^x - 25 = 0 \stopformula
> >
> > I don't think it's normal (I see the spacing to make room for anything
> > that comes after the first character in the exposant, but it is not
> > printed).
> i'll fix it ...
>
>
>
> -
>Hans Hagen | PRAGMA ADE
>Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
> -
>
> ___
> 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
___


[NTG-context] Strange behavior with \startbodymatter ... \stopbodymatter

2021-12-28 Thread Fabrice Couvreur via ntg-context
Hi,
In my file cours_premiere.tex if I indicate

 \startbodymatter
\component[probabilites.tex]
 \stopbodymatter

I get the following error message

tex error   > tex error on line 49 in file ./cours_premiere.tex:
Undefined control sequence \pgfmath@settrigformat


\pgfmath@settrigformat
\pgfmath@settrigformat \pgfmath@settrigformat

\stopbodymatter

39[criterium=all,
40interaction=all,
41 alternative=c]
42
43   \stoptitle
44
45 \stopfrontmatter
46
47 \startbodymatter
48 \component[probabilites.tex]
49 >>  \stopbodymatter
50
51
52 \stopproduct
The control sequence at the end of the top line of your error message was
never
\def'ed. You can just continue as I'll forget about whatever was undefined.
mtx-context | fatal error: return code: 1

TeX Output exited abnormally with code 1 at Tue Dec 28 15:31:31


On the other hand, if I indicate

\component[probabilites.tex]

 the file compiles without error.
Thanks
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
___


[NTG-context] Compilation error with the new version of lmtx

2021-10-16 Thread Fabrice Couvreur via ntg-context
Hi,
The latest version of lmtx does not allow me to compile the following file
although there was no problem before.
Thank you
Fabrice

\startproduct[expertes-manual]

  \startfrontmatter

\setuppagenumbering
   [location=]

\definefont
  [ChapterTextStyle]
  [SansBold*default sa 2.2]

\setuphead
  [title]
  [style=ChapterTextStyle,
   align=flushright]

\setuplist
   [chapter]
   [style=bold,
alternative=b,
width=1em]

\setuplist
   [section]
   [margin=1em,
width=1.75em]

\setuplist
   [subsection]
   [margin=2.75em,
width=2em,
distance=\spaceamount]


\starttitle[title=Table des matières]

 \placelist
   [chapter,section,subsection]
   [criterium=all,
   interaction=all,
alternative=c]

  \stoptitle

\stopfrontmatter

\startbodymatter
\component[chapter_1]
\component[chapter_2]
\stopbodymatter


\stopproduct

##
tex error   > tex error on line 1 in file ./expertes.tex: Undefined
control sequence \undefined




\relax
 \p_maxwidth
\dostarttagged \t!listcontent \empty \clf_listtitle {\currentlist
}\currentlistindex \relax
\dostoptagged
 \strc_lists_limitated_text
#1->\edef \p_maxwidth {\listparameter \c!maxwidth }\ifempty \p_maxwidth
\listparameter \c!textcommand {#1}
\else \listparameter \c!textcommand {\limitatetext {#1}\p_maxwidth
{\splitsymbol {\listparameter \c!limittext }}}\fi
 \22>:140>:abc
...rence_attribute \v!text \strc_lists_set_style_color \c!textstyle
\c!textcolor \v!text \the \t_lists_every_renderingtext \the
\t_lists_every_renderingsynchronize \setstrut \begstrut
\strc_lists_limitated_text \currentlistentrytitle
\endstrut \en ...
 \currentlistextra
...\begingroup \ifempty \m_strc_list_alternative \edef
\currentlistalternative {\listparameter \c!alternative }\else \let
\currentlistalternative \m_strc_list_alternative \fi \directsetup
{\listalternativeparameter \c!renderingsetup }
\relax \endgr ...
 ...


alternative=c]

 1 >>  \startproduct[expertes-manual]
 2
 3   \startfrontmatter
 4
 5 \setuppagenumbering
 6[location=]
 7
 8 \definefont
 9   [ChapterTextStyle]
10   [SansBold*default sa 2.2]
11
The control sequence at the end of the top line of your error message was
never
\def'ed. You can just continue as I'll forget about whatever was undefined.
mtx-context | fatal error: return code: 256

TeX Output exited abnormally with code 1 at Sat Oct 16 19:28:21
___
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] Framedtext : text out of frame

2021-09-26 Thread Fabrice Couvreur via ntg-context
Hi,
How to fix the small problem in the code below where the text goes out of
the frame ?
Thanks
Fabrice

\usecolors[x11]

\starttext
  \startframedtext[frame=off,width=\textwidth,
align={broad,right},indenting={yes},background=color,backgroundcolor=navajowhite1]
  \startitemize[columns,three,n]
\startitem
 Une quantité constante est une quantité déterminée, qui conserve
toujours la même valeur.
\stopitem\par
\startitem
  Une quantité variable est une quantité indéterminée, ou, si l'on
veut, une quantité universelle, qui comprend toutes les valeurs déterminées.
\stopitem\par
\startitem
  Une quantité variable devient déterminée, lorsqu'on lui attribue
une valeur déterminée quelconque.
\stopitem\par
\startitem
  Une fonction de quantité variable est une expression analytique
composée, de quelque manière que ce soit, de cette même quantité & de
nombres, ou de quantités constantes.

  Par exemple, \m{a+3z} ; \m{az-4zz} ;

  \m{az+b\sqrt{aa-zz}} , cz ; \m{etc}. sont des

  fonctions de \m{z}.
\stopitem\par
\startitem
  Une fonction de variable est

  donc aussi une quantité variable.
\stopitem\par
  \stopitemize
\stopframedtext
\stoptext1
___
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] Image cropped

2021-09-13 Thread Fabrice Couvreur via ntg-context
Hi Wolfgang,
I had done the same thing but I thought this solution was not the most
elegant, and I wanted to know what the specialists were going to do.
Thank you.
Fabrice

Le dim. 12 sept. 2021 à 16:50, Wolfgang Schuster via ntg-context <
ntg-context@ntg.nl> a écrit :

> Fabrice Couvreur via ntg-context schrieb am 12.09.2021 um 12:10:
>
> Hi Wolfgang,
> That's what I understood but the problem is that if I reduce the margin,
> the logo is too small in my opinion : what would you do ?
>
>
> Place the logo with a layer or shift is inwards.
>
> \setuplayout
>   [width=middle,
>height=middle]
>
> \setupfootertexts
>   [margin]
>   []
>   [{\offset[x=-1cm,y=\strutdp]{\externalfigure[logo.pdf][factor=max]}}]
>   []
>   [{\offset[x=1cm,y=\strutdp]{\externalfigure[logo.pdf][factor=max]}}]
>
> %\showframe
>
> \starttext
> \dorecurse{8}{\samplefile{knuth}}
> \stoptext
>
> Wolfgang
>
>
> ___
> 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] Image cropped

2021-09-12 Thread Fabrice Couvreur via ntg-context
Hi Wolfgang,
That's what I understood but the problem is that if I reduce the margin,
the logo is too small in my opinion : what would you do ?
Indeed the line is green but you will have understood: =)
Fabrice

Le sam. 11 sept. 2021 à 19:17, Wolfgang Schuster via ntg-context <
ntg-context@ntg.nl> a écrit :

> Fabrice Couvreur via ntg-context schrieb am 11.09.2021 um 17:52:
>
> Hi Wolfgang,
> The red frame is the print area ?
>
>
> The *green* frame are the margins of the A4 paper which is positioned in
> the middle of the A3 paper.
>
> The larger paper allows you to the see the part of the margins which are
> outside of the printable area.
>
> Wolfgang
>
>
> ___
> 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] Image cropped

2021-09-11 Thread Fabrice Couvreur via ntg-context
Hi Wolfgang,
The red frame is the print area ?

Le sam. 11 sept. 2021 à 16:43, Wolfgang Schuster via ntg-context <
ntg-context@ntg.nl> a écrit :

> Fabrice Couvreur via ntg-context schrieb am 11.09.2021 um 16:32:
>
> Hello,
> I like to put a logo on my statements but I noticed that the image is
> cropped on the edge.
> I tried to change the printer's print settings but was unsuccessful.
>
>
> Add these settings to your example and you see the problem.
>
> \setuppapersize[A4][A3]
>
> \setuplayout[location=middle]
>
> \setuplayout[width=middle,height=middle]
>
> \setupfootertexts
>[margin]
>[]
>[{\offset[y=\strutdp]{\externalfigure[logo.pdf][factor=max]}}]
>[]
>[{\offset[y=\strutdp]{\externalfigure[logo.pdf][factor=max]}}]
>
> \showframe
>
> \starttext
> \dorecurse{8}{\input knuth}
> \stoptext
>
>
> Wolfgang
>
>
> ___
> 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
___


[NTG-context] Image cropped

2021-09-11 Thread Fabrice Couvreur via ntg-context
Hello,
I like to put a logo on my statements but I noticed that the image is
cropped on the edge.
I tried to change the printer's print settings but was unsuccessful.
Thanks
Fabrice

\setuplayout[width=middle,height=middle]

\setupfootertexts
   [margin]
   []
   [{\offset[y=\strutdp]{\externalfigure[logo.pdf][factor=max]}}]
   []
   [{\offset[y=\strutdp]{\externalfigure[logo.pdf][factor=max]}}]

\showframe

\starttext
\dorecurse{8}{\input knuth}
\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] getting line numbers

2021-09-05 Thread Fabrice Couvreur via ntg-context
Hi,
I am trying to test this file but without success.
I just do context test.tex but I suspect that is not it.
When you say

> We compile and run:
>

Which command is it with ?
Thanks
Fabrice

Le ven. 3 sept. 2021 à 18:26, Hans Hagen via ntg-context 
a écrit :

> On 9/3/2021 3:53 PM, Aditya Mahajan via ntg-context wrote:
> > On Fri, 3 Sep 2021, Thierry Horsin via ntg-context wrote:
> >
> >> Hi everybody
> >>
> >> Is there a way to have an automatic access to the current line number
> of a specific place inside a tex file ? To be more precise, here is what I
> would like to do.
> >
> > Also look at the filter module.
> >
> >  https://github.com/adityam/filter
> >
> > Behind the scenes, it works by saving the content in an external file
> and then
> > running it through any external program. It also allows for caching the
> > result, and has many options for customizing the behavior.
> you forgot to mention that it also makes sure that you only process when
> there has been a change (after all calling gcc comes at a price)
>
> Hans
>
> -
>Hans Hagen | PRAGMA ADE
>Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
> -
>
> ___
> 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] Test for displaying a header

2021-08-26 Thread Fabrice Couvreur via ntg-context
Hi,
Using this (but it's not exactly what I want) it works

test-1.tex %%

\setuppagenumbering
  [alternative=doublesided,location=]

\definelayout
  [1]
  [header=10mm]

\setuplayout
  [header=0pt,
   height=middle]

\setupbackgrounds
   [header]
   [text]
   [frame=off,bottomframe=on,
 framecolor=lightgray,rulethickness=1pt]


\starttext
\dorecurse{5}{\samplefile{lorem}}
%\dorecurse{1}{\samplefile{lorem}}
\stoptext

%%ù

Using this (almost what I'm trying to do) without success

test-2.tex %
\setuppagenumbering
  [alternative=doublesided,location=]

\setupbackgrounds
  [header]
  [text]
  [frame=off,bottomframe=on,
   framecolor=lightgray,rulethickness=1pt]

\startsetups[header]
  \doifelse{\totalnumberofpages}{1}
{\setupheadertexts[\setups{header}]}
{}
\stopsetups


\starttext
\dorecurse{5}{\samplefile{lorem}}
%\dorecurse{1}{\samplefile[lorem]r}
\stoptext

%%%

Fabrice


Le jeu. 26 août 2021 à 17:56, Wolfgang Schuster via ntg-context <
ntg-context@ntg.nl> a écrit :

> Taco Hoekwater via ntg-context schrieb am 26.08.2021 um 16:34:
> >
> > Hi,
> >
> >> On 26 Aug 2021, at 16:07, Fabrice Couvreur via ntg-context <
> ntg-context@ntg.nl> wrote:
> >>
> >> Hi,
> >> I know I asked the question a few years ago, but I don't remember !
> >> The idea is to test whether the document contains only one page or not.
> >
> > Perhaps not the nicest solution, but this works:
> >
> > \doifvalueelse
> >{\lastpage}
> >{1}
> >{\message{true}}
> >{\message{false}}
>
>
> Same solution but better counter name:
>
> \doifelse{\totalnumberofpages}{1}{...}{...}
>
> Wolfgang
>
> ___
> 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
___


[NTG-context] Test for displaying a header

2021-08-26 Thread Fabrice Couvreur via ntg-context
Hi,
I know I asked the question a few years ago, but I don't remember !
The idea is to test whether the document contains only one page or not.
If it contains only one page, the header is enabled.
If it contains several pages, the header is enabled only on the first page
but not on the others.
Thanks
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
___


[NTG-context] Place a logo at the bottom of the page with a layer

2021-08-24 Thread Fabrice Couvreur via ntg-context
Hi,
I want to insert a logo at the bottom of the page on the right on the first
page, on the left on the second, on the right on the third ...
With the key repeat=yes, the logo is always at the bottom right
Thanks
Fabrice

\useMPlibrary[dum]

\definelayer
   [MyLogo]
   [x=0mm, y=0mm,
width=\paperwidth,
height=\paperheight,
repeat=yes]


\setupbackgrounds[page][background=MyLogo]

\setlayer
  [MyLogo]
  [hoffset=\dimexpr\textwidth+\backspace+\rightmargindistance\relax,
   voffset=\dimexpr\topspace+\textheight+\footerheight\relax]
   {\externalfigure[dum][width=\rightmarginwidth,height=\headerheight]}

\showframe

\starttext
\dorecurse{20}{\samplefile{lorem}}
\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] Adjustment for header and footer

2021-08-22 Thread Fabrice Couvreur via ntg-context
Hi,
In the file below (not minimal, sorry!) I am using commands from Wolfgang
in different threads. We can see that the top frame overflows into the
text: how to correct this ?
I would also like the top and bottom stroke to be adjusted to the width of
the paper.
Thanks
Fabrice

\useMPlibrary[dum]

\setuplayout
   [topspace=1cm,
backspace=3cm,
cutspace=3cm,
leftmargin=.75cm,
leftmargindistance=.5cm,
rightmargin=1.25cm,
rightmargindistance=1cm,
header=20mm,
headerdistance=1cm,
footer=20mm,
footerdistance=1cm,
width=middle,
height=middle,
location=middle]

\setupbodyfont
   [newcomputermodern-book,11pt]

\definefont
   [TextStyle]
   [SansBold*default sa 1.2]


\defineframed
  [headerframed]
  [frame=off,
   height=fit,
   width=fit,
  ]

\setupbackgrounds [header] [text]
   [frame=off,bottomframe=on,width=\widthpaper,
framecolor=darkred,rulethickness=1pt]

\setupbackgrounds [footer] [text]
   [frame=off,bottomframe=on,width=max,
   framecolor=darkred,rulethickness=1pt]

 \setupfootertexts
  [margin]
  []
  [{\offset[y=\strutdp]{\externalfigure[dum][factor=max]}}]
  []
  [{\offset[y=\strutdp]{\externalfigure[dum][factor=max]}}]

\startsetups [headertext]

\setupheadertexts
[{
\startframed [headerframed]
[foregroundstyle=TextStyle,align=middle]
\getvariable{headertext}{location}\\
 Spécialité mathématiques\\
\getvariable{headertext}{title} n\high{\tfxx \bf
o}\,\getvariable{headertext}{number}
\stopframed
}]

\setupheadertexts
[{
\startframed [headerframed]
[align=flushleft,foregroundstyle=\ssx]
Lycée LA SALLE\\
Durée : \getvariable{headertext}{time}\\

\date[d=\getvariable{headertext}{day},m=\getvariable{headertext}{month},y=\getvariable{headertext}{year}]
\stopframed
}]
[{
\startframed [headerframed]
[align=flushright,foregroundstyle=\ssx]
  \externalfigure[dum] [factor=max]
\stopframed
}]

\stopsetups

\setvariable{headertext}{set}{\directsetup{headertext}}


\setvariables
  [headertext]
  [title={Devoir maison},
   number={2},
   day={22},
   month={08},
   year={2021},
   location={Terminale},
   time={2 heures}]


\starttext
\samplefile{lorem}
\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] Strange behavior of a macro

2021-08-16 Thread Fabrice Couvreur via ntg-context
Hello,
I don't understand why this macro works with this simple example but return
the following error if I use it for chapters in my book.
Thanks
Fabrice


\setupbodyfont
   [newcomputermodern-book,11pt]

\unexpanded\def\N{\math{\mathbb{N}}\autoinsertnextspace}

\defineenumeration
   [test]
   [title=yes,
text={Test},
style=italic]

\starttext
\N
\starttest
\m{\forall n \in \N}
\stoptest
\stoptext


tex error   > tex error on line 64 in file ./terminale_suites_2.tex:
Use of \N doesn't match its definition




  Soient \u, \v deux suites définies sur \N,
 \m{l} et \m{l'} deux réels.

54 \startitem
55   \u converge vers \m{l},
56 \stopitem
57   \stopitemize
58   alors \m{l\geqslant 0}.
59 \stopproposition
60 \startremarque
61   Nous retiendrons que le passage à la limite sur une
inégalité stricte restitue une inégalité large.
62 \stopremarque
63 \startcorollaire
64 >>Soient \u, \v deux suites définies sur \N, \m{l} et \m{l'}
deux réels.
65
66   Si
67
68   \startitemize
69 \startitem
70   les suites \u et \v convergent respectivement vers
\m{l} et \m{l'},
71 \stopitem
72 \startitem
73   \m{\forall n \in\mathbb{N}, \thinspace u_n>v_n},
74 \stopitem
If you say, e.g., '\def\a1{...}', then you must always put '1' after '\a',
since control sequence names are made up of letters only. The macro here
has not
been followed by the required stuff, so I'm ignoring it.
mtx-context | fatal error: return code: 256

___
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] How not to display the header of the chapter page on the page with the table of contents ?

2021-08-16 Thread Fabrice Couvreur via ntg-context
Hi Wolfgang,
Pablo's solution works, but I tried yours without success. Here are the
main lines of my project

 begin product
\startproduct[terminale-manual]

\project[terminale-environment]

\startdocument

\startfrontmatter
...
\stopfrontmatter

\startbodymatter
\component[terminale_recurrence]
...
\stopbodymatter

\stopdocument

\stopproduct
 end product

 begin project
\startproject[terminale-environment]

\environment[terminale-style]
 ...
\stopproject
 end project

 begin component
\project[terminale-environment]

\startcomponent[terminale_recurrence]
...
\endcomponent
 end component

 begin environment
\startenvironment[terminale-style]
...
\startsetups [section:chapter]

\setuphead
   [chapter]
   [align=flushright,
textcommand=\groupedcommand{\blank[medium]}{},
numbercolor=darkgray,
textstyle=ChapterTextStyle,
numberstyle=ChapterNumberStyle,
before=\startChapterFrame,
after=\stopChapterFrame,
header=high]

\stopsetups

\startsectionblockenvironment [bodypart]
 \directsetup{section:chapter}
\stopsectionblockenvironment

\doifmode{*component}{\directsetup{section:chapter}}

...
\endenvironment
 end environment

Le dim. 15 août 2021 à 19:03, Wolfgang Schuster via ntg-context <
ntg-context@ntg.nl> a écrit :

> Pablo Rodriguez via ntg-context schrieb am 15.08.2021 um 18:33:
> > On 8/15/21 6:02 PM, Fabrice Couvreur via ntg-context wrote:
> >> A small note : this method works if I compile the project but if I
> >> compile only one chapter, the header no longer appears.
> > Hi Fabrice,
> >
> > I have never used projects and chapters (or whatever the right name is).
> >
> > I’m not sure I get what you’re experiencing: with a single chapter, do
> > you have the fancy layout or not?
> >
> > It would make sense that the fancy chapter doesn’t appear only compiling
> > a chapter. I guess there is no \startbodymatter...\stopbodymatter
> > wrapping it.
> >
> > Another approach would be:
> >
> > [...]
>
> Setting values for \title is a way to avoid the chapter setup for the
> table of contents etc.
> but there is a way to set values which are used only when you process a
> component file.
>
> To make it work one has to load the environment file after
> \startcomponent because you
> can use the *component mode to check whether the parent file is a
> product or a component.
>
>  begin product
> \startproduct [*]
>
> \environment [...]
>
> \startfrontmatter
> ...
> \stopfrontmatter
>
> \startbodymatter
> \component [...]
> \stopbodymatter
>
> \stopproduct
>  end product
>
>  begin component
> \startcomponent [*]
>
> \environment [...]
>
> ...
>
> \stopcomponent
>  end component
>
>  begin environment
> \startenvironment [*]
>
> \startsetups [section:chapter]
>
>  \setuphead
>  [chapter]
>  [...]
>
> \stopsetups
>
> \startsectionblockenvironment [bodypart]
>  \directsetup{section:chapter}
> \stopsectionblockenvironment
>
> \doifmode{*component}{\directsetup{section:chapter}}
>
> \stopenvironment
>  end environment
>
> Wolfgang
>
>
> ___
> 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
___


[NTG-context] Adjustment in the table of contents

2021-08-16 Thread Fabrice Couvreur via ntg-context
Hi,
I wish to have the table of contents as the attached image. The result is
almost as expected except for the margin of the subsection.

 \setuplist
   [chapter,section,subsection]
   [width=fit,distance=\spaceamount]

 \setuplist
   [chapter]
   [alternative=b]

 \setuplist [chapter][style=bold]


 \setuplist [section][margin=1em]
 \setuplist [subsection] [margin=2.75em]

Thanks
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
___


Re: [NTG-context] How not to display the header of the chapter page on the page with the table of contents ?

2021-08-15 Thread Fabrice Couvreur via ntg-context
Hi Pablo,
The second solution works as I want it to
Thanks
Fabrice

Le dim. 15 août 2021 à 18:33, Pablo Rodriguez via ntg-context <
ntg-context@ntg.nl> a écrit :

> On 8/15/21 6:02 PM, Fabrice Couvreur via ntg-context wrote:
> > A small note : this method works if I compile the project but if I
> > compile only one chapter, the header no longer appears.
>
> Hi Fabrice,
>
> I have never used projects and chapters (or whatever the right name is).
>
> I’m not sure I get what you’re experiencing: with a single chapter, do
> you have the fancy layout or not?
>
> It would make sense that the fancy chapter doesn’t appear only compiling
> a chapter. I guess there is no \startbodymatter...\stopbodymatter
> wrapping it.
>
> Another approach would be:
>
> \setuphead
>[chapter]
>[align=flushright,
> textcommand=\groupedcommand{\blank[medium]}{},
> numbercolor=darkgray,
> textstyle=ChapterTextStyle,
> numberstyle=ChapterNumberStyle,
> before=\startChapterFrame,
> after=\stopChapterFrame,
> header=high]
>
> \setuphead
>   [title]
>   [header=empty,
>align=,
>textcommand=,
>textstyle=,
>style=\tfc,
>before={\blank[2*big]},
>after={\blank[2*big]}]
>
> 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] How not to display the header of the chapter page on the page with the table of contents ?

2021-08-15 Thread Fabrice Couvreur via ntg-context
A small note : this method works if I compile the project but if I compile
only one chapter, the header no longer appears.

Le dim. 15 août 2021 à 17:01, Fabrice Couvreur 
a écrit :

> Hi Pablo,
> Thanks, it works.
> Fabrice
>
> Le dim. 15 août 2021 à 16:20, Pablo Rodriguez via ntg-context <
> ntg-context@ntg.nl> a écrit :
>
>> On 8/15/21 12:49 PM, Fabrice Couvreur via ntg-context wrote:
>> > Hello,
>> > Wolfgang created a
>> > heading https://mailman.ntg.nl/pipermail/ntg-context/2021/102870.html
>> > for the chapters of my book.
>> > How can I prevent this header from appearing on the page with the table
>> > of contents ?
>>
>> Hi Fabrice,
>>
>> a simple way would be:
>>
>>   \startsectionblockenvironment[bodypart]
>> \setuphead
>>[chapter]
>>[align=flushright,
>> textcommand=\groupedcommand{\blank[medium]}{},
>> numbercolor=darkgray,
>> textstyle=ChapterTextStyle,
>> numberstyle=ChapterNumberStyle,
>> before=\startChapterFrame,
>> after=\stopChapterFrame,
>> header=high]
>>   \stopsectionblockenvironment
>>
>> Then use frontmatter and bodymatter.
>>
>> Just in case it might help,
>>
>> 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] How not to display the header of the chapter page on the page with the table of contents ?

2021-08-15 Thread Fabrice Couvreur via ntg-context
Hi Pablo,
Thanks, it works.
Fabrice

Le dim. 15 août 2021 à 16:20, Pablo Rodriguez via ntg-context <
ntg-context@ntg.nl> a écrit :

> On 8/15/21 12:49 PM, Fabrice Couvreur via ntg-context wrote:
> > Hello,
> > Wolfgang created a
> > heading https://mailman.ntg.nl/pipermail/ntg-context/2021/102870.html
> > for the chapters of my book.
> > How can I prevent this header from appearing on the page with the table
> > of contents ?
>
> Hi Fabrice,
>
> a simple way would be:
>
>   \startsectionblockenvironment[bodypart]
> \setuphead
>[chapter]
>[align=flushright,
> textcommand=\groupedcommand{\blank[medium]}{},
> numbercolor=darkgray,
> textstyle=ChapterTextStyle,
> numberstyle=ChapterNumberStyle,
> before=\startChapterFrame,
> after=\stopChapterFrame,
> header=high]
>   \stopsectionblockenvironment
>
> Then use frontmatter and bodymatter.
>
> Just in case it might help,
>
> 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
___


[NTG-context] How not to display the header of the chapter page on the page with the table of contents ?

2021-08-15 Thread Fabrice Couvreur via ntg-context
Hello,
Wolfgang created a heading
https://mailman.ntg.nl/pipermail/ntg-context/2021/102870.html for the
chapters of my book.
How can I prevent this header from appearing on the page with the table of
contents ?
Thanks
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
___


Re: [NTG-context] Create an enumeration style

2021-08-11 Thread Fabrice Couvreur via ntg-context
I forgot this : how to reduce the font size for the exponents "er", "e" ?
Thanks
Fabrice

Le mer. 11 août 2021 à 12:41, Fabrice Couvreur 
a écrit :

> Hi Wolfgang,
> Many thanks
> Fabrice
>
> Le mer. 11 août 2021 à 10:23, Hans Hagen via ntg-context <
> ntg-context@ntg.nl> a écrit :
>
>> On 8/11/2021 10:09 AM, Otared Kavian via ntg-context wrote:
>> >
>> >
>> >> On 9 Aug 2021, at 18:10, Wolfgang Schuster via ntg-context <
>> ntg-context@ntg.nl> wrote:
>> >> (…)
>> >> core-con.lua (line 1155):
>> >>
>> >> local ordinals = {
>> >>  [...]
>> >>  french = function(n)
>> >>  if n == 1 then
>> >>  return "er"
>> >> +   else
>> >> +   return "e"
>> >>  end
>> >>  end,
>> >> }
>> >
>> > Hi Wolfgang,
>> >
>> > Thanks for the example and the fix, but I would rather think that the «
>> french » part of ordinals should be
>> >
>> >   french = function(n)
>> >   if n == 1 then
>> >   return « er"
>> >   else
>> >return « ème"
>> >   end
>> >   end,
>> >
>> > Now if this were not accepted as a fix in core-con.lua, is there a way
>> for a user to change the default to the above choice in his document ?
>>
>> it is no problem to fix if you all can agree on what/how to fix ...
>>
>> Hans
>>
>>
>> -
>>Hans Hagen | PRAGMA ADE
>>Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
>> tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
>> -
>>
>> ___
>> 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] Create an enumeration style

2021-08-11 Thread Fabrice Couvreur via ntg-context
Hi Wolfgang,
Many thanks
Fabrice

Le mer. 11 août 2021 à 10:23, Hans Hagen via ntg-context 
a écrit :

> On 8/11/2021 10:09 AM, Otared Kavian via ntg-context wrote:
> >
> >
> >> On 9 Aug 2021, at 18:10, Wolfgang Schuster via ntg-context <
> ntg-context@ntg.nl> wrote:
> >> (…)
> >> core-con.lua (line 1155):
> >>
> >> local ordinals = {
> >>  [...]
> >>  french = function(n)
> >>  if n == 1 then
> >>  return "er"
> >> +   else
> >> +   return "e"
> >>  end
> >>  end,
> >> }
> >
> > Hi Wolfgang,
> >
> > Thanks for the example and the fix, but I would rather think that the «
> french » part of ordinals should be
> >
> >   french = function(n)
> >   if n == 1 then
> >   return « er"
> >   else
> >return « ème"
> >   end
> >   end,
> >
> > Now if this were not accepted as a fix in core-con.lua, is there a way
> for a user to change the default to the above choice in his document ?
>
> it is no problem to fix if you all can agree on what/how to fix ...
>
> Hans
>
>
> -
>Hans Hagen | PRAGMA ADE
>Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
> -
>
> ___
> 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
___


[NTG-context] Create an enumeration style

2021-08-08 Thread Fabrice Couvreur via ntg-context
Hello,
Is it possible to create an enumeration style to get this :
1 ^ {er} exemple
2 ^ {e}  exemple
3 ^ {e} exemple 
Thanks
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
___


Re: [NTG-context] Question about \groupedcommand{}{}

2021-07-28 Thread Fabrice Couvreur via ntg-context
Hi Wolfgang,
Thank you for this nice solution.
Fabrice

Le mar. 27 juil. 2021 à 21:31, Wolfgang Schuster via ntg-context <
ntg-context@ntg.nl> a écrit :

> Fabrice Couvreur via ntg-context schrieb am 27.07.2021 um 18:57:
> > Hi,
> > The name of the environment must always end with a dot both with a title
> > and without title. How to do ?
> > Thanks
> > Fabrice
> >
> > [...]
>
>
> You can create simple dummy environments to test the parameters.
>
> \defineenumeration
>[grouptest]
>[title=yes,
>  text={dummy text},
> titleleft=,
>titleright=,
>   headcommand=\groupedcommand{[}{]},
> numbercommand=\groupedcommand{(}{)},
>  titlecommand=\groupedcommand{<}{>}]
>
> \starttext
>
> \startgrouptest [title={dummy title}]
> \unknown
> \stopgrouptest
>
> \startgrouptest
> \unknown
> \stopgrouptest
>
> \blank[2*line]
>
> \setupenumeration
>[grouptest]
>[number=no]
>
> \startgrouptest [title={dummy title}]
> \unknown
> \stopgrouptest
>
> \startgrouptest
> \unknown
> \stopgrouptest
>
> \stoptext
>
> Wolfgang
>
> ___
> 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
___


[NTG-context] Question about \groupedcommand{}{}

2021-07-27 Thread Fabrice Couvreur via ntg-context
Hi,
The name of the environment must always end with a dot both with a title
and without title. How to do ?
Thanks
Fabrice

\setupenumerations
  [before={\blank},
   after={\blank},
   alternative=serried,
   title=yes,
   titleleft={(},
   titleright={)},
   titlestyle=normal,
   titlecommand=\groupedcommand{}{\bf.},
   width=broad]

\defineenumeration
   [definition]
   [text=Définition,
number=no,
headcommand=\groupedcommand{}{},
style=italic]

\starttext
\startdefinition{With a title}
\samplefile{lorem}
\stopdefinition
Without title but no dot after the name of the environment.
\startdefinition
\samplefile{lorem}
\stopdefinition
\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] Macro that does not work in an environment

2021-07-27 Thread Fabrice Couvreur via ntg-context
Hello,
How to make the macro work in the environment definition ?
Thank you
Fabrice


\unexpanded\def\card#1{\math{\text{Card}\thinspace#1}}

\defineenumeration
   [definition]
   [text=Définition,
number=no,
headcommand=\groupedcommand{}{.},
style=italic]

\starttext

 \startdefinition
   Soit E un ensemble fini. Le cardinal de E, noté \card{E}, est le nombre
d'éléments de E.

   En particulier, nous avons  \m{\card{\emptyset}=0}.
 \stopdefinition

\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] Adjust the length of a frame

2021-07-27 Thread Fabrice Couvreur via ntg-context
-- Forwarded message -
De : Fabrice Couvreur 
Date: lun. 26 juil. 2021 à 13:13
Subject: Texte source 30 / 5000 Résultats de traduction Adjust the length
of a frame
To: mailing list for ConTeXt users 


Hello,
Following on from my previous questions for writing my book (thanks again
Wolfgang), I have to create a solution environment like the attached image.
My problem is adjusting the length of the frame.
Thank you.
Fabrice

\setupbodyfont[newcomputermodern-book,11pt]

\defineframed
   [ACFRAME]
   [frame=off,
width=fit,
align=flushleft,
location=low,
background=color,
backgroundcolor=lightgray,
foregroundcolor=,
foregroundstyle=]


\setupenumerations
  [before={\blank},
   after={\blank},
   alternative=top,
   title=yes,
   titleleft={},
   titleright={},
   titlestyle=bold,
   width=broad]

\defineenumeration
   [exercice]
   [text=Exercice,
number=yes,
numbercommand=\groupedcommand{}{.},
style=italic]

\defineenumeration
   [solution]
   [text=Solution,
headcommand=\ACFRAME,
number=no,
numbercommand=\groupedcommand{}{},
style=normal]

\starttext

\startexercice{Le nombre d'or est irrationnel}
  Le nombre d'or, noté \m{\phi}, est tel que
\m{\phi=\dfrac{1+\sqrt{5}}{2}}. Montrer que \m{\phi} est irrationnel.
\stopexercice

\startsolution
  Nous raisonnons par l'absurde en supposant que \m{\phi} est rationnel.
\stopsolution

\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] Adjust the length of a frame

2021-07-27 Thread Fabrice Couvreur via ntg-context
Le lun. 26 juil. 2021 à 13:13, Fabrice Couvreur 
a écrit :

> Hello,
> Following on from my previous questions for writing my book (thanks again
> Wolfgang), I have to create a solution environment like the attached image.
> My problem is adjusting the length of the frame.
> Thank you.
> Fabrice
>
> \setupbodyfont[newcomputermodern-book,11pt]
>
> \defineframed
>[ACFRAME]
>[frame=off,
> width=fit,
> align=flushleft,
> location=low,
> background=color,
> backgroundcolor=lightgray,
> foregroundcolor=,
> foregroundstyle=]
>
>
> \setupenumerations
>   [before={\blank},
>after={\blank},
>alternative=top,
>title=yes,
>titleleft={},
>titleright={},
>titlestyle=bold,
>width=broad]
>
> \defineenumeration
>[exercice]
>[text=Exercice,
> number=yes,
> numbercommand=\groupedcommand{}{.},
> style=italic]
>
> \defineenumeration
>[solution]
>[text=Solution,
> headcommand=\ACFRAME,
> number=no,
> numbercommand=\groupedcommand{}{},
> style=normal]
>
> \starttext
>
> \startexercice{Le nombre d'or est irrationnel}
>   Le nombre d'or, noté \m{\phi}, est tel que
> \m{\phi=\dfrac{1+\sqrt{5}}{2}}. Montrer que \m{\phi} est irrationnel.
> \stopexercice
>
> \startsolution
>   Nous raisonnons par l'absurde en supposant que \m{\phi} est rationnel.
> \stopsolution
>
> \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] Texte source 30 / 5000 Résultats de traduction Adjust the length of a frame

2021-07-26 Thread Fabrice Couvreur via ntg-context
Hello,
Following on from my previous questions for writing my book (thanks again
Wolfgang), I have to create a solution environment like the attached image.
My problem is adjusting the length of the frame.
Thank you.
Fabrice

\setupbodyfont[newcomputermodern-book,11pt]

\defineframed
   [ACFRAME]
   [frame=off,
width=fit,
align=flushleft,
location=low,
background=color,
backgroundcolor=lightgray,
foregroundcolor=,
foregroundstyle=]


\setupenumerations
  [before={\blank},
   after={\blank},
   alternative=top,
   title=yes,
   titleleft={},
   titleright={},
   titlestyle=bold,
   width=broad]

\defineenumeration
   [exercice]
   [text=Exercice,
number=yes,
numbercommand=\groupedcommand{}{.},
style=italic]

\defineenumeration
   [solution]
   [text=Solution,
headcommand=\ACFRAME,
number=no,
numbercommand=\groupedcommand{}{},
style=normal]

\starttext

\startexercice{Le nombre d'or est irrationnel}
  Le nombre d'or, noté \m{\phi}, est tel que
\m{\phi=\dfrac{1+\sqrt{5}}{2}}. Montrer que \m{\phi} est irrationnel.
\stopexercice

\startsolution
  Nous raisonnons par l'absurde en supposant que \m{\phi} est rationnel.
\stopsolution

\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
___