Re: [NTG-context] All NUL files in the Context distribution

2023-06-14 Thread Leah Neukirchen via ntg-context
Leah Neukirchen via ntg-context  writes:

> Hi,
>
> I was looking into the SciTE setup when I found that
> tex/texmf-context/context/data/scite/context/scite-context-internal.properties
> only contained NUL bytes.
>
> Deleting and reinstalling doesn't fix it.
>
> I have now checked the other files there and these files seem to have
> gotten corrupted at some point.  Does anyone have a working copy to
> restore them?
>
> tex/texmf-context/context/data/scite/context/scite-context-internal.properties
> tex/texmf-context/context/data/scite/context/lexers/scite-context-lexer-web-snippets.lua
> tex/texmf-context/doc/context/sources/general/manuals/start/en/ma-cb-en-commands.tex
>
> Thanks,

Note that they are broken via HTTP:

% wget 
http://lmtx.pragma-ade.com/install-lmtx//tex/texmf-context/context/data/scite/context/scite-context-internal.properties
% sha1sum scite-context-internal.properties 
55a4ba44601c71deb73c0cad41b3632722696a32  scite-context-internal.properties
% xxd scite-context-internal.properties
:          
0010:          
0020:          
0030:          
0040:          
0050:          
...

-- 
Leah Neukirchenhttps://leahneukirchen.org
___
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] All NUL files in the Context distribution

2023-06-14 Thread Leah Neukirchen via ntg-context
Hi,

I was looking into the SciTE setup when I found that
tex/texmf-context/context/data/scite/context/scite-context-internal.properties
only contained NUL bytes.

Deleting and reinstalling doesn't fix it.

I have now checked the other files there and these files seem to have
gotten corrupted at some point.  Does anyone have a working copy to
restore them?

tex/texmf-context/context/data/scite/context/scite-context-internal.properties
tex/texmf-context/context/data/scite/context/lexers/scite-context-lexer-web-snippets.lua
tex/texmf-context/doc/context/sources/general/manuals/start/en/ma-cb-en-commands.tex

Thanks,
-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] Undefined control sequence error message

2023-03-16 Thread Leah Neukirchen via ntg-context
Hi,

LMTX prints a bit weird error message for undefined control sequences:

\starttext
\zong
\stoptext

tex error   > tex error on line 2 in file ./foo.tex: Undefined control 
sequence \undefined 

 
\zong

Shouldn't it print "\zong" in the "tex error" line too?

-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] LMTX: request for \tracinglostchars=3

2022-12-22 Thread Leah Neukirchen via ntg-context
Hans Hagen via ntg-context  writes:

>> LMTX only seems to support =0 (ignore) and =1 (report).  Making these
>> a fatal error (with exit status != 0) would be useful for automated
>> typesetting, as missing characters easily can get lost in the logs,
>> and then symbols are missing unnoticed in the output.
>
> Will never be default, you can play with:
>
> % \checkmissingcharacters
> % \removemissingcharacters
> % \replacemissingcharacters
> % \handlemissingcharacters
>
>> (However, \tracinglostchars=3 also doesn't seem to work with
>> LuaTeX+MKIV, probably because there is code to fallback to other fonts?)
> and if you want to quit:
>
> \enabledirectives[logs.errors=missing characters]

Ok, this is useful.

I looked around, but I couldn't find a similar feature for when a font
is not found?

cu,
-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] LMTX: request for \tracinglostchars=3

2022-12-22 Thread Leah Neukirchen via ntg-context
Hi,

since TeX Live 2021 (TeX 3.141592653), there is

> - if \tracinglostchars >= 3, make missing characters an error (not just
>   a log message), and always report the character code in hex.

LaTeX also enables this by default these days.

LMTX only seems to support =0 (ignore) and =1 (report).  Making these
a fatal error (with exit status != 0) would be useful for automated
typesetting, as missing characters easily can get lost in the logs,
and then symbols are missing unnoticed in the output.

(However, \tracinglostchars=3 also doesn't seem to work with
LuaTeX+MKIV, probably because there is code to fallback to other fonts?)

cu,
-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] Containerized ConTeXt

2022-12-14 Thread Leah Neukirchen via ntg-context
Thangalin via ntg-context  writes:

> Thoughts? Suggestions for improvement?

If you are looking for technical suggestions, every RUN line will
create a layer even if you delete files later.  I'd suggest making the
final image by copying the root directory of a multistage container,
e.g. https://adriancitu.com/2022/03/11/7-ways-to-build-lighter-linux-containers/

Alternatively, do all the steps before installing ConTeXt in a
multistage container, and run all shell commands that install ConTeXt
in one action, then you get two layers and the lower one only changes
if a font changes (or alpine:latest).

-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] LMTX: reimplementing texquotes as OTF feature

2022-11-12 Thread Leah Neukirchen via ntg-context
Hans Hagen via ntg-context  writes:

> can you show what is wrong and what it should be with
>
> fonts.handlers.otf.addfeature {
> name = "germantexlig",
> type = "ligature",
> data = {
> ['“'] = { "`", "`" },
> ['”'] = { "'", "'" },
> ['„'] = { '"', "`" },
> ['“'] = { '"', "'" },
> ['‘'] = { "`" },
> ['’'] = { "'" }
> }
> }

Since `` and "' map to the same character, only "' works.
The table has only 5 entries, not 6!  (This took me a while to realize. ;))

> best not use an existign feature because we accumulate ... features
> come in order (you can force order if needed as you probably saw in
> one of the test files)
>
> \definefontfeature[ltest][germantexlig=yes,trep=no] \addff{ltest}

I think "texlig" and "texsub" aren't existing features.  But even
renaming doesn't help.

I've attached the working Schola screenshot and the broken LModern
behavior.


-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] LMTX: reimplementing texquotes as OTF feature

2022-11-11 Thread Leah Neukirchen via ntg-context
Hi,

as Hans recommended in the last video meeting, I tried to implement
the texquotes feature using OTF features, and hit two problems:

1) To support German quotes as well, I have two ligatures that end
   up as the same glyph:
  `` -> “
  "' -> “
   This can't be in the same ligature feature, as it will overwrite
   the table entry with a duplicate key.

   After some fiddling, I decided to map "' to a Unicode PUA symbol
   and then add a second feature that maps this symbol to “ using
   the substitute feature.  This works for TeX Gyre Schola.
   But perhaps someone knows a nicer way.

2) This approach doesn't work for lmodern or palatino, I still
   get "' as inch-sign/quote there... anything else I need to tweak
   for these fonts?


\startluacode
fonts.handlers.otf.addfeature {
name = "texlig",
type = "ligature",
data = {
['“'] = { "`", "`" },
['”'] = { "'", "'" },
['„'] = { '"', "`" },
[''] = { '"', "'" },
['‘'] = { "`" },
['’'] = { "'" }
}
}
fonts.handlers.otf.addfeature {
name = "texsub",
type = "substitute",
data = {
[''] = '“',
}
}
\stopluacode

% with lmodern or palatino it breaks
\setupbodyfont[schola]

\definefontfeature[ltest][texlig=yes,texsub=yes,trep=no]
\addff{ltest}

\starttext

``foo'' `foo' "`foo"' 19" rack

\stoptext


Thanks,
-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] Backgrounds has changed in latest lmtx

2022-10-23 Thread Leah Neukirchen via ntg-context
"Thomas A. Schmitz via ntg-context"  writes:

> On 10/23/22 21:34, Otared Kavian via ntg-context wrote:
>> Hi Thomas,
>> Both your examples typeset fine with my installation of LMTX
>> (version 2022.10.22 11:23) on MacOS 11.7.
>> (Indeed you previous file test file reporting the background issue
>> is typeset fine also).
>> Best regards : Otared
>
> Thanks, Otared - that's bizarre. I just tried both on linux64 and
> macos (12.6, arm): run install.sh, reload font cache and run context
> without the luatex switch on the minimal example with the XITS Math
> font, and on both systems, I get the error that I have sent this
> afternoon. Can you try after rebuilding the font cache?

FWIW I get the error too on linux64.

-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] Setting the size of \small

2022-10-21 Thread Leah Neukirchen via ntg-context
Hans Hagen via ntg-context  writes:

> I'll add
>
> \setupbodyfontenvironment
>   [all]
>   [12pt]
>   [x=4pt,
>small=4pt]
>
> as option (assuming we have no performance hit).

It would also be nice to be able to

\setupbodyfontenvironment[all][default][x=0.8]

(I solved my actual problem by adding a new custom fontsize with
\definefontsize, as it's not really \small but something else.)

-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] Setting the size of \small

2022-10-20 Thread Leah Neukirchen via ntg-context
Hi,

playing around with \definebodyfontenvironment with latest LMTX,
I found this possibly buggy behavior:

\definebodyfontenvironment[12pt][small=6pt] % x=6pt works here
\setupbodyfont[12pt]
\starttext
normal {\tx tx} {\small small}
\stoptext

With \definebodyfontenvironment[12pt][x=6pt] I can resize \tx fine,
but for \small it doesn't work.

-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] Suboptimal German hyphenation

2022-10-19 Thread Leah Neukirchen via ntg-context
Leah Neukirchen via ntg-context  writes:

> Max Chernoff via ntg-context  writes:
>
>> Hi Leah,
>>
>>> I was typesetting some German text on a narrow page when I discovered
>>> the justification wasn't as good as expected.  I think I tracked this
>>> down to differences in hyphenation points, namely, ConTeXt has fewer:
>>> 
>>> \starttext
>>> \language[de]
>>> \showhyphens{Zusammenhang}
>>> \showhyphens{anderswo}
>>> \showhyphens{anderswoher}
>>> \stoptext
>>> 
>>> This shows
>>> languages   > hyphenation > show: Zusam[-||]men[-||]hang
>>> languages   > hyphenation > show: anderswo
>>> languages   > hyphenation > show: anders[-||]wo[-||]her
>>
>> Babel/ngerman sets left/righthyphenmin to 2/2, but ConTeXt sets those to
>> 3/3 for German. (The English default is 2/3). I don't speak German so I
>> have no idea which is correct, but you can get the same behaviour in
>> ConTeXt with:
>
> Perfect, thanks!
>
> Many prefixes have two letters, so changing the default may be
> reasonable.  But there are more experienced German typographers on
> this list who can chime in.

After some research, I found the recommendation in
Forssman, de Jong: Detailtypografie (4. Aufl, 2008, S. 124f.) to
use 2/3 for German justified texts, and 3/4 to 5/5 for ragged text.
They also recommend to never hyphenate words with 5 letters, not sure
that can be encoded.

-- 
Leah Neukirchenhttps://leahneukirchen.org
___
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] LMTX generates PDFs with non-working fonts on real printers

2022-10-12 Thread Leah Neukirchen via ntg-context
Max Chernoff via ntg-context  writes:

> Hi Leah,
>
>
>> > Leah and I are zooming in on the issue. It might relate to wrong font
>> > matrix default behavior in the pdf printer driver, and GS got a fix
>> > for that long ago, so maybe old printers with not-updated drivers can
>> > be affected.
>> >
>> > Once we're confident that we can catch it Leah (who does the low level
>> > introspective testing with viewers, printers and tools) likely will
>> > report on it and there will be a test file for users to test if what
>> > we do is okay before we apply the safeguard.
>> 
>> There's a write up now on the issue:
>> https://leahneukirchen.org/blog/archive/2022/10/50-blank-pages-or-black-box-debugging-of-pdf-rendering-in-printers.html
>
> Great write up! I was expecting the issue to be something quite simple,
> but it's actually fairly complicated. Especially considering that the
> issue only happens with a few printer models, I'm pretty impressed that
> you managed to find the problem. At least the fix appears quite easy.
>
> Seeing that you're modifying the font encoding, could you perhaps
> reconsider supporting hinting in LMTX? 
>
>https://mailman.ntg.nl/pipermail/ntg-context/2022/106311.html
>
> Even with a high resolution screen, I can still see a difference, and
> the issue can show up in print too:
>
>
>https://graphicdesign.stackexchange.com/q/5874
>
> I'm fairly confident that these issues are all hinting-related:
>
>https://mailman.ntg.nl/pipermail/ntg-context/2022/106874.html
>https://mailman.ntg.nl/pipermail/ntg-context/2022/105212.html
>
> Considering that all of the fonts included with ConTeXt are hinted, it
> seems like a shame to not include any of that data in the generated
> PDFs.

The last version of font-cff.lua should also copy the hinting-related
values of the CFF properly (/BlueScale, /StemSnap[HV] etc).
We fixed that on the side. ;)

-- 
Leah Neukirchenhttps://leahneukirchen.org
___
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] LMTX generates PDFs with non-working fonts on real printers

2022-10-11 Thread Leah Neukirchen via ntg-context
Hans Hagen via ntg-context  writes:

> On 10/9/2022 8:03 AM, Max Chernoff via ntg-context wrote:
>> Hi all,
>> 
>>> I use LuaMetaTeX 2.10 20220918 + ConTeXt LMTX 2022.09.11.
>>>
>>> Here's a tiny test document, I disabled PDF compression but it also
>>> doesn't work with the default settings.
>>>
>>> \setupbackend[level=0,compresslevel=0]
>>> \starttext
>>> Just a line of text.
>>> \stoptext
>>>
>>> When I print this "directly" (i.e. sending the raw PDF to the printer)
>>> on a Ricoh MP3053 or on a Samsung CLP-680DW, I just get an empty page.
>> Just to add some more data points, I tested the attached MkXL file
>> on
>> two printers, and the file printed perfectly on both.
>> Printer 1:
>> Brother HL-3170CDW
>> Printed via running "cat test.mkxl.pdf | nc Colour-Printer.local 9100"
>> Printer 2:
>> HP M227f LaserJet
>> Printed from the PDF file on a USB stick
>> Neither printer is anything fancy; they're both fairly
>> inexpensive home
>> laser printers. I've got a much older Brother laser printer that I may be
>> able to test with next week.
>> Sorry I can't be of more help.
> Leah and I are zooming in on the issue. It might relate to wrong font
> matrix default behavior in the pdf printer driver, and GS got a fix
> for that long ago, so maybe old printers with not-updated drivers can
> be affected.
>
> Once we're confident that we can catch it Leah (who does the low level
> introspective testing with viewers, printers and tools) likely will
> report on it and there will be a test file for users to test if what
> we do is okay before we apply the safeguard.

There's a write up now on the issue:
https://leahneukirchen.org/blog/archive/2022/10/50-blank-pages-or-black-box-debugging-of-pdf-rendering-in-printers.html

-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] \quotation, protrusion and linebreaking

2022-10-11 Thread Leah Neukirchen via ntg-context
Henning Hraban Ramm via ntg-context  writes:

> Am 11.10.22 um 20:00 schrieb Leah Neukirchen via ntg-context:
>> Hello,
>> I noticed the following problem:
>> \showframe
>> \startluacode
>>fonts.protrusions.vectors.pure[0x201C] = { 1, 1 }
>> \stopluacode
>> \definefontfeature[default][default][protrusion=pure]
>> \setupalign[hanging]
>> \starttext
>> This text is unquoted.
>> “This text is quoted manually.”
>> \quotation{This text is quoted by a macro.}
>> This is a very long line followed by a nice linebreak, very
>> supercalifragilisticexpialidocious.
>> This is a very long line followed by an ugly linebreak, not
>> \quotation{supercalifragilisticexpialidocious}
>> \stoptext
>> The macro-quoted text is not protruded.  I fixed this locally with a
>> macro
>> \def\q#1{\protrusionboundary1\quotation{#1}}
>> Should this be default?
>> But the missing hyphenation I have to add myself with \-.  Ideas?
>
> Try
> \setupdelimitedtext[quotation][method=font]

That fixes both issues, thanks!

Not sure where I should have learned this exists, however. ;)

-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] \quotation, protrusion and linebreaking

2022-10-11 Thread Leah Neukirchen via ntg-context
Hello,

I noticed the following problem:


\showframe

\startluacode
  fonts.protrusions.vectors.pure[0x201C] = { 1, 1 }
\stopluacode

\definefontfeature[default][default][protrusion=pure]
\setupalign[hanging]

\starttext

This text is unquoted.

“This text is quoted manually.”

\quotation{This text is quoted by a macro.}

This is a very long line followed by a nice linebreak, very 
supercalifragilisticexpialidocious.

This is a very long line followed by an ugly linebreak, not 
\quotation{supercalifragilisticexpialidocious}

\stoptext


The macro-quoted text is not protruded.  I fixed this locally with a macro
\def\q#1{\protrusionboundary1\quotation{#1}}
Should this be default?

But the missing hyphenation I have to add myself with \-.  Ideas?

-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] Help test a LMTX bug fix: tweaks in PDF generation

2022-10-09 Thread Leah Neukirchen via ntg-context
Henning Hraban Ramm via ntg-context  writes:

> Am 09.10.22 um 17:33 schrieb Leah Neukirchen via ntg-context:
>> Hi,
>> last week we had a long thread about non-printing PDF on this list
>> and
>> together with Hans I tracked down the issue and we found a fix.
>> Since it changes some details of how PDFs are generated by LMTX, we'd
>> like to test this change first on a wide range of software and
>> printers.
>> So please: Try to preview and then try to print the attached PDF;
>> and report back if either preview or printout does not look like
>> the attached reference PNG image (i.e. something is missing,
>> the fonts look different, or have wrong relative size.)
>> If you use other PDF tools in your workflow, please also check they
>> continue to work as before (and just as well as with MKIV-generated PDFs).
>
> Hi Leah, thank you!
>
> I viewed and printed the PDF with pdf.js in Thunderbird, Apple Preview
> and Adobe Acrobat Pro 9 to my Kyocera FS-C5100DN color laserprinter
> via KPDL (PS-compatible) driver.
> I don’t see any font problems, but neither text nor the bar are 100%
> black – is this intentional? Doesn’t look like RGB black, there are no
> other colors involved except in the printout from pdf.js.

Should be all black (CMYK black), but we didn't change this.
Picking from the screenshot I get #00 on Linux with evince, mupdf,
pdf.js.

> pdf.js seems to print as image and blurs the outlines. (I never tried
> to print from pdf.js before, is this normal?)

Yes, unfortunately.  But not related to our changes.

> Hraban

-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] startTEXpage on A4

2022-10-09 Thread Leah Neukirchen via ntg-context
Hans Hagen via ntg-context  writes:

> On 10/9/2022 3:52 PM, Leah Neukirchen via ntg-context wrote:
>> Wolfgang Schuster via ntg-context  writes:
>> 
>>> Leah Neukirchen via ntg-context schrieb am 09.10.2022 um 15:19:
>>>> Hi,
>>>>
>>>> is there a way to have something like
>>>>
>>>> \setuppapersize[A5][A4]
>>>>
>>>> but have the "inner paper size" be a computed fit like in
>>>> \startTEXpage?
>>>>
>>>> Or, alternatively, is there is a way to print crop marks around
>>>> an environment like \startTEXpage?
>>>
>>> Can you be more concrete what your goal is, there are a few ways to solve
>>> your problem but with a few more information we can give you a good
>>> solution.
>> Say I want to print some stickers or paper strips of non-fixed size,
>> and get crop marks around them to know where to cut.
>> With \setuppapersize and \setuparranging I can do this nicely if I
>> know the size in advance, but in some cases I don't.
>
> \definepapersize
>   [label]
>   [width=6cm,
>height=25mm]

But that requires knowing the size in advance.  Think of the labels in
a museum that depend how long the description is. ;)

-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] Help test a LMTX bug fix: tweaks in PDF generation

2022-10-09 Thread Leah Neukirchen via ntg-context
Hi,

last week we had a long thread about non-printing PDF on this list and
together with Hans I tracked down the issue and we found a fix.
Since it changes some details of how PDFs are generated by LMTX, we'd
like to test this change first on a wide range of software and
printers.

So please: Try to preview and then try to print the attached PDF;
and report back if either preview or printout does not look like
the attached reference PNG image (i.e. something is missing,
the fonts look different, or have wrong relative size.)

If you use other PDF tools in your workflow, please also check they
continue to work as before (and just as well as with MKIV-generated PDFs).



fontmatrixtest.pdf
Description: Adobe PDF document

Thank you very much,
-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] startTEXpage on A4

2022-10-09 Thread Leah Neukirchen via ntg-context
Wolfgang Schuster via ntg-context  writes:

> Leah Neukirchen via ntg-context schrieb am 09.10.2022 um 15:19:
>> Hi,
>>
>> is there a way to have something like
>>
>> \setuppapersize[A5][A4]
>>
>> but have the "inner paper size" be a computed fit like in
>> \startTEXpage?
>>
>> Or, alternatively, is there is a way to print crop marks around
>> an environment like \startTEXpage?
>
> Can you be more concrete what your goal is, there are a few ways to solve
> your problem but with a few more information we can give you a good
> solution.

Say I want to print some stickers or paper strips of non-fixed size,
and get crop marks around them to know where to cut.

With \setuppapersize and \setuparranging I can do this nicely if I
know the size in advance, but in some cases I don't.

-- 
Leah Neukirchenhttps://leahneukirchen.org
___
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] startTEXpage on A4

2022-10-09 Thread Leah Neukirchen via ntg-context
Hi,

is there a way to have something like

\setuppapersize[A5][A4]

but have the "inner paper size" be a computed fit like in
\startTEXpage?

Or, alternatively, is there is a way to print crop marks around
an environment like \startTEXpage?

Thanks,
-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] LMTX generates PDFs with non-working fonts on real printers

2022-10-06 Thread Leah Neukirchen via ntg-context
Hans Hagen via ntg-context  writes:

> On 10/6/2022 2:42 PM, Leah Neukirchen wrote:
>
>> But I also found yet another printer model that doesn't print:
>> the HP Color LaserJet 4700 (Model Q7492A, Firmware 20060821 46.031.1).
>> Since you seem to own the only printer that works ;) would
>> you be so kind and share which model you have?
>
> We have a HP ColorFlowMFP X585 full-width highspeed duplex inkjet
> printer (a couple of years old, always prints ok). So far we never
> heard of printing failures elsewhere.
>
>> I also wondered whether bisecting the snapshot-repo would work.
>> But I only have one LMTX binary; this font handling should be all in
>> lua code tho?
>
> It makes no sense to compare luametatex and luatex .. it's different
> machinery.
>
> Btw, some in the thread mention issues (like bad looking heros shapes)
> but in your case there is no print at all, so that is different. Isn't
> there some error log in these printer?

The error log didn't contain anything useful.

I made two experiments now.

First, I modified the MKIV PDF file to use the MKXL font stream, and
changed the text primitives to use low chars.  This renders fine on
all PDF viewers I found (text is garbled, of course), but it still
doesn't print.  So now I'm fairly sure now the bug is in the font stream.



foo.doctored.pdf
Description: Adobe PDF document

I finally found a tool to analyze CID fonts at
https://github.com/janpe2/CFFDump
I noticed two things:
1) the MKIX Top DICT INDEX doesn't contain /version, but the string is
   in the SID.  Unfortunately merely adding it to topdict in
   tablewriters.cff doesn't fix the printing bug.  But I'd still
   recommend doing so.

2) The Private DICT doesn't contain /StdHW /StdVW /StemSnapH /StemSnapV.
   Also BlueScale is 0.
   This should not matter for printing(?) but it explains why
   Adobe displays it differently! The hinting information is missing.

   Note that the code would copy this data but it's missing in the
   cffinfo already.

I'll attach both CFF dumps here, perhaps someone finds other issues.



font-0008.mkiv.dump
Description: Binary data


font-0008.mkxl.dump
Description: Binary data

cu,
-- 
Leah Neukirchenhttps://leahneukirchen.org
___
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] LMTX generates PDFs with non-working fonts on real printers

2022-10-06 Thread Leah Neukirchen via ntg-context
Hans Hagen via ntg-context  writes:

> On 10/6/2022 12:31 PM, Ulrike Fischer via ntg-context wrote:
>> Am Tue, 4 Oct 2022 18:09:28 +0200 schrieb Hans Hagen via
>> ntg-context:
>> 
 Hans, is it possible that LMTX uses some technique that is “too modern”
 for some built-in PDF interpreter?
>> 
>>> we basically use the old pre 1.6 embedding, same as luatex
>> I saw that the new code renumbers the glyphs, so it uses 0001, 0002
>> etc instead of the mix of various slot numbers in luatex. Perhaps
>> the printers don't like that.
> indeed, soem control code confusion; a few days ago i suggested a test
> for that and got no response yet

Sorry, I didn't have access to a printer until last night.

As I expected, starting the numbering from 31 doesn't help
either---still blank pages.  (Note that with DejaVu Sans the numbering
from 1 works fine.)

But I also found yet another printer model that doesn't print:
the HP Color LaserJet 4700 (Model Q7492A, Firmware 20060821 46.031.1).

Since you seem to own the only printer that works ;) would
you be so kind and share which model you have?

I also wondered whether bisecting the snapshot-repo would work.
But I only have one LMTX binary; this font handling should be all in
lua code tho?
-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] LMTX generates PDFs with non-working fonts on real printers

2022-10-04 Thread Leah Neukirchen via ntg-context
Hans Hagen via ntg-context  writes:

> Hi,
>
> does (the obsolete)
>
> \enabledirectives[backend.pdf.forcecidset]
>
> help

No; same blank page. :(

(Also MKIV works without CIDSet...)

I looked into /StemV 0 (which was different in MKIV) but that works
with the TTF files, too.  Also should be ignored for Type 3 anyway.

Really out of ideas now...

-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] LMTX generates PDFs with non-working fonts on real printers

2022-10-04 Thread Leah Neukirchen via ntg-context
Hans Hagen  writes:

> what is sent to the printer .. maybe not pdf but something the printer
> driver produces

For the Ricoh and Samsung printers, we printed the raw PDF directly
over JetDirect (port 9100).  For the Brother, the "upload PDF"
function was used.  So no outside printer drivers involved.

If I run it through Ghostscript, that somehow fixes it:
gs -dPDF -dBATCH -dNOPAUSE -sDEVICE=pdfwrite -sOutputFile=print.pdf foo.pdf

But Ghostscript also seems to rewrite the font, at least in FontForge
it shows a different scale.

Are there any tools to analyze this CID font stream?

-- 
Leah Neukirchenhttps://leahneukirchen.org
___
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] LMTX generates PDFs with non-working fonts on real printers

2022-10-04 Thread Leah Neukirchen via ntg-context
Hans Hagen via ntg-context  writes:

> On 10/4/2022 4:16 AM, Angel M Alganza via ntg-context wrote:
>> On Mon, Oct 03, 2022 at 07:17:10PM +0200, Leah Neukirchen via
>> ntg-context wrote:
>> 
>>> When I print this "directly" (i.e. sending the raw PDF to the printer)
>>> on a Ricoh MP3053 or on a Samsung CLP-680DW, I just get an empty page.
>> I believe that is the exact same problem I have and that I described
>> a
>> few days ago in my email with subject "Missing letters and numbers in
>> printout".  I have some grids on my document, which gets printed out,
>> but nothing else does.

Another data point: Brother B205 doesn't print it either.
But would all of these use the same licensed PDF renderer...

>>> The PDFs render fine on every PDF reader I could find.
>> Same here.
>> 
>>> PDFs generated directly from Context MKIV from TeXLive 2022 using
>>> LuaTeX 1.5 render fine on these printers.
>>> I've also printed PDFs from pdfTeX in the past fine.
>> Same here.
>> 
>>> Any ideas what I should try to help debug this?
>> I was told that this is the default now, that isn't going to change,
>> and
>> that I could always use LuaTeX instead.  I could also use LaTeX, I
>> guess, but I'd rather keep using ConTeXt at least while my old 32 bits
>> OpenBSD installation works.
> what happens if you include the lmtx pdf in a mkiv document as image

On above Brother B205, this document:

\starttext
\externalfigure[foo.mkxl.pdf]
\stoptext

only prints the page number of the outer document, which is kept in a
seperate font:

NREXLC+LMRoman12-Regular CID Type 0C   Identity-H   yes yes 
yes  5  0
CLLXEY+LMRoman12-Regular CID Type 0C   Identity-H   yes yes 
yes  8  0

I tried converting the pdf with pdfjam (which uses pdfTeX internally)
before, which probably uses similar mechanisms, and it didn't work
either.

-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] LMTX generates PDFs with non-working fonts on real printers

2022-10-03 Thread Leah Neukirchen via ntg-context
Hans Hagen via ntg-context  writes:

> On 10/3/2022 7:17 PM, Leah Neukirchen via ntg-context wrote:
>> Hi,
>> I use LuaMetaTeX 2.10 20220918 + ConTeXt LMTX 2022.09.11.
>> Here's a tiny test document, I disabled PDF compression but it also
>> doesn't work with the default settings.
>> \setupbackend[level=0,compresslevel=0]
>> \starttext
>> Just a line of text.
>> \stoptext
>> When I print this "directly" (i.e. sending the raw PDF to the
>> printer)
>> on a Ricoh MP3053 or on a Samsung CLP-680DW, I just get an empty page.
>> The PDFs render fine on every PDF reader I could find.
>> Conversion to PostScript with pstopdf (poppler-22.07.0) and then
>> sending the PS renders the document correctly on the printer.
>> PDFs generated directly from Context MKIV from TeXLive 2022 using
>> LuaTeX 1.5 render fine on these printers.
>> I've also printed PDFs from pdfTeX in the past fine.
>> I attached the non-working 'foo.pdf.mkix'
>> and the working 'foo.pdf.mkiv' file.
>> I tried to disable font subsetting to debug this further, but I
>> couldn't figure out how to do it.
>
> subsetting should not be a problem and both files are subsetted  (lmxt
> a bit different but not fundamentally)

Well the idea was to have the same font stream in both files, so we
exclude that from the reasons it breaks.

Curiously, when I use Deja Vu:
\setupbodyfont[dejavu]

Then I get a
VHOYGZ+DejaVuSansMonoCID TrueType  Identity-H
   yes yes yes  8  0

and the PDF prints fine!  So it must be related to how Type 0C fonts
are written out, I think.

-- 
Leah Neukirchenhttps://leahneukirchen.org
___
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] LMTX generates PDFs with non-working fonts on real printers

2022-10-03 Thread Leah Neukirchen via ntg-context
Leah Neukirchen via ntg-context  writes:

> Hi,
>
> I use LuaMetaTeX 2.10 20220918 + ConTeXt LMTX 2022.09.11.
>
> Here's a tiny test document, I disabled PDF compression but it also
> doesn't work with the default settings.
>
> \setupbackend[level=0,compresslevel=0]
> \starttext
> Just a line of text.
> \stoptext
>
> When I print this "directly" (i.e. sending the raw PDF to the printer)
> on a Ricoh MP3053 or on a Samsung CLP-680DW, I just get an empty page.
>
> The PDFs render fine on every PDF reader I could find.

On Acrobat DC on macOS, there is a visible difference between the two files:


Note that the 'a' and 'l' look quite different.

But I couldn't reproduce it with MuPDF for example.

-- 
Leah Neukirchenhttps://leahneukirchen.org
___
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] LMTX generates PDFs with non-working fonts on real printers

2022-10-03 Thread Leah Neukirchen via ntg-context
Hi,

I use LuaMetaTeX 2.10 20220918 + ConTeXt LMTX 2022.09.11.

Here's a tiny test document, I disabled PDF compression but it also
doesn't work with the default settings.

\setupbackend[level=0,compresslevel=0]
\starttext
Just a line of text.
\stoptext

When I print this "directly" (i.e. sending the raw PDF to the printer)
on a Ricoh MP3053 or on a Samsung CLP-680DW, I just get an empty page.

The PDFs render fine on every PDF reader I could find.

Conversion to PostScript with pstopdf (poppler-22.07.0) and then
sending the PS renders the document correctly on the printer.

PDFs generated directly from Context MKIV from TeXLive 2022 using
LuaTeX 1.5 render fine on these printers.
I've also printed PDFs from pdfTeX in the past fine.

I attached the non-working 'foo.pdf.mkix'
and the working 'foo.pdf.mkiv' file.

I tried to disable font subsetting to debug this further, but I
couldn't figure out how to do it.

Any ideas what I should try to help debug this?



foo.pdf.mkxl
Description: Binary data


foo.pdf.mkiv
Description: Binary data

cu,
-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] Suboptimal German hyphenation

2022-09-28 Thread Leah Neukirchen via ntg-context
Max Chernoff via ntg-context  writes:

> Hi Leah,
>
>> I was typesetting some German text on a narrow page when I discovered
>> the justification wasn't as good as expected.  I think I tracked this
>> down to differences in hyphenation points, namely, ConTeXt has fewer:
>> 
>> \starttext
>> \language[de]
>> \showhyphens{Zusammenhang}
>> \showhyphens{anderswo}
>> \showhyphens{anderswoher}
>> \stoptext
>> 
>> This shows
>> languages   > hyphenation > show: Zusam[-||]men[-||]hang
>> languages   > hyphenation > show: anderswo
>> languages   > hyphenation > show: anders[-||]wo[-||]her
>
> Babel/ngerman sets left/righthyphenmin to 2/2, but ConTeXt sets those to
> 3/3 for German. (The English default is 2/3). I don't speak German so I
> have no idea which is correct, but you can get the same behaviour in
> ConTeXt with:

Perfect, thanks!

Many prefixes have two letters, so changing the default may be
reasonable.  But there are more experienced German typographers on
this list who can chime in.

-- 
Leah Neukirchenhttps://leahneukirchen.org
___
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] LMTX incompatibility in \meaning breaks TikZ, other minor issues

2022-09-28 Thread Leah Neukirchen via ntg-context
Hans Hagen via ntg-context  writes:

>> After a bunch of debugging, it turns out that LMTX breaks the TikZ
>> 'quotes'
>> library, which works using code ala:
>> \def\tikz@enable@node@quotes{%
>>\pgfkeyssetvalue{/handlers/first char syntax/the character
>> "}{\tikz@quote@parser}%
>>\let\tikz@quotes@as\tikz@node@quotes@as%
>> }
>> The last part of the /-key is derived from \meaning, but in LMTX,
>> \meaning" is "the character U+0022 'quotation mark'"
>> and thus the key cannot be found.
>> I have patched TikZ for now to match for this alternate string too.
>
> a bit weird way to test a key .. maybe you can compare to
>
> \edef\ThatQuote{\meaning/}
>
> using \ifx
>
>> But perhaps it would be better for compatibility to agree with the
>> original TeX \meaning strings for the 7-bit ASCII subset at least. 
>
> too messy when want to parse

To follow up on this: I have upstreamed patches to tikz and tikz-cd to
use the dynamic output of \meaning instead of hardcoding.

I'm not sure who maintains the t-tikz module, but if it gets updated
at some point the fix should be in.

-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] Suboptimal German hyphenation

2022-09-28 Thread Leah Neukirchen via ntg-context
Hi,

I was typesetting some German text on a narrow page when I discovered
the justification wasn't as good as expected.  I think I tracked this
down to differences in hyphenation points, namely, ConTeXt has fewer:

\starttext
\language[de]
\showhyphens{Zusammenhang}
\showhyphens{anderswo}
\showhyphens{anderswoher}
\stoptext

This shows
languages   > hyphenation > show: Zusam[-||]men[-||]hang
languages   > hyphenation > show: anderswo
languages   > hyphenation > show: anders[-||]wo[-||]her

Now with LaTeX and Babel:

\documentclass{article}
\usepackage[ngerman]{babel}
\begin{document}
\showhyphens{Zusammenhang}
\showhyphens{anderswo}
\showhyphens{anderswoher}
\end{document}

This shows
[] \TU/lmr/m/n/10 Zu-sam-men-hang
[] \TU/lmr/m/n/10 an-ders-wo
[] \TU/lmr/m/n/10 an-ders-wo-her

The LaTeX hyphenation points agree with the German Duden dictionary.

As none of the words use more than 7-bit ASCII, I think newer pattern
changes are not related.

Curiously, the same effect already appears with MKII and MKIV from
TeXLive 2014, the oldest I had around.

I'm also surprised 'anders-wo-her' gets hyphenated but 'anderswo' is
not hyphenated at all.

I could not reproduce a difference with English words so far.

Any ideas? As far as I understand, MKIV/LMTX should use the
de-hyph-1996 patterns which LuaLaTeX uses these days too, via
hyph-utf8.

Thanks,
-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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] LMTX incompatibility in \meaning breaks TikZ, other minor issues

2022-09-22 Thread Leah Neukirchen via ntg-context
Hi,

I'm trying to get tikz-cd to run on LMTX and some examples already
work fine, but I had a problem with text on arrows.

To reproduce:

\usemodule[tikz]
\usetikzlibrary[cd]

\starttext
\starttikzcd
A \arrow{r}{A} \NC B \NR
\stoptikzcd
\stoptext

This builds fine on MkIV from TeXLive 2022 with LuaTeX, but on LMTX I get:

system  > ConTeXt  ver: 2022.09.11 20:44 LMTX  fmt: 2022.9.20  int: 
english/english
...
close source> level 2, order 63, name 'tikzlibrarycd.code.tex'
fonts   > preloading latin modern fonts (second stage)
fonts   > 'fallback modern-designsize rm 12pt' is loaded
tex error   > tex error on line 8 in file ./tik.tex: Package pgfkeys Error: 
I do not know the key '/tikz/"{A}"{}' and I am going to ignore it. Perhaps you 
misspelled it.^^J...^^Jl.7 I think the culprit is a tikzcd arrow in cell 1-1

After a bunch of debugging, it turns out that LMTX breaks the TikZ 'quotes'
library, which works using code ala:

\def\tikz@enable@node@quotes{%
  \pgfkeyssetvalue{/handlers/first char syntax/the character 
"}{\tikz@quote@parser}%
  \let\tikz@quotes@as\tikz@node@quotes@as%
}

The last part of the /-key is derived from \meaning, but in LMTX,
\meaning" is "the character U+0022 'quotation mark'"
and thus the key cannot be found.

I have patched TikZ for now to match for this alternate string too.

But perhaps it would be better for compatibility to agree with the
original TeX \meaning strings for the 7-bit ASCII subset at least.


I found another minor nit that's not really triggering a bug but still a
difference to LuaTeX: \eTeXrevision should expand to .2, but it
expands to 2 in MkIX.  There is some code out there which uses
constructions like
\number\eTeXversion\eTeXrevision
or even
\ifdim 0\XeTeXrevision pt > 0.9996pt

As LMTX doesn't care about this macro, this should be easy to adjust.


Thanks,
-- 
Leah Neukirchenhttps://leahneukirchen.org/
___
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
___