[luatex] loading the font database -- luaotfload

Philipp Gesang phg at phi-gamma.net
Wed Jun 4 21:25:44 CEST 2014


···<date: 2014-06-04, Wednesday>···<from: Herbert Voss>···

> Am 04.06.2014 20:41, schrieb Philipp Gesang:
> 
> > 1. The function load() in the namespace fonts.names is how it’s
> >    done internally, e.g.:
> >    https://bitbucket.org/phg/lua-la-tex-tests/src/tip/pln-access-db.tex
> 
> Thanks Philipp,
> 
> that helped. However, is it possible to have an user interface
> to the fontmap, something like
> 
> local myfonttable = loadfontmap()
> 
> then a normal user, like me, can use always the same command:
> 
> for i, v in ipairs (myfonttable.mappings) do ...
> 
> That would be very helpful and I suppose not a big deal for luaotfload.

Indeed. I thought about adding something like that -- Luatex
attracts users that like to investigate the internals, so stuff
like that should be made easy. I guess there could be two
different functions:

    luaotfload.aux.read_font_index ()
    luaotfload.aux.font_index ()

The former forces “luaotfload-names.luc” to be read and returns
the contents of the table. Manipulating that table will not
affect the behavior of Luaotfload. The other function would
return a reference into the table that is actually used by
Luaotfload.

I can’t guarantee the layout of the tables or data fields though,
e.g. the contents of the entries of the .mappings array changed
quite a bit from version 2.3 to 2.4.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 490 bytes
Desc: not available
URL: <http://tug.org/pipermail/luatex/attachments/20140604/a9042d88/attachment.bin>


More information about the luatex mailing list