Re: [NTG-context] Placing extra bookmarks?

2020-12-02 Thread Bruce Horrocks


> On 2 Dec 2020, at 18:42, Hans Hagen  wrote:
> 
> On 12/2/2020 12:10 AM, Bruce Horrocks wrote:
>> On 1 Dec 2020, at 16:37, Henning Hraban Ramm  wrote:
>>> 
 Am 01.12.2020 um 15:36 schrieb Bruce Horrocks :
 
 I have \placebookmarks[chapter] in my doc and all is fine except that I'd 
 like to force an extra bookmark at the top of the list that jumps to the 
 cover page. However there is no chapter title, or other built in style on 
 the cover.
 
 I tried inserting \bookmark[chapter]{The Cover} but nothing happened - no 
 error, no bookmark.
 
 Any suggestions please? There's no need to bookmark to a specific point - 
 just going to page 1 would be enough.
>>> 
>>> Did you enable interactions? \setupinteractions[state=start]
>>> 
>>> But when I recently tried to manually set some bookmarks instead of visible 
>>> chapter titles, I also didn’t get any; didn’t investigate further yet.
> there are some examples in the test suite (sections/bookmarks-*.tex)
> 
> You can specify bookmarks when you use \startsection etc an dalso add them 
> any place to named lists.

Thanks Hans - I never thought to look in the test cases (d'oh!).

For the benefit of those searching the archives in the future, here is an MWE 
adapted from one of the test cases that places one bookmark via a chapter 
heading and one manually that is not linked to any document section.

\enabletrackers[references.bookmarks,backend.resources] % For debug only

\setupinteraction
  [state=start]

\setupinteractionscreen
  [option=bookmark]

\definelist
  [mylist]
  
\placebookmarks[chapter,mylist]

\starttext
\input zapf
\bookmark[mylist]{Bookmark not linked to a section heading}
\input zapf

\page[yes]
\startchapter[title=Tufte]
\input tufte
\stopchapter
\stoptext

I shall add it to the Wiki.
--
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 / 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 do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread T. Kurt Bond
Oh, so it does.  That doesn't look good.

On Wed, Dec 2, 2020 at 2:21 PM Rik Kabel 
wrote:

>
> On 12/2/2020 13:59, T. Kurt Bond wrote:
>
> Interesting.
>
> Here is a an example that sort of works, Variant 1:
>
> \definefontfamily[english] [rm] [ebgaramond] [features={default, dlig=no}]
> \setupbodyfont[english,10pt]
> \starttext
>
> Variant 1:
> Does this look like EBGaramond?
>
> fi fl ffi ffl ct st
> \stoptext
>
>
> However, it turns of *all* the ligatures.
>
> Here is an example that works as expected, Variant 2:
>
> \definefontfeature[english][dlig=no]
> \definefontfamily[ebgaramond] [rm] [EB Garamond]
>  [features={default,english}]
> \setupbodyfont[ebgaramond,10pt]
>
> \starttext
>
> Variant 2:
> Does this look like EBGaramond?
>
> fi fl ffi ffl ct st
> \stoptext
>
>
> It turns off just the ct and st ligatures.
>
> I've attached the generated PDF files for both variants.
>
>
> No, it turns off other ligatures as well, so is not a generally workable
> solution. (Try *fj* and *ſi*, for two examples.)
>
> --
> Rik
>
> ___
> 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
>
> ___
>


-- 
T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io
___
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 do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread Rik Kabel


On 12/2/2020 13:34, Hans Hagen wrote:

On 12/2/2020 5:54 PM, Joey McCollum wrote:
If you're using Octavio Pardo's version of EB Garamond 
(https://github.com/octaviopardo/EBGaramond12 
), then these ligatures 
are covered (along with the Th ligature) by the "dlig" (discretionary 
ligatures) feature, so you'll need to disable that. Unfortunately, 
this will also disable the Th ligature. This is a known, open issue 
for the font: https://github.com/octaviopardo/EBGaramond12/issues/20 
.

One of these examples where opensource fails ...

https://github.com/octaviopardo/EBGaramond12
https://github.com/georgd/EB-Garamond

A while ago I replaced AB on my machine in oirdert to test some issue 
so now I have to replace it again? Which one is the real one? Which 
one is the original? Which one are we supposed to support / configure?


\definefontfeature[whatever][default][rlig=yes]
% \definefontfeature[whatever][default][rlig=yes,dlig=yes] % those st 
and ct ligs


\definefontfamily [english] [rm] [EB Garamond] [features=whatever]
\definefontfamily [english] [mm] [Stix Two Math]

\setupbodyfont[english]

\starttext
    fi fl ffi ffl ct st
\stoptext

Using the ones pointed from google fonts.

Hans


Hello all,

I am the one who posted issue #20 for the font back in January 2018. The 
report simply states that there is no way to get dlig without also 
getting hlig, and includes an easily reproducible demonstration (using 
LibreOffice on the assumption that it is more accessible for testing). 
Since then, there has been a PR submitted. Crickets. No action.


As to which version of the font should be used, Georg Duffner 
transferred stewardship of the font to Octavio Pardo in 2017 or so. 
Pardo added support for faces beyond roman and italic (bold, semibold, 
extrabold). Some work was done a couple of years ago to support variable 
fonts, but nothing that can be used has yet come out of that effort. To 
a casual observer, the development and maintenance appears to be 
abandoned. I am sure that many would be happy to see work on this font 
resume, but projects like this are difficult to take over and support is 
thin.


So, if you can find that satisfies your requirements as it is, use it. 
The Duffner versions (pre-Pardo) do not have this particular issue, and 
if you do not need emboldened faces or other updates Pardo may have 
implemented, that should work. Or look elsewhere. Although the range and 
licensing of EB Garamond was certainly attractive, there are plenty of 
Garamonds in the world.


--
Rik

___
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 do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread Rik Kabel


On 12/2/2020 13:59, T. Kurt Bond wrote:

Interesting.

Here is a an example that sort of works, Variant 1:

\definefontfamily[english] [rm] [ebgaramond] [features={default,
dlig=no}]
\setupbodyfont[english,10pt]
\starttext

Variant 1:
Does this look like EBGaramond?

fi fl ffi ffl ct st
\stoptext


However, it turns of *all* the ligatures.

Here is an example that works as expected, Variant 2:

\definefontfeature[english][dlig=no]
\definefontfamily[ebgaramond] [rm] [EB Garamond]
 [features={default,english}]
\setupbodyfont[ebgaramond,10pt]

\starttext

Variant 2:
Does this look like EBGaramond?

fi fl ffi ffl ct st
\stoptext


It turns off just the ct and st ligatures.

I've attached the generated PDF files for both variants.


No, it turns off other ligatures as well, so is not a generally workable 
solution. (Try *fj* and *ſi*, for two examples.)


--
Rik

___
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] ntg-context Digest, Vol 198, Issue 8

2020-12-02 Thread Wolfgang Schuster

Andres Conrado Montoya schrieb am 02.12.2020 um 20:05:
You are naming your font "english". If you call "ebgaramond" it will 
always take the default ebgaramond features. Just call your font with 
the name you gave it.


\definefontfamily[english] [rm] [ebgaramond] [features={dlig=no}]


Pass only named features sets (create with \definefontfeature) as 
argument to the features key.


Even though "dlig=no" works at the moment this is not officially 
supported and can disappear in the future.


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
___


Re: [NTG-context] ntg-context Digest, Vol 198, Issue 8

2020-12-02 Thread Andres Conrado Montoya
You are naming your font "english". If you call "ebgaramond" it will always
take the default ebgaramond features. Just call your font with the name you
gave it.

\definefontfamily[english] [rm] [ebgaramond] [features={dlig=no}]
\setupbodyfont[english,10pt]
\starttext
ct st
\stoptext



-- 
Andrés Conrado Montoya
Andi Kú
andresconr...@gmail.com
http://sesentaycuatro.com
http://messier87.com
http://chiquitico.org

Los fines no justifican los medios, porque la medida verdadera de nuestro
carácter está dada por los medios que estamos dispuestos a utilizar, no por
los fines que proclamamos.


“You develop an instant global consciousness, a people orientation, an
intense dissatisfaction with the state of the world, and a compulsion to do
something about it. From out there on the moon, international politics look
so petty. You want to grab a politician by the scruff of the neck and drag
him a quarter of a million miles out and say, ‘Look at that, you son of a
bitch.’” — Apollo 14 astronaut Edgar Mitchell
___
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 do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread T. Kurt Bond
I agree, this solution does seem cleaner to me.  Thanks!

On Wed, Dec 2, 2020 at 1:23 PM Pablo Rodriguez  wrote:

> On 12/2/20 6:56 PM, T. Kurt Bond wrote:
> > Ah, ok.
> >
> > Here is a minimal NONWORKING example: the resulting PDF shows the ct and
> > st ligatures.  What commands should I use to turn them off?
>
> Hi Kurt,
>
> here you have the sample that should work:
>
>   %~ \definefontfamily[ebgaramond] [rm] [ebgaramond]
>
> %~ [features={default,dlig=no}]
>
>   \definefontfeature[english][dlig=no]
>
>   \definefontfamily[ebgaramond] [rm] [EB Garamond]
>
> [features={default,english}]
>
>   \setupbodyfont[ebgaramond,10pt]
>
>   \starttext
>
>   ct st
>
>   \stoptext
>
> BTW, on my system the default doesn’t get discretionary ligatures.
>
> Your sample didn’t work because the identifier for \definefontfamily
> (english) was different from the one used in \setupbodyfont. (If they
> don’t match, it cannot work.)
>
> Another cleaner approach is to define font features to invoke them in
> \definefontfamily. This method seems cleaner to me.
>
> 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
>
> ___
>


-- 
T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io
___
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 do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread T. Kurt Bond
Interesting.

Here is a an example that sort of works, Variant 1:

\definefontfamily[english] [rm] [ebgaramond] [features={default, dlig=no}]
\setupbodyfont[english,10pt]
\starttext

Variant 1:
Does this look like EBGaramond?

fi fl ffi ffl ct st
\stoptext


However, it turns of *all* the ligatures.

Here is an example that works as expected, Variant 2:

\definefontfeature[english][dlig=no]
\definefontfamily[ebgaramond] [rm] [EB Garamond]
 [features={default,english}]
\setupbodyfont[ebgaramond,10pt]

\starttext

Variant 2:
Does this look like EBGaramond?

fi fl ffi ffl ct st
\stoptext


It turns off just the ct and st ligatures.

I've attached the generated PDF files for both variants.


On Wed, Dec 2, 2020 at 1:23 PM Pablo Rodriguez  wrote:

> On 12/2/20 6:56 PM, T. Kurt Bond wrote:
> > Ah, ok.
> >
> > Here is a minimal NONWORKING example: the resulting PDF shows the ct and
> > st ligatures.  What commands should I use to turn them off?
>
> Hi Kurt,
>
> here you have the sample that should work:
>
>   %~ \definefontfamily[ebgaramond] [rm] [ebgaramond]
>
> %~ [features={default,dlig=no}]
>
>   \definefontfeature[english][dlig=no]
>
>   \definefontfamily[ebgaramond] [rm] [EB Garamond]
>
> [features={default,english}]
>
>   \setupbodyfont[ebgaramond,10pt]
>
>   \starttext
>
>   ct st
>
>   \stoptext
>
> BTW, on my system the default doesn’t get discretionary ligatures.
>
> Your sample didn’t work because the identifier for \definefontfamily
> (english) was different from the one used in \setupbodyfont. (If they
> don’t match, it cannot work.)
>
> Another cleaner approach is to define font features to invoke them in
> \definefontfamily. This method seems cleaner to me.
>
> 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
>
> ___
>


-- 
T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io


ebgaramond-lig.pdf
Description: Adobe PDF document


ebgaramond-lig-variant-2.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] Placing extra bookmarks?

2020-12-02 Thread Hans Hagen

On 12/2/2020 12:10 AM, Bruce Horrocks wrote:

On 1 Dec 2020, at 16:37, Henning Hraban Ramm  wrote:



Am 01.12.2020 um 15:36 schrieb Bruce Horrocks :

I have \placebookmarks[chapter] in my doc and all is fine except that I'd like 
to force an extra bookmark at the top of the list that jumps to the cover page. 
However there is no chapter title, or other built in style on the cover.

I tried inserting \bookmark[chapter]{The Cover} but nothing happened - no 
error, no bookmark.

Any suggestions please? There's no need to bookmark to a specific point - just 
going to page 1 would be enough.


Did you enable interactions? \setupinteractions[state=start]

But when I recently tried to manually set some bookmarks instead of visible 
chapter titles, I also didn’t get any; didn’t investigate further yet.

there are some examples in the test suite (sections/bookmarks-*.tex)

You can specify bookmarks when you use \startsection etc an dalso add 
them any place to named lists.


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] How do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread Hans Hagen

On 12/2/2020 5:54 PM, Joey McCollum wrote:
If you're using Octavio Pardo's version of EB Garamond 
(https://github.com/octaviopardo/EBGaramond12 
), then these ligatures 
are covered (along with the Th ligature) by the "dlig" (discretionary 
ligatures) feature, so you'll need to disable that. Unfortunately, this 
will also disable the Th ligature. This is a known, open issue for the 
font: https://github.com/octaviopardo/EBGaramond12/issues/20 
.

One of these examples where opensource fails ...

https://github.com/octaviopardo/EBGaramond12
https://github.com/georgd/EB-Garamond

A while ago I replaced AB on my machine in oirdert to test some issue so 
now I have to replace it again? Which one is the real one? Which one is 
the original? Which one are we supposed to support / configure?


\definefontfeature[whatever][default][rlig=yes]
% \definefontfeature[whatever][default][rlig=yes,dlig=yes] % those st 
and ct ligs


\definefontfamily [english] [rm] [EB Garamond]   [features=whatever]
\definefontfamily [english] [mm] [Stix Two Math]

\setupbodyfont[english]

\starttext
fi fl ffi ffl ct st
\stoptext

Using the ones pointed from google fonts.

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] How do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread T. Kurt Bond
That did the trick, thanks!

Should I put that on the wiki?  Where should it go?

On Wed, Dec 2, 2020 at 1:07 PM Joey McCollum 
wrote:

> You'll need to use the alias for the font family, as follows:
>
> \definefontfamily[english] [rm] [ebgaramond] [features={default, hlig=no}]
>
> \setupbodyfont[english,10pt]
>
> \starttext
>
> ct st
>
> \stoptext
>
> On Wed, Dec 2, 2020 at 12:56 PM T. Kurt Bond  wrote:
>
>> Ah, ok.
>>
>> Here is a minimal NONWORKING example: the resulting PDF shows the ct and
>> st ligatures.  What commands should I use to turn them off?
>>
>> \definefontfamily[english] [rm] [ebgaramond] [features={default,dlig=no}]
>> \setupbodyfont[ebgaramond,10pt]
>> \starttext
>> ct st
>> \stoptext
>>
>>
>> On Wed, Dec 2, 2020 at 12:35 PM Hans Hagen  wrote:
>>
>>> On 12/2/2020 6:14 PM, T. Kurt Bond wrote:
>>> > It does help.  Thanks.
>>> >
>>> > But how do I turn that font feature off in ConTeXt?
>>> You forget to add a MWE ...
>>>
>>> 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
>>> -
>>>
>>
>>
>> --
>> T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io
>>
>> ___
>> 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
>
> ___
>


-- 
T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io
___
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 do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread Pablo Rodriguez
On 12/2/20 6:56 PM, T. Kurt Bond wrote:
> Ah, ok.
>
> Here is a minimal NONWORKING example: the resulting PDF shows the ct and
> st ligatures.  What commands should I use to turn them off?

Hi Kurt,

here you have the sample that should work:

  %~ \definefontfamily[ebgaramond] [rm] [ebgaramond]

%~ [features={default,dlig=no}]

  \definefontfeature[english][dlig=no]

  \definefontfamily[ebgaramond] [rm] [EB Garamond]

[features={default,english}]

  \setupbodyfont[ebgaramond,10pt]

  \starttext

  ct st

  \stoptext

BTW, on my system the default doesn’t get discretionary ligatures.

Your sample didn’t work because the identifier for \definefontfamily
(english) was different from the one used in \setupbodyfont. (If they
don’t match, it cannot work.)

Another cleaner approach is to define font features to invoke them in
\definefontfamily. This method seems cleaner to me.

I hope it helps,

Pablo
--
http://www.ousia.tk
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

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


Re: [NTG-context] How do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread Wolfgang Schuster

T. Kurt Bond schrieb am 02.12.2020 um 18:56:

Ah, ok.

Here is a minimal NONWORKING example: the resulting PDF shows the ct and 
st ligatures.  What commands should I use to turn them off?


\definefontfamily[english] [rm] [ebgaramond] [features={default,dlig=no}]
\setupbodyfont[ebgaramond,10pt]
\starttext
ct st
\stoptext


\definefontfamily [english] [rm] [EB Garamond]
\definefontfamily [english] [mm] [Stix Two Math]

\setupbodyfont[english]

\starttext
fi fl ffi ffl ct st
\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
___


Re: [NTG-context] How do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread Joey McCollum
Sorry, there was a typo. Use this:

\definefontfamily[english] [rm] [ebgaramond] [features={default, dlig=no}]

\setupbodyfont[english,10pt]

\starttext

ct st

\stoptext

On Wed, Dec 2, 2020 at 1:05 PM Joey McCollum 
wrote:

> You'll need to use the alias for the font family, as follows:
>
> \definefontfamily[english] [rm] [ebgaramond] [features={default, hlig=no}]
>
> \setupbodyfont[english,10pt]
>
> \starttext
>
> ct st
>
> \stoptext
>
> On Wed, Dec 2, 2020 at 12:56 PM T. Kurt Bond  wrote:
>
>> Ah, ok.
>>
>> Here is a minimal NONWORKING example: the resulting PDF shows the ct and
>> st ligatures.  What commands should I use to turn them off?
>>
>> \definefontfamily[english] [rm] [ebgaramond] [features={default,dlig=no}]
>> \setupbodyfont[ebgaramond,10pt]
>> \starttext
>> ct st
>> \stoptext
>>
>>
>> On Wed, Dec 2, 2020 at 12:35 PM Hans Hagen  wrote:
>>
>>> On 12/2/2020 6:14 PM, T. Kurt Bond wrote:
>>> > It does help.  Thanks.
>>> >
>>> > But how do I turn that font feature off in ConTeXt?
>>> You forget to add a MWE ...
>>>
>>> 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
>>> -
>>>
>>
>>
>> --
>> T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io
>>
>> ___
>> 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 do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread Joey McCollum
You'll need to use the alias for the font family, as follows:

\definefontfamily[english] [rm] [ebgaramond] [features={default, hlig=no}]

\setupbodyfont[english,10pt]

\starttext

ct st

\stoptext

On Wed, Dec 2, 2020 at 12:56 PM T. Kurt Bond  wrote:

> Ah, ok.
>
> Here is a minimal NONWORKING example: the resulting PDF shows the ct and
> st ligatures.  What commands should I use to turn them off?
>
> \definefontfamily[english] [rm] [ebgaramond] [features={default,dlig=no}]
> \setupbodyfont[ebgaramond,10pt]
> \starttext
> ct st
> \stoptext
>
>
> On Wed, Dec 2, 2020 at 12:35 PM Hans Hagen  wrote:
>
>> On 12/2/2020 6:14 PM, T. Kurt Bond wrote:
>> > It does help.  Thanks.
>> >
>> > But how do I turn that font feature off in ConTeXt?
>> You forget to add a MWE ...
>>
>> 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
>> -
>>
>
>
> --
> T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io
>
> ___
> 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 do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread T. Kurt Bond
Ah, ok.

Here is a minimal NONWORKING example: the resulting PDF shows the ct and st
ligatures.  What commands should I use to turn them off?

\definefontfamily[english] [rm] [ebgaramond] [features={default,dlig=no}]
\setupbodyfont[ebgaramond,10pt]
\starttext
ct st
\stoptext


On Wed, Dec 2, 2020 at 12:35 PM Hans Hagen  wrote:

> On 12/2/2020 6:14 PM, T. Kurt Bond wrote:
> > It does help.  Thanks.
> >
> > But how do I turn that font feature off in ConTeXt?
> You forget to add a MWE ...
>
> 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
> -
>


-- 
T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io
___
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 do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread Hans Hagen

On 12/2/2020 6:14 PM, T. Kurt Bond wrote:

It does help.  Thanks.

But how do I turn that font feature off in ConTeXt?

You forget to add a MWE ...

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] How do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread Joey McCollum
The wiki page on featuresets (https://wiki.contextgarden.net/Featuresets)
offers a more comprehensive treatment.

On Wed, Dec 2, 2020 at 12:29 PM Joey McCollum 
wrote:

> I think it would look something like
>
> \definefontfamily[english] [rm] [EB Garamond] [features={default,dlig=no}]
>
> On Wed, Dec 2, 2020 at 12:14 PM T. Kurt Bond  wrote:
>
>> It does help.  Thanks.
>>
>> But how do I turn that font feature off in ConTeXt?
>>
>> On Wed, Dec 2, 2020 at 11:55 AM Joey McCollum <
>> jmccollum20140...@gmail.com> wrote:
>>
>>> If you're using Octavio Pardo's version of EB Garamond (
>>> https://github.com/octaviopardo/EBGaramond12), then these ligatures are
>>> covered (along with the Th ligature) by the "dlig" (discretionary
>>> ligatures) feature, so you'll need to disable that. Unfortunately, this
>>> will also disable the Th ligature. This is a known, open issue for the
>>> font: https://github.com/octaviopardo/EBGaramond12/issues/20.
>>>
>>> I hope this helps.
>>>
>>> On Wed, Dec 2, 2020 at 11:41 AM T. Kurt Bond 
>>> wrote:
>>>
 Searches didn't reveal the answer.

 --
 T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io

 ___
 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
>>>
>>> ___
>>>
>>
>>
>> --
>> T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io
>>
>> ___
>> 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 do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread Joey McCollum
I think it would look something like

\definefontfamily[english] [rm] [EB Garamond] [features={default,dlig=no}]

On Wed, Dec 2, 2020 at 12:14 PM T. Kurt Bond  wrote:

> It does help.  Thanks.
>
> But how do I turn that font feature off in ConTeXt?
>
> On Wed, Dec 2, 2020 at 11:55 AM Joey McCollum 
> wrote:
>
>> If you're using Octavio Pardo's version of EB Garamond (
>> https://github.com/octaviopardo/EBGaramond12), then these ligatures are
>> covered (along with the Th ligature) by the "dlig" (discretionary
>> ligatures) feature, so you'll need to disable that. Unfortunately, this
>> will also disable the Th ligature. This is a known, open issue for the
>> font: https://github.com/octaviopardo/EBGaramond12/issues/20.
>>
>> I hope this helps.
>>
>> On Wed, Dec 2, 2020 at 11:41 AM T. Kurt Bond  wrote:
>>
>>> Searches didn't reveal the answer.
>>>
>>> --
>>> T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io
>>>
>>> ___
>>> 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
>>
>> ___
>>
>
>
> --
> T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io
>
> ___
> 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 do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread T. Kurt Bond
It does help.  Thanks.

But how do I turn that font feature off in ConTeXt?

On Wed, Dec 2, 2020 at 11:55 AM Joey McCollum 
wrote:

> If you're using Octavio Pardo's version of EB Garamond (
> https://github.com/octaviopardo/EBGaramond12), then these ligatures are
> covered (along with the Th ligature) by the "dlig" (discretionary
> ligatures) feature, so you'll need to disable that. Unfortunately, this
> will also disable the Th ligature. This is a known, open issue for the
> font: https://github.com/octaviopardo/EBGaramond12/issues/20.
>
> I hope this helps.
>
> On Wed, Dec 2, 2020 at 11:41 AM T. Kurt Bond  wrote:
>
>> Searches didn't reveal the answer.
>>
>> --
>> T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io
>>
>> ___
>> 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
>
> ___
>


-- 
T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io
___
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 do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread Joey McCollum
If you're using Octavio Pardo's version of EB Garamond (
https://github.com/octaviopardo/EBGaramond12), then these ligatures are
covered (along with the Th ligature) by the "dlig" (discretionary
ligatures) feature, so you'll need to disable that. Unfortunately, this
will also disable the Th ligature. This is a known, open issue for the
font: https://github.com/octaviopardo/EBGaramond12/issues/20.

I hope this helps.

On Wed, Dec 2, 2020 at 11:41 AM T. Kurt Bond  wrote:

> Searches didn't reveal the answer.
>
> --
> T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io
>
> ___
> 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 do I get rid of the ct and st ligatures in EBGaramond?

2020-12-02 Thread T. Kurt Bond
Searches didn't reveal the answer.

-- 
T. Kurt Bond, tkurtb...@gmail.com, https://tkurtbond.github.io
___
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] Using ConTeXt-LMTX for modern Mathematically-Literate-Programming 2/2

2020-12-02 Thread Hans Hagen

On 12/2/2020 11:43 AM, Stephen Gaito wrote:


Again, to my knowledge, Lua v5.4 has only one implementation (though
this implementation *can* be compiled for a very wide range of CPU's).


Lua has not many demands ... it can even run on tiny cpu's. It's all 
rather plain C code. (And in luametatex we have no c++ ... all is just C.)



Finally, the computational complexity of my proof engine, will be
comparable to MetaFun/MetaPost... which I suspect you would not
consider implementing in pure Lua. Some things are faster in C.


Hard to say ... I think that the parser / expansion machinery in mp is 
the bottleneck here (no fun to do that in lua). Redoing it in Lua also 
is asking for compatibility issues. (btw, extensions are done in lua 
anyway, as is the mp backend)



So yes I do need to implement it in ANSI-C wrapped in Lua (so that it
can be used from *inside* ConTeXt).


I would have to see the 'kind of code involved' in order to comment on 
that.


An option is to do most in lua and maybe some helpers for crititical 
code in C.

 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] Using ConTeXt-LMTX for modern Mathematically-Literate-Programming 1/2

2020-12-02 Thread Hans Hagen

On 12/2/2020 10:40 AM, Stephen Gaito wrote:


Many thanks for your swift and helpful comments.

After some *very crude* tests using the `luametatex` and `luametafun`
documents, I find that while I *can* stop effective processing at
various points in the LuaMetaTeX pipeline, the time difference overall
is not really significant enough to bother with this approach.

The principle problem is, as you suggested below, "stopping" the
pipeline at the PDF stage (using for example the `pre_output_filter`)
corrupted the `*.tuc` data which is for my purposes, critical.

Your comment was:


but keep in mind that multipass data is flushed as part of the
shipout (because it is often location and order bound)


For the record, using the `append_to_vlist_filter` callback, I did
manage to drastically reduce the "pages" (which were all blank, not
surprisingly).

However, on my elderly desktop from 2008, both callbacks essentially cut
only 6-8 seconds out of 18 seconds, for the `luametatex` document, and
190 seconds, for the `luametafun` document.


hm, on my 2013 laptop the luametatex manual needs 10 sec (i have all the 
fonts, so that includes a bunch) and a metafun manual should do about 20


a test on am M1 mini needs half those times as reported yesterday

i bet that on a modern desktop the luatex manual will do < 5 sec


In the case of the `luametafun` document, it is the MetaFun/MetaPost
processing which, of course, is taking a long time (as it should, the
graphics computations represent important but complex computations).


One run or many due to xref? Maybe your machine has no significant cpu 
cache? Do you run from disk or ssd? How much memory?



My ultimate goal is to parallelize the production of large, heavily
cross-referenced, ConTeXt documents... more on this in a future email...

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] Using ConTeXt-LMTX for modern Mathematically-Literate-Programming 2/2

2020-12-02 Thread Stephen Gaito
Hans,

Many thanks for your comments... see below.

On Mon, 30 Nov 2020 19:31:55 +0100
Hans Hagen  wrote:

> On 11/30/2020 10:51 AM, Stephen Gaito wrote:
> > Hello (again),
> > 
> > This email is further to my previous "Using ConTeXt-LMTX for modern
> > Mathematically-Literate-Programming 1/2" email...
> > 
> > My ultimate goal in using ConTeXt-LMTX as a
> > Mathematically-Literate-Programming tool, is to actually write a
> > kernel "Mathematical Language" in ANSI-C (wrapped in Lua) which is
> > then imported back into ConTeXt-LMTX as a standard Lua module (with
> > an ANSI-C shared library).
> 
> Just curious: do you think that using c instead of lua for that has 
> advantages?

This is a very good and important question. One I have asked myself
repeatedly.

My ultimate goal is to write a small mathematical kernel in ANSI-C,
which is, using [Frama-C](https://frama-c.com/), proven *correct*.

To my knowledge, Lua has no similar tool for correctness proofs.

Equally importantly, there are a very wide range of very different
compilers which compile ANSI-C for an equally very wide range of CPU's. 

Again, to my knowledge, Lua v5.4 has only one implementation (though
this implementation *can* be compiled for a very wide range of CPU's).

The problem here is that Mathematicians are inherently very
conservative about the concept of "proof" (it has taken well over 2,000
hard years to develop our current understanding). My kernel will be an
extensible "proof" engine. For mathematicians to trust it, this proof
engine must itself be proven correct (or as correct as currently
possible). It must also be simple enough to *see* that it is correct
(hence the Literate-Programming approach), *and* (since I can not even
hope to prove the compilers are *correct*), there must be many
*different* compiler implementations (to show that the results are not
artefacts of one particular implementation).

Finally, the computational complexity of my proof engine, will be
comparable to MetaFun/MetaPost... which I suspect you would not
consider implementing in pure Lua. Some things are faster in C.

So yes I do need to implement it in ANSI-C wrapped in Lua (so that it
can be used from *inside* ConTeXt).

Since this is a mathematical tool, "embedding" it in ConTeXt is ideal.

As a mathematician writes, what they write gets proof-checked
automatically... in the document they are writing, and by the
typesetting tool they are using for the finished PDF. :-)

ConTeXt (via LuaMetaTex) makes this possible in a way native TeX/LaTeX
never could.

So once again, many many thanks for the vision to create such a
flexible tool!

> 
> > This would allow the output of "code" in my "Mathematical Language"
> > to be directly embedded/typeset in the output of my Mathematical
> > document.
> > 
> > (The ultimate goal is to ensure that there is NO wishful thinking
> > that the code is "correct" ("just trust me")... all results would be
> > directly visible in the PDF).
> > 
> > Alas, while, for other reasons, trying to use the Lua-CJSON Lua
> > module from within ConTeXt-LMTX (which also makes use of a shared
> > library written in C), I find that the current ConTeXt-LMTX is
> > missing (among potentially others) the `lua_checkstack` symbol:
> 
> could be .. we dont' use it
> 
> >> ...Xt/tex/texmf-context/tex/context/base/mkiv/l-package.lua:333:
> >> error loading module 'cjson' from file
> >> '/usr/local/lib/lua/5.4/cjson.so':
> >> /usr/local/lib/lua/5.4/cjson.so: undefined symbol: lua_checkstack
> > 
> > even when using the ConTeXt/LuaMetaTeX `--permiteloadlib` switch.
> > 
> > (Note that this Lua-CJSON module does work with the native 5.4 Lua).
> 
> why not use the build in helpers

The test, which triggered the error message (above), was to prove that
I could send [NATS](https://nats.io/) messages from *inside* ConTeXt.

"Out of the box", the [Lua-NATS](https://github.com/DawnAngel/lua-nats)
requires:

- luasocket (which LuaMetaTex provides, many many thanks!)

- lua-cjson (which is an external shared library and is what I was
  testing)

Fortunately, I found a couple of pure Lua JSON tools which I could get
Lua-NATS to use with a one line change. (And, for the record, I *can*
send and receive messages from a NATS server from inside ConTeXt :-)  

If I find I need to make changes to the Lua-NATS code, I will probably
use LuaMetaTeX's internal JSON implementation as you suggest below
(again many thanks for embedding a JSON implementation).

Using Lua-NATS is part of my larger goal to parallelize the typesetting
of large documents using ConTeXt (more on this in another email).

> 
> \usemodule[json]
> 
> \starttext
> 
> \startluacode
>  local l = { a = 1, b = { c = "d" } }
>  inspect(l)
>  local j = utilities.json.tojson(l)
>  inspect(j)
>  local s = utilities.json.tostring(j)
>  inspect(s)
>  io.savedata("temp.json",j)
>  local t = utilities.json.load("temp.json")
>  inspect(t)
> \stopluacode
> 
> \stoptext
> 
> > 

Re: [NTG-context] Using ConTeXt-LMTX for modern Mathematically-Literate-Programming 1/2

2020-12-02 Thread Stephen Gaito
Hans,

Many thanks for your swift and helpful comments.

After some *very crude* tests using the `luametatex` and `luametafun`
documents, I find that while I *can* stop effective processing at
various points in the LuaMetaTeX pipeline, the time difference overall
is not really significant enough to bother with this approach.

The principle problem is, as you suggested below, "stopping" the
pipeline at the PDF stage (using for example the `pre_output_filter`)
corrupted the `*.tuc` data which is for my purposes, critical.

Your comment was: 

> but keep in mind that multipass data is flushed as part of the
> shipout (because it is often location and order bound)

For the record, using the `append_to_vlist_filter` callback, I did
manage to drastically reduce the "pages" (which were all blank, not
surprisingly).

However, on my elderly desktop from 2008, both callbacks essentially cut
only 6-8 seconds out of 18 seconds, for the `luametatex` document, and
190 seconds, for the `luametafun` document.

In the case of the `luametafun` document, it is the MetaFun/MetaPost
processing which, of course, is taking a long time (as it should, the
graphics computations represent important but complex computations).

My ultimate goal is to parallelize the production of large, heavily
cross-referenced, ConTeXt documents... more on this in a future email...

Again, many thanks for your comments!

Regards,

Stephen Gaito

On Mon, 30 Nov 2020 19:59:07 +0100
Hans Hagen  wrote:

> On 11/30/2020 10:51 AM, Stephen Gaito wrote:
> > Hello,
> > 
> > I am slowly working on a Mathematical problem requiring underlying
> > computation.
> > 
> > As Mathematicians (myself included) are rather "conservative", I
> > need to discuss each "chunk" of code with the full set of
> > Mathematical notation.
> > 
> > A couple of years ago I started using ConTeXt-MKIV as a
> > Mathematically-Literate-Programming tool by using its excellent Lua
> > interface to capture the code and dump it to disk for external
> > compilation.
> > 
> > I am now revisiting my original design and want to redo my tools
> > using ConTeXt-LMTX.
> > 
> > I would *like* to be able to "stop" the ConTeXt typesetting at
> > various points for differing purposes:
> > 
> > 1. After all macro expansions (and hence after *my* calls into Lua)
> > but before line/paragraph/page layout begins.
> 
> maybe something
> 
> \startmystuff
> 
> \stopmystuff
> 
> and then you can hook something into startmystuff and \stopmystuff
> 
> > 2. After line/paragraph/page layout but before PDF generation.
> 
> pdf is generated per page, if needed one can kick in a shipout
> overload
> 
> but keep in mind that multipass data is flushed as part of the
> shipout (because it is often location and order bound)
> 
> > 3. After all PDF generated (ie. a "normal" "full" ConTeXt run).
> > 
> > Stopping after all macro expansions would allow my code generation
> > builds to proceed without the un-needed page setting or PDF
> > generation.
> 
> hm, the problem is always in the 'state' of all kind of variables
> 
> > Stopping after the line/paragraph/page layout would allow multiple
> > "faster(?)" ConTeXt runs while the "*.tuc" file converges to a
> > complete set of page numbers and cross references (etc). Then, once
> > the "*.tuc" file has converged, a full ConTeXt run with PDF output
> > could be done.
> 
> not sure what you mean here ... what is fast? or: how slow is it now? 
> what is the bottleneck? can you cache data that didn't change?
> 
> a large document is normally split up in sections that can be
> processed independent
> 
> \starttext
>  \dorecurse{1}{\samplefile{ward}\par}
> \stoptext
> 
> runs on my 2013 laptop at over 65 pages per second
> 
> quite often performance is hit by inefficient styling and such ..
> it's no problem to bring a tex system a grinding halt
> 
> > I am very aware that *internally* ConTeXt is probably structured as
> > a tight pipeline with each of the "traditional" TeX stages "Mouth",
> > "Stomach", "page setting", PDF generation tightly "chained"...
> > This means that there is no "one" place in the code where all macro
> > expansions have completed but before the page setting "starts", or
> > similarly, after the page setting has finished but before the PDF
> > generation "starts".
> 
> yes and often something is left over for a next page so it's kind of
> fluid
> 
> > 
> > QUESTION: Is it possible to use the new LuaMetaTeX callbacks (found
> > in chapter 10 of the "LuaMetaTEX Reference Manual") to "suppress"
> > any further computation at various points in the ConTeXt pipeline?
> > 
> 
> sure, you can kick in handlers at various stages (assuming that you
> keep in mind where you kick them in as there is some order involved)
> 
> > For example, could I use one of the "*_linebreak_filter"s (or the
> > "append_to_vlist_filter") to "return" an empty value and hence
> > reduce further computation downstream in the pipeline?
> 
> you can but linebreak 

Re: [NTG-context] Installing VSCode extension?

2020-12-02 Thread Saša Janiška
On Wed, 5 Aug 2020 22:07:53 +0200
Mikael Sundqvist  wrote:

> * Since January, the editor supports a global tasks.json file (if I
> understood
> https://stackoverflow.com/questions/41046494/making-global-tasks-in-vs-code
> correctly).

Are those extensions only for VSCode or they should work with other
clients/editors (Emacs, Vim, ST) all of which have LSP support?


Sincerely,
Gour

-- 
A person is considered still further advanced when he regards honest
well-wishers, affectionate benefactors, the neutral, mediators, the
envious, friends and enemies, the pious and the sinners all with an
equal mind.


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