luatex 1.11: bfchar entry empty in mode=harf
When I load a font in harf mode the bfchar entry is empty: \pdfvariable compresslevel0 \pdfvariable objcompresslevel0 \documentclass{article} \usepackage{harfload} %is actually in my format ... \begin{document} \font\test={texgyreheros:mode=harf;} abcäüö \end{document} gives in the pdf /CMapName /TeX-Identity-GXAFXV-LMRoman10-Regular def /CMapType 2 def 1 begincodespacerange <0000> <FFFF> endcodespacerange 0 beginbfrange endbfrange 0 beginbfchar endbfchar With harftex or an older luatex I get: 1 beginbfchar <0052> <0031> endbfchar What's going on here? -- Ulrike Fischer https://www.troubleshooting-tex.de/
On Sun, Jun 30, 2019 at 12:34 AM Ulrike Fischer
With harftex or an older luatex I get:
1 beginbfchar <0052> <0031> endbfchar
By older luatex I assume luatex with non-harf mode?
What's going on here?
The Lua code for harf mode uses a new callback in HarfTeX to set the glyphs tounicode values, because the existing mechanisms in luatex are too slow for the way I do it. I set tounicode based on shaping output, so need to be done incrementally after loading the font, while luaotfload does it by analyzing the fonts cmap and GSUB tables and can set them at once while loading the font. Regards, Khaled
Am Sun, 30 Jun 2019 23:09:21 +0200 schrieb Khaled Hosny:
On Sun, Jun 30, 2019 at 12:34 AM Ulrike Fischer
wrote: With harftex or an older luatex I get:
1 beginbfchar <0052> <0031> endbfchar
By older luatex I assume luatex with non-harf mode?
What's going on here?
The Lua code for harf mode uses a new callback in HarfTeX to set the glyphs tounicode values, because the existing mechanisms in luatex are too slow for the way I do it. I set tounicode based on shaping output, so need to be done incrementally after loading the font, while luaotfload does it by analyzing the fonts cmap and GSUB tables and can set them at once while loading the font.
hm. The interesting thing is that it works with luatex 1.11 if I load harf-luaotfload in the document, it only fails if I load it in \everyjob through a setting in a local lualatex.ini I used to build the format. Why is this? -- Ulrike Fischer https://www.troubleshooting-tex.de/
On Sun, Jun 30, 2019 at 11:29 PM Ulrike Fischer
Am Sun, 30 Jun 2019 23:09:21 +0200 schrieb Khaled Hosny:
On Sun, Jun 30, 2019 at 12:34 AM Ulrike Fischer
wrote: With harftex or an older luatex I get:
1 beginbfchar <0052> <0031> endbfchar
By older luatex I assume luatex with non-harf mode?
What's going on here?
The Lua code for harf mode uses a new callback in HarfTeX to set the glyphs tounicode values, because the existing mechanisms in luatex are too slow for the way I do it. I set tounicode based on shaping output, so need to be done incrementally after loading the font, while luaotfload does it by analyzing the fonts cmap and GSUB tables and can set them at once while loading the font.
hm. The interesting thing is that it works with luatex 1.11 if I load harf-luaotfload in the document, it only fails if I load it in \everyjob through a setting in a local lualatex.ini I used to build the format. Why is this?
If you are seeing non-empty tounicodes then most likely the font is not processed in harf mode, the only way I set them is through a callback that is missing from luatex. Regards, Khaled
here it seems ok
# luatex --credits
This is LuaTeX, Version 1.11.0 (TeX Live 2020/dev)
The LuaTeX team is Hans Hagen, Hartmut Henkel, Taco Hoekwater, Luigi Scarso.
LuaTeX merges and builds upon (parts of) the code from these projects:
tex : Donald Knuth
etex : Peter Breitenlohner, Phil Taylor and friends
omega : John Plaice and Yannis Haralambous
aleph : Giuseppe Bilotta
pdftex : Han The Thanh and friends
kpathsea : Karl Berry, Olaf Weber and others
lua : Roberto Ierusalimschy, Waldemar Celes and Luiz Henrique de
Figueiredo
metapost : John Hobby, Taco Hoekwater, Luigi Scarso, Hans Hagen and friends
pplib : Paweł Jackowski
fontforge : George Williams (partial)
luajit : Mike Pall (used in LuajitTeX)
Compiled with libharfbuzz 2.5.3; using 2.5.3
Compiled with libpng 1.6.37; using 1.6.37
Compiled with lua version 5.3.5
Compiled with mplib version 2.00
Compiled with zlib 1.2.11; using 1.2.11
Development id: 7169
On Sun, Jun 30, 2019 at 11:52 PM Khaled Hosny
On Sun, Jun 30, 2019 at 11:29 PM Ulrike Fischer
wrote: Am Sun, 30 Jun 2019 23:09:21 +0200 schrieb Khaled Hosny:
On Sun, Jun 30, 2019 at 12:34 AM Ulrike Fischer
wrote:
With harftex or an older luatex I get:
1 beginbfchar <0052> <0031> endbfchar
By older luatex I assume luatex with non-harf mode?
What's going on here?
The Lua code for harf mode uses a new callback in HarfTeX to set the glyphs tounicode values, because the existing mechanisms in luatex are too slow for the way I do it. I set tounicode based on shaping output, so need to be done incrementally after loading the font, while luaotfload does it by analyzing the fonts cmap and GSUB tables and can set them at once while loading the font.
hm. The interesting thing is that it works with luatex 1.11 if I load harf-luaotfload in the document, it only fails if I load it in \everyjob through a setting in a local lualatex.ini I used to build the format. Why is this?
If you are seeing non-empty tounicodes then most likely the font is not processed in harf mode, the only way I set them is through a callback that is missing from luatex.
Regards, Khaled _______________________________________________ dev-luatex mailing list dev-luatex@ntg.nl https://mailman.ntg.nl/mailman/listinfo/dev-luatex
-- luigi
Am Mon, 1 Jul 2019 00:04:10 +0200 schrieb luigi scarso:
here it seems ok # luatex --credits
Development id: 7169
I still have id 7168, but this clearly don't work correctly (no ToUnicode-entries for fonts using harf-mode), even if I remove all my local stuff. And from Khaled's remark it is clear that it is due to the missing callback. I will wait for updates of the binaries and then check again. -- Ulrike Fischer http://www.troubleshooting-tex.de/
On Sun, Jun 30, 2019 at 11:09 PM Khaled Hosny
On Sun, Jun 30, 2019 at 12:34 AM Ulrike Fischer
wrote: With harftex or an older luatex I get:
1 beginbfchar <0052> <0031> endbfchar
By older luatex I assume luatex with non-harf mode?
What's going on here?
The Lua code for harf mode uses a new callback in HarfTeX to set the glyphs tounicode values
of course if it's in harftexdir only , then it's not in luatex. I update only luaharfbuzz. -- luigi
Am Mon, 1 Jul 2019 00:19:26 +0200 schrieb Khaled Hosny:
\font\test={texgyreheros:mode=harf;} abcäüö
You are defining the font but not actually using it, so what you are seeing is the default font.
Ah yes ;-). That explains the difference between harf code in the format and in the document: only the first affect actually the default fonts. -- Ulrike Fischer http://www.troubleshooting-tex.de/
participants (3)
-
Khaled Hosny
-
luigi scarso
-
Ulrike Fischer