summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKhaled Hosny <khaledhosny@eglug.org>2010-06-07 07:41:18 +0300
committerKhaled Hosny <khaledhosny@eglug.org>2010-06-07 07:41:18 +0300
commitbc5490e6a3f47df0943c6ddbdc41723898c40156 (patch)
tree73e024e57626d608e7046dcdfcab9943fa6319ae
parent088ae4bf05db0f3eb4fa0203d3854c3f9b1c9eb6 (diff)
downloadluaotfload-bc5490e6a3f47df0943c6ddbdc41723898c40156.tar.gz
Fix XeTeX's square brackets syntax
It should force "file" not "name" lookup.
-rw-r--r--otfl-font-xtx.lua2
1 files changed, 1 insertions, 1 deletions
diff --git a/otfl-font-xtx.lua b/otfl-font-xtx.lua
index 413769d..c8bcd22 100644
--- a/otfl-font-xtx.lua
+++ b/otfl-font-xtx.lua
@@ -176,7 +176,7 @@ local spaces = lpeg.P(" ")^0
local namespec = (1-lpeg.S("/:("))^0 -- was: (1-lpeg.S("/: ("))^0
local filespec = (lpeg.R("az", "AZ") * lpeg.P(":"))^-1 * (1-lpeg.S(":("))^1
local crapspec = spaces * lpeg.P("/") * (((1-lpeg.P(":"))^0)/isstyle) * spaces
-local filename = (lpeg.P("file:")/isfile * (filespec/thename)) + (lpeg.P("[") * lpeg.P(true)/isname * (((1-lpeg.P("]"))^0)/thename) * lpeg.P("]"))
+local filename = (lpeg.P("file:")/isfile * (filespec/thename)) + (lpeg.P("[") * lpeg.P(true)/isfile * (((1-lpeg.P("]"))^0)/thename) * lpeg.P("]"))
local fontname = (lpeg.P("name:")/isname * (namespec/thename)) + lpeg.P(true)/issome * (namespec/thename)
local sometext = (lpeg.R("az","AZ","09") + lpeg.S("+-."))^1
local truevalue = lpeg.P("+") * spaces * (sometext/istrue)