Re: [NTG-context] Referencing formulas doesn't work?

2020-02-09 Thread Exp
Please allow me to ask in this thread something slightly off-topic:
why doesn't ConTeXt give a compilation error or alike when
encountering such kind of mistakes? Is it technically difficult, or
is it conventional for *TeX processors to be over tolerant?

On Sun, Feb 9, 2020 at 11:05 PM Wolfgang Schuster <
wolfgang.schuster.li...@gmail.com> wrote:

> On Mon, 10 Feb 2020 05:58:50 +0800
> Jon Wong  wrote:
>
> > MWE:
> >
> > \starttext
> >
> > The famous result (and again) is given by
> > \placeformula[formulalabel]
> > \startformula
> > c^2 = a^2 + b^2.
> > \stopformula
> > And now we can refer to formula \ref[][formulalabel].
> >
> > \stoptext
> >
> > There is a blank where the formula label should be at “now we can refer
> to formula ---“.
>
> Use \ref[number][formulalabel] or \in[formulalabel].
>
> 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] Referencing formulas doesn't work?

2020-02-09 Thread Wolfgang Schuster
On Mon, 10 Feb 2020 05:58:50 +0800
Jon Wong  wrote:

> MWE:
> 
> \starttext
> 
> The famous result (and again) is given by
> \placeformula[formulalabel]
> \startformula
> c^2 = a^2 + b^2.
> \stopformula
> And now we can refer to formula \ref[][formulalabel].
> 
> \stoptext
> 
> There is a blank where the formula label should be at “now we can refer to 
> formula ---“.

Use \ref[number][formulalabel] or \in[formulalabel].

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
___


[NTG-context] Referencing formulas doesn't work?

2020-02-09 Thread Jon Wong
MWE:

\starttext

The famous result (and again) is given by
\placeformula[formulalabel]
\startformula
c^2 = a^2 + b^2.
\stopformula
And now we can refer to formula \ref[][formulalabel].

\stoptext

There is a blank where the formula label should be at “now we can refer to 
formula ---“.

Regards
Jon
___
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] zip downloads / mirror

2020-02-09 Thread Hans Hagen

On 2/9/2020 1:07 PM, Philipp Gesang wrote:

Hey guys,

some time during January the git mirror stopped syncing so I went
on pragma-ade.nl and noticed the old download URLs now 404.
Instead there one zip at this location:

 http://www.pragma-ade.nl/context/latest/cont-tmf.zip

I take it the “current” vs. “beta” model has been retired?


indeed, we're always latest now (as 'current' was mostly what ended up 
on tex live)



Cc: me please I’m not on the list, thanks!



Best regards,
Philipp

PS: I’m out of the loop; is the mirror actually still needed or
 is there an official repo now?
Mojca is working on a repository setup for sources (what we have now but 
also including luametatex sources), installation (including binaries 
taken from the compile farm), extras (like modules taken from the garden 
repository) so at some point we can make those official. Till then it's 
nice to have the existing one.


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
___


[NTG-context] zip downloads / mirror

2020-02-09 Thread Philipp Gesang
Hey guys,

some time during January the git mirror stopped syncing so I went
on pragma-ade.nl and noticed the old download URLs now 404.
Instead there one zip at this location:

http://www.pragma-ade.nl/context/latest/cont-tmf.zip

I take it the “current” vs. “beta” model has been retired?

Cc: me please I’m not on the list, thanks!

Best regards,
Philipp

PS: I’m out of the loop; is the mirror actually still needed or
is there an official repo now?



signature.asc
Description: PGP signature
___
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] page break

2020-02-09 Thread Fabrice Couvreur
Hi,
Sorry if my minimal example is not, but I have to understand with your help
what is wrong. For example, why a page break after the second item when
there seems to be enough space to stay on this page ?
Thanks
Fabrice

\define\starttikzpicture
 {\hbox\bgroup\forcecolorhack\tikzpicture}

\define\stoptikzpicture
{\endtikzpicture\egroup}

\define[2]\CScript{\start\switchtobodyfont[xitsbidi]\m{{\mathscript{#1}}_{#2}}\stop}


  \usemodule[tikz]
  \usemodule[pgfplots]
  \pgfplotsset{compat=newest}

  \unexpanded\def\R{\math{\mathbb{R}}\autoinsertnextspace}
  \unexpanded\def\intervalff#1#2{\math{\left[#1\nonscript\,;#2\right]}}
  \unexpanded\def\point#1#2#3{\math{#1\left(#2\,;#3\right)}}

  \switchtobodyfont[pagella,11pt]

 \definefloat
[recipe]
[figure]

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

  \setuppagenumbering
   [alternative=,
location=]

  \starttext

   \startitemize[n]
\startitem
   {\it Pour tout événement \m{E}, on note \m{\overline{E}}
l'évènement contraire de \m{E}.}
  \blank
  On considère l'arbre pondéré suivant :
  \startlinecorrection[blank]
\startmidaligned
   \starttikzpicture
[level 1/.style={level distance=40mm,sibling distance=25mm,very
thick},
 level 2/.style={level distance=35mm,sibling distance=20mm,very
thick}]
\node{}[grow=right]
  child {node{\m{\overline{R}}}
child{node{\m{\overline{S}}}edge from parent
node[below=2pt]{0,8}}
child{node{\m{S}}edge from parent node[above=2pt]{0,2}
} edge from parent node[below=2pt]{0,3}}
  child {node{\m{R}}
child{node{\m{\overline{S}}}edge from parent
node[below=2pt]{0,6}}
child{node{\m{S}}edge from parent node[above=2pt]{0,4}}
edge from parent node[above=2pt]{0,7}};
  \stoptikzpicture
\stopmidaligned
  \stoplinecorrection
  {\bi Affirmation 1 : }  La probabilité de \m{\overline{R}}
sachant \m{S} est 0,06.
\stopitem
\blank
\startitem
 Soit \m{f} une fonction dérivable sur l'intervalle
\intervalff{0}{15}. On suppose que sa fonction dérivée, notée \m{f'}, est
continue sur \intervalff{0}{15}. Les variations de \m{f'} sont représentées
dans le tableau ci-dessous.
  \startlinecorrection[blank]
\startmidaligned
  \externalfigure[tab_bacblanc.pdf]
\stopmidaligned
  \stoplinecorrection
  {\bi Affirmation 2 :}  La courbe représentative \CScript{C}{f} de
la fonction \m{f} admet une et une seule tangente parallèle à l'axe des
abscisses.
\stopitem
 \placerecipe{}{
   \hbox{
   \starttikzpicture
 [extended line/.style={shorten >=-#1,shorten <=-#1},
 scale=1, every node/.style={scale=0.8},
 /pgf/declare function={f(\x)=\x^2 +1 - \x^3;},
 /pgf/declare function={g(\x)=-5*\x - 2;}]
   \startaxis
[restrict x to domain=-2:3, xmax=3, xmin=-2,
 restrict y to domain=-3:4, ymax=4, ymin=-3,
 x=0.8cm,
 y=0.8cm,
 axis x line=middle,
 axis y line=middle,
 major tick style=black,
 axis line style = ultra thick,
 tick align=outside,
 tickwidth=0.14cm,
 tick style=thick,
 grid=both,
 xtick={-1,...,2},
 ytick={-2,...,3},
 extra x ticks={-2,3},
 extra x tick label={\null},
 extra y ticks={-3,4},
 extra y tick label={\null},
 extra tick style={tick style={draw=none}},
 xlabel=$x$,ylabel=$y$,
 every axis x label/.style={
 at={(ticklabel* cs:1.01)},anchor=west},
 every axis y label/.style={
 at={(ticklabel* cs:1.01)}, anchor=south},
 samples=2000,
 axis on top=false,
 >=stealth]


 \addplot [very thick,domain=-1.25:2] {g(x)};
 \addplot [darkred,very thick,domain=-1.25:2] {f(x)};

 \node[below left=1pt] at (0,0){\m{0}};
 \node[above right] at (-1,{f(-1)}) {\m{A}};
 \node[above right] at (0,{g(0)}) {\m{B}};
 \node[above right] at (1.2,0.5){\CScript{C}{h}};
 \node[left] at (-0.5,0.5){\m{T}};
 \node[fill=black,circle,scale=0.5] at (-1,{f(-1)}){};
 \node[fill=black,circle,scale=0.5] at (0,{g(0)}){};

   \stopaxis
   \stoptikzpicture
}
  }
 \startitem
 La courbe \CScript{C}{h} représentative d'une fonction \m{h}
définie et dérivable sur \R est représentée ci-contre.
  On a tracé la tangente \m{T} à \CScript{C}{h} au point
\point{A}{-1}{3}.

  \m{T} passe par le point \point{B}{0}{-2}.
  \blank
  {\bi Affirmation 3 : } le nombre 

[NTG-context] Side effects with \startformula \stopformula

2020-02-09 Thread Fabrice Couvreur
Hi,
I composed a large document and I often use \ startformula \ stopformula.
I have the impression that this creates untimely page breaks or white
spaces.
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
___