diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/luaotfload-auxiliary.lua | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/src/luaotfload-auxiliary.lua b/src/luaotfload-auxiliary.lua index 58e4c59..3d300e7 100644 --- a/src/luaotfload-auxiliary.lua +++ b/src/luaotfload-auxiliary.lua @@ -42,9 +42,14 @@ local luaotfload_callbacks = { } --- https://github.com/khaledhosny/luaotfload/issues/54 local rewrite_fontname = function (tfmdata, specification) - local format = tfmdata.properties.format + local format = tfmdata.format or tfmdata.properties.format if format ~= "type1" then - tfmdata.name = [["]] .. specification .. [["]] + if stringfind (specification, " ") then + tfmdata.name = stringformat ("%q", specification) + else + --- other specs should parse just fine + tfmdata.name = specification + end end end |