summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorElie Roux <elie.roux@telecom-bretagne.eu>2009-09-08 21:50:22 +0300
committerElie Roux <elie.roux@telecom-bretagne.eu>2009-09-08 21:50:22 +0300
commit9e4beeabe84e0a34f4afc545a5f591fed292bc32 (patch)
tree76c3c1082357598078f0663e2dc74cd304d4e736
parent2c62fc4c7df9005e289d59d51d7f7ee5f143b757 (diff)
downloadluaotfload-9e4beeabe84e0a34f4afc545a5f591fed292bc32.tar.gz
fixing a bug on vf files appeared with the last commit
-rw-r--r--luaotfload.dtx17
1 files changed, 16 insertions, 1 deletions
diff --git a/luaotfload.dtx b/luaotfload.dtx
index 5d9d12d..3144cb2 100644
--- a/luaotfload.dtx
+++ b/luaotfload.dtx
@@ -420,6 +420,21 @@ fonts.enc.known = {}
% \end{macrocode}
%
+% We have to register a function in the |find_vf_file| callback in order to make everything work.
+%
+% \begin{macrocode}
+
+function luaotfload.find_vf_file(name)
+ name = file.removesuffix(file.basename(name))
+ local result = kpse.find_file(name, "vf") or ""
+ if result == "" then
+ result = kpse.find_file(name, "ovf") or ""
+ end
+ return result
+end
+
+% \end{macrocode}
+%
% Finally two functions
%
% \begin{macrocode}
@@ -429,7 +444,7 @@ function luaotfload.register_callbacks()
callback.add('hpack_filter', nodes.simple_font_handler, 'luaotfload.hpack_filter')
callback.reset('define_font')
callback.add('define_font', fonts.define.read, 'luaotfload.define_font', 1)
- callback.add('find_vf_file', fonts.vf.find, 'luaotfload.find_vf_file')
+ callback.add('find_vf_file', luaotfload.find_vf_file, 'luaotfload.find_vf_file')
end
function luaotfload.unregister_callbacks()