Re: [NTG-context] upload / some new math stuff

2021-06-11 Thread Mikael Sundqvist
On Thu, Jun 10, 2021 at 11:35 PM Hans Hagen  wrote:
>
> Hi,
>
> I played a bit with these newcomputermodern fonts. They are extended
> versions of latin modern and come in:
>
> - 10pt (serif, sane, mono, math)
> - book (serif, sane, mono, math)
> -  8pt (partial)
>
> I made a typescript for the 10pt regular and book (as I see no reason to
> configure 8pt).  So, assuming that one installs these fonts:
>
> \setupbodyfont[newcomputermodern-book]
> \setupbodyfont[newcomputermodern]
>
> should work ok. The book variant is quite nice. I didn't look into the
> provided math alternates (context supports that but I didn't define them
> for this font ... input from math lovers is welcome).
>
> Now, this font also implements, as cambria does, upright integrals and
> as that has comes on my radar every year when I ponder these integrals I
> decided that it was about tiem to deal with it properly. It is no big
> deal to implement them gropwing (after all one can see them as left
> delimiter) but the main issue are these super and subscripts.
>
> \setupbodyfont[newcomputermodern-book]
> % \setupbodyfont[cambria]
>
> \starttext
>
> \startformula
>  x = \integral^1_2 \mathinner{\vrule height 10mm depth 10mm width 5mm} =
>  x = \integral^1_2 \mathinner{\vrule height 20mm depth 20mm width 5mm} =
>  x = \integral^1_2 \mathinner{\vrule height 30mm depth 30mm width 5mm} =
>  x = \integral^1_2 \mathinner{x} =
>  x = \integral^1_2 x
> \stopformula
>
> \startformula
>  x = \int\Umathadaptsize^1_2 \mathinner{\vrule height 10mm depth
> 10mm width 5mm} =
>  x = \int\Umathadaptsize^1_2 \mathinner{\vrule height 20mm depth
> 20mm width 5mm} =
>  x = \int\Umathadaptsize^1_2 \mathinner{\vrule height 30mm depth
> 30mm width 5mm} =
>  x = \int\Umathadaptsize^1_2 \mathinner{x} =
>  x = \int\Umathadaptsize^1_2 x
> \stopformula
>
> \def\rab{\Umathchar"1"00"007C }
>
> $
>  x = \int\Umathadaptsize^1_2 \mathinner{\vrule height 10mm depth
> 10mm width 5mm} =
>  x = \int\Umathadaptsize^1_2 \mathinner{\vrule height 20mm depth
> 20mm width 5mm} =
>  x = \int\Umathadaptsize^1_2 \mathinner{\vrule height 30mm depth
> 30mm width 5mm} =
>  x = \int\Umathadaptsize^1_2 x =
>  x = \rab\Umathadaptsize^1_2^^1__2 \mathinner{\vrule height 30mm
> depth 30mm width 5mm}
> $
>
> \stoptext
>
> After playing with several solutions (delimiters, fences, radicals etc)
> I just settled for a few line extension to the engine (there was already
> plenty in place in luametatex for that anyway) and it seem to work ok.
>
> This \Umathadaptsize is a bit like the limits related suffixes (and uses
> the same scanner logic). It basically flags an operator as something
> that should grow cf what follows. I can add some fine tuning if needed
> (can also be dealt with at the macro end, as with other mechanisms, but
> this is just a first test of useability).
>
> (I might also extend another mechanism to deal with it but putting
> scripts on top or after is already handles pretty well by regular
> mechanisms, so ...)
>
> Of course only a few fonts provide these upright growing integrals
> (makes me wonder about summation and product).
>
> Concerning the newcm fonts: for some reason the book variants (otf
> files) are about twice as large (in filesize) but what we use (cached)
> is the same size (only bboxes differ) so there is something fishy in the
> otf. I can imagine that at some point we add the 10pt/book ones to the
> standard mkiv distribution and maybe only the subset to the lmtx
> distribution but for now these book ones are too big for that, but it
> all depende on them being used.
>
> Happy testing (hopefully there are no side effects).
>
> Hans
>

Hi!

The book version looks nice, indeed! (I am one of those who still use
the MetaFont version of computer modern (in LaTeX), with some
parameters set so that it becomes less thin. Looks very nice when
printed. I guess this book version will also look better, and replace
the MetaFont setup!)

Is there an option available to always get upright integrals?

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


Re: [NTG-context] upload / some new math stuff

2021-06-11 Thread Fabrice Couvreur
Hi Hans,
I am not a font specialist and I use pagella and modern.
I'm curious so I installed this new font in
/home/viserion/LMTX/tex/texmf/fonts/opentype/public/newcomputermodern
I tested your file and I get the following message
Thank you Fabrice

Running `lmtx' on `hans-33' with
``/home/viserion/LMTX/tex/texmf-linux-64/bin/mtxrun --autogenerate --script
context --autopdf --purgeall hans-33''

resolvers   | formats | executing runner 'run luametatex format':
/home/viserion/LMTX/tex/texmf-linux-64/bin/luametatex --jobname="hans-33"
--fmt=/home/viserion/LMTX/tex/texmf-cache/luatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e/formats/luametatex/cont-en.fmt
--lua=/home/viserion/LMTX/tex/texmf-cache/luatex-cache/context/5fe67e0bfe781ce0dde776fb1556f32e/formats/luametatex/cont-en.lui
 --c:autopdf --c:currentrun=1 --c:fulljobname="./hans-33"
--c:input="./hans-33" --c:kindofrun=1 --c:maxnofruns=9 --c:purgeall
--c:texmfbinpath="/home/viserion/LMTX/tex/texmf-linux-64/bin"
fonts   > beware: no fonts are loaded yet, using 'lm mono' in box
system  >
system  > ConTeXt  ver: 2021.06.10 23:13 LMTX  fmt: 2021.6.11  int:
english/english
system  >
system  > 'cont-new.mkxl' loaded
open source > level 1, order 1, name
'/home/viserion/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/viserion/LMTX/tex/texmf-context/tex/context/base/mkxl/cont-new.mkxl'
system  > files > jobname 'hans-33', input './hans-33', result
'hans-33'
fonts   > latin modern fonts are not preloaded
languages   > language 'en' is active
open source > level 1, order 2, name './hans-33.tex'
open source > level 2, order 3, name
'/home/viserion/LMTX/tex/texmf-context/tex/context/fonts/mkiv/type-imp-newcomputermodern.mkiv'
close source> level 2, order 3, name
'/home/viserion/LMTX/tex/texmf-context/tex/context/fonts/mkiv/type-imp-newcomputermodern.mkiv'
fonts   > defining > forced type 'otf' of 'newcm10-regular' not
found
fonts   > defining > unable to define 'newcm10-regular.otf' as
'newcomputermodern-12pt-rm-tf-0--0'
fonts   > defining > font with asked name 'newcmmath-regular' is
not found using lookup 'file'
fonts   > defining > unable to define 'newcmmath-regular' as
'newcomputermodern-12pt-mm-mr--3'
fonts   > defining > unable to define 'newcmmath-regular' as
'newcomputermodern-12pt-mm-mr--2'
fonts   > defining > unable to define 'newcmmath-regular' as
'newcomputermodern-12pt-mm-mr--1'
fonts   > defining > unable to define 'newcmmath-regular' as
'newcomputermodern-12pt-mm-mb--3'
fonts   > defining > unable to define 'newcmmath-regular' as
'newcomputermodern-12pt-mm-mb--2'
fonts   > defining > unable to define 'newcmmath-regular' as
'newcomputermodern-12pt-mm-mb--1'
tex error   > tex error on line 12 in file ./hans-33.tex: Math error:
parameter 'quad' in style 0 is not set

 \p_distance \endgroup \stopimath

 \p_distance \stopforceddisplaymath
\egroup \d_strc_math_number_width \wd \b_strc_formulas_number \ifcase
\mathnumberstatus \setfalse \c_strc_math_has_number \or \ifzeropt
\d_strc_math_number_width \setfalse \c_strc_math_has_number \else \settrue
\c_strc_math_has
 \p_distance \endgroup \ifcase \c_strc_formulas_mode
\Ucheckedstopdisplaymath \or \normalUstopmath \egroup
\strc_formulas_flush_content_and_number \else \expandafter \stopinnermath
\fi
\afterdisplayspace \egroup

 \p_distance \strc_formulas_place_number \strc_formulas_flush_number
\dostarttagged \t!formulacontent \empty \dotagregisterformula
\c_strc_formulas_n \csname \e!stop \formulaparameter \c!alternative
\v!formula \endcsname
\dostoptagged \dostoptagged \nonoindentati

 \stopformula

 2 % \setupbodyfont[cambria]
 3
 4 \starttext
 5
 6 \startformula
 7  x = \integral^1_2 \mathinner{\vrule height 10mm depth 10mm
width 5mm} =
 8  x = \integral^1_2 \mathinner{\vrule height 20mm depth 20mm
width 5mm} =
 9  x = \integral^1_2 \mathinner{\vrule height 30mm depth 30mm
width 5mm} =
10  x = \integral^1_2 \mathinner{x} =
11  x = \integral^1_2 x
12 >>  \stopformula
13
14 \startformula
15  x = \int\Umathadaptsize^1_2 \mathinner{\vrule height 10mm depth
16 10mm width 5mm} =
17  x = \int\Umathadaptsize^1_2 \mathinner{\vrule height 20mm depth
18 20mm width 5mm} =
19  x = \int\Umathadaptsize^1_2 \mathinner{\vrule height 30mm depth
20 30mm width 5mm} =
21  x = \int\Umathadaptsize^1_2 \mathinner{x} =
22  x = \int\Umathadaptsize^1_2 x
Sorry, but I can't typeset math unless various parameters have been set.
This is
normally done by loading special math fonts into the math family slots.
Your font
set is lacking at least the parameter mentioned earlier.
mtx-context | fatal error: return code: 256

Le ven. 11 juin 202

Re: [NTG-context] upload / some new math stuff

2021-06-11 Thread Hans Hagen

On 6/11/2021 12:23 PM, Fabrice Couvreur wrote:

Hi Hans,
I am not a font specialist and I use pagella and modern.
I'm curious so I installed this new font 
in/home/viserion/LMTX/tex/texmf/fonts/opentype/public/newcomputermodern

I tested your file and I get the following message

fonts           > defining > unable to define 'newcm10-regular.otf' as 
'newcomputermodern-12pt-rm-tf-0--0'
fonts           > defining > font with asked name 'newcmmath-regular' is 
not found using lookup 'file'

you forgot to:

mtxrun --generate


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


Re: [NTG-context] upload / some new math stuff

2021-06-11 Thread Alan Braslau
On Thu, 10 Jun 2021 23:35:14 +0200
Hans Hagen  wrote:

> So, assuming that one installs these fonts:

It looks modern (and new). Why not include it in the lmtx distribution?

Alan
___
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] upload / some new math stuff

2021-06-11 Thread Hans Hagen

On 6/11/2021 3:22 PM, Alan Braslau wrote:

On Thu, 10 Jun 2021 23:35:14 +0200
Hans Hagen  wrote:


So, assuming that one installs these fonts:


It looks modern (and new). Why not include it in the lmtx distribution?
Indeed it looks ok. (Years ago I had a talk at bachotex showing slightly 
boldened modern so it is already possible in context with the normal lm 
fonts .. it's how we do full-bold math).


I might but wonder why the book files are so large (it would add 
significant to the currently small lmtx distribution so maybe wait till 
a next version .. i'd not include the 8 pt anyway).


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
___


Re: [NTG-context] upload / some new math stuff

2021-06-11 Thread Pablo Rodriguez
On 6/10/21 11:35 PM, Hans Hagen wrote:
> [...]
> I made a typescript for the 10pt regular and book (as I see no reason to
> configure 8pt).  So, assuming that one installs these fonts:
>
> \setupbodyfont[newcomputermodern-book]
> \setupbodyfont[newcomputermodern]
> [...]
> Happy testing (hopefully there are no side effects).

Many thanks for the new latest, Hans.

The following sample shows an issue with "newcmmono10-bolditalic.otf":

  \mainlanguage[agr]
  \definefontfamily[another][rm][Another]
[tf=file:newcmmono10-boldoblique.otf]
  \setupbodyfont[newcomputermodern]
  \starttext
  \tt\bi\input aristotle-grc\par
  \switchtobodyfont[another]
  \input aristotle-grc\par
  \it\input aristotle-grc
  \stoptext

I’m afraid that there is no "newcmmono10-bolditalic.otf", but
"newcmmono10-boldoblique.otf".

The following patch fixes the issue:

---
context/tex/texmf-context/tex/context/fonts/mkiv/type-imp-newcomputermodern.mkiv
2021-06-11 16:58:53.742990586 +0200
+++ type-imp-newcomputermodern.mkiv 2021-06-11 16:51:57.861274985 +0200
@@ -46,7 +46,7 @@
 \definefontsynonym [\s!MonoItalic]
[\s!file:newcmmono10-italic.otf]
[\s!features=\s!none,\s!fallbacks=\s!MonoItalic]
-\definefontsynonym [\s!MonoBoldItalic]
[\s!file:newcmmono10-bolditalic.otf]
[\s!features=\s!none,\s!fallbacks=\s!MonoBoldItalic]
+\definefontsynonym [\s!MonoBoldItalic]
[\s!file:newcmmono10-boldoblique.otf]
[\s!features=\s!none,\s!fallbacks=\s!MonoBoldItalic]
 \stoptypescript

 \starttypescript [\s!math][newcomputermodern] [\s!name]
@@ -76,7 +76,7 @@
 \definefontsynonym [\s!MonoItalic]
[\s!file:newcmmono10-bookitalic.otf]
[\s!features=\s!none,\s!fallbacks=\s!MonoItalic]
-\definefontsynonym [\s!MonoBoldItalic]
[\s!file:newcmmono10-bolditalic.otf]
[\s!features=\s!none,\s!fallbacks=\s!MonoBoldItalic]
+\definefontsynonym [\s!MonoBoldItalic]
[\s!file:newcmmono10-boldoblique.otf]
[\s!features=\s!none,\s!fallbacks=\s!MonoBoldItalic]
 \stoptypescript

 \starttypescript [\s!math][newcomputermodern-book] [\s!name]

Many thanks for your excellent work with ConTeXt,

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
___


[NTG-context] new upload / math

2021-06-11 Thread Hans Hagen

Hi,

In addition the the mentioned integral trickery we can now do this

\setupbodyfont[newcomputermodern-book]

\enableexperiments[math.extensibles]

\starttext

% \startformula
% x = \integral^1_2 \mathinner{\vrule height 10mm depth 10mm width 
5mm} =
% x = \integral^1_2 \mathinner{\vrule height 20mm depth 20mm width 
5mm} =
% x = \integral^1_2 \mathinner{\vrule height 30mm depth 30mm width 
5mm} =

% x = \integral^1_2 \mathinner{x} =
% x = \integral^1_2 x
% \stopformula

% \startformula
% x = \int\Umathadapttoright^1_2 \mathinner{\vrule height 10mm depth 
10mm width 5mm} =
% x = \int\Umathadapttoright^1_2 \mathinner{\vrule height 20mm depth 
20mm width 5mm} =
% x = \int\Umathadapttoright^1_2 \mathinner{\vrule height 30mm depth 
30mm width 5mm} =

% x = \int\Umathadapttoright^1_2 \mathinner{x} =
% x = \int\Umathadapttoright^1_2 x
% \stopformula

% $
% x = \int\Umathadapttoright^1_2 \mathinner{\vrule height 10mm depth 
10mm width 5mm} =
% x = \int\Umathadapttoright^1_2 \mathinner{\vrule height 20mm depth 
20mm width 5mm} =
% x = \int\Umathadapttoright^1_2 \mathinner{\vrule height 30mm depth 
30mm width 5mm} =

% x = \int\Umathadapttoright^1_2 x =
% $

\def\rab{\Umathchar"1"00"007C }

\startTEXpage[offset=3cm]
  $
\color[green]{\rab\Umathadapttoright^{\black 1}_{\black 2}^^3__4}
\color[blue] {\mathinner{\vrule height 30mm depth 30mm width 5mm}}
\color[red]  {\rab\Umathadapttoleft ^5_6^^{\black 7}__{\black 8}}
  $
\stopTEXpage

\startTEXpage[offset=10pt] % \showglyphs
$
\rab\Umathadapttoright^1_2^^3__4
\mathinner{\vrule height 30mm depth 30mm width 5mm}
\rab\Umathadapttoleft^5_6^^7__8
$
\stopTEXpage

\stoptext

So, we can have left and right sided adaptation. The

\enableexperiments[math.extensibles]

is a cheat that makes the extensible into one character (cut and paste 
related).


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] Call for papers: CG journal 2020

2021-06-11 Thread Henning Hraban Ramm
Hi, do you remember our ConTeXt meeting 2020 in Sibřina? (programme attached)

There were some interesting talks and presentations that should get preserved 
in our current journal (to be distributed at the meeting in Bassenge this fall).

Also, additional articles are always welcome – there were a lot of interesting 
new features and solutions since then.

So far, I/we got only one(!) article, by Taco on MetaPost.


Please don’t let me/us down and hand in your articles until end of July (but 
ASAP)!

@Harald: Please send the latest version of your German report, too! I’ll 
translate it into ConTeXt.


Thank you – I’m looking forward to another interesting issue of CG journal!

Yours, Hraban



pr2020.pdf
Description: Adobe PDF document
___
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 / math

2021-06-11 Thread Pablo Rodriguez
On 6/11/21 6:08 PM, Hans Hagen wrote:
> Hi,
>
> In addition the the mentioned integral trickery we can now do this
>
> \setupbodyfont[newcomputermodern-book]

Hi Hans,

many thanks for the new upload.

I’m afraid that now slanted for New Computer Modern Mono doesn’t work:

  \mainlanguage[agr]
  \setupbodyfont[newcomputermodern]
  \starttext
  {\tt\bi\input aristotle-grc\par}
  \tt\it\input aristotle-grc\par
  \stoptext

"newcmmono10-oblique.otf" is actually "newcmmono10-italic.otf". Naming
isn’t consistent in those fonts (italic and bold oblique, I’m afraid).

Many thanks for your 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
___