summaryrefslogtreecommitdiff
path: root/luaotfload-extralibs.lua
diff options
context:
space:
mode:
Diffstat (limited to 'luaotfload-extralibs.lua')
-rw-r--r--luaotfload-extralibs.lua12
1 files changed, 9 insertions, 3 deletions
diff --git a/luaotfload-extralibs.lua b/luaotfload-extralibs.lua
index 90dbf09..3204229 100644
--- a/luaotfload-extralibs.lua
+++ b/luaotfload-extralibs.lua
@@ -176,9 +176,15 @@ if not chardata then
if k == true then
return chardata[currentfont()]
else
- local characters = identifiers[k].characters
- t[k] = characters
- return characters
+ local tfmdata = identifiers[k]
+ if not tfmdata then --- unsafe
+ tfmdata = font.fonts[k]
+ end
+ if tfmdata then
+ local characters = tfmdata.characters
+ t[k] = characters
+ return characters
+ end
end
end)
fonthashes.characters = chardata