From: Philipp Gesang <Philipp.Gesang@alumni.uni-heidelberg.de>
To: ConTeXt ML <ntg-context@ntg.nl>
Subject: Re: [fontloader] cached fonts have invalid tounicode values
Date: Thu, 27 Jun 2013 22:08:51 +0200 [thread overview]
Message-ID: <20130627200851.GA12791@phlegethon> (raw)
In-Reply-To: <20130627090941.GA23357@phlegethon>
[-- Attachment #1.1: Type: text/plain, Size: 1073 bytes --]
···<date: 2013-06-27, Thursday>···<from: Philipp Gesang>···
> Hi Hans,
>
> this has been reported by Dohyun Kim [1]: the generic fontloader
> (not Context) serializes some tounicode values as Lua numbers,
> not strings. When re-reading the cache file the values lose all
> leading zeros, so they are no longer well-formed UTF-16BE.
>
> ...
> ["tounicode"]={
> [2329]="E001",
> ...
> [2384]="0063006B", -- <-- correct
> [2385]=00630068, -- <-- invalid
> [2386]=00740074,
> [2387]=00630074,
> [2388]="017F0069",
> ...
>
> Best regards,
> Philipp
>
> [1] https://github.com/lualatex/luaotfload/issues/102
> (Kim’s example works with luatex-plain if you comment out the
> ``\input luaotfload.sty`` line.)
I’ve traced it to luatex-basics-gen.lua. The cache is compiled
with the spec “{reduce = true}” which causes values to be
analyzed and “tonumber()”ed. If I unset the reduce flag, the
values turn out correct in the PDF.
Best,
Philipp
[-- Attachment #1.2: Type: application/pgp-signature, Size: 490 bytes --]
[-- Attachment #2: Type: text/plain, Size: 485 bytes --]
___________________________________________________________________________________
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://tex.aanhet.net
archive : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___________________________________________________________________________________
next prev parent reply other threads:[~2013-06-27 20:08 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-06-27 9:09 Philipp Gesang
2013-06-27 20:08 ` Philipp Gesang [this message]
2013-06-28 0:14 Akira Kakuto
2013-06-28 11:12 ` Philipp Gesang
2013-06-28 11:33 ` Hans Hagen
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20130627200851.GA12791@phlegethon \
--to=philipp.gesang@alumni.uni-heidelberg.de \
--cc=ntg-context@ntg.nl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).