summaryrefslogtreecommitdiff
path: root/otfl-font-nms.lua
diff options
context:
space:
mode:
authorKhaled Hosny <khaledhosny@eglug.org>2010-05-31 19:37:50 +0300
committerKhaled Hosny <khaledhosny@eglug.org>2010-05-31 19:54:23 +0300
commitf7f60c1f72bb8c9cd64372c313e05cf46a570354 (patch)
tree53a8e34c20cbb75c6f1466da35e8e875e73121a6 /otfl-font-nms.lua
parent70c20cda5b485931cb5105aa996d7b98197a2197 (diff)
downloadluaotfload-f7f60c1f72bb8c9cd64372c313e05cf46a570354.tar.gz
Handle bypassing TFM fonts properly
We now detect tfm fonts much earlier and force a file based lookup, thus bypassing |names.resolve()| completely. So, now |\font\tenrm=cmr10| is exactly the same as |\font\tenrm=file:cmr10| as long as there is a tfm/ofm file named cmr10.
Diffstat (limited to 'otfl-font-nms.lua')
-rw-r--r--otfl-font-nms.lua18
1 files changed, 0 insertions, 18 deletions
diff --git a/otfl-font-nms.lua b/otfl-font-nms.lua
index 0cad6b1..212a667 100644
--- a/otfl-font-nms.lua
+++ b/otfl-font-nms.lua
@@ -128,24 +128,6 @@ local loaded = false
local reloaded = false
function names.resolve(specification)
- local tfm = resolvers.find_file(specification.name, "tfm")
- local ext = lower(file.extname(specification.name))
-
- if tfm then
- -- is a tfm font, skip names database
- if ext == 'tfm' then
- return specification.name, false
- else
- return specification.name..'.tfm', false
- end
- elseif resolvers.find_file(specification.name, "ofm") then
- if ext == 'ofm' then
- return specification.name, false
- else
- return specification.name..'.ofm', false
- end
- end
-
local name = sanitize(specification.name)
local style = sanitize(specification.style) or "regular"