summaryrefslogtreecommitdiff
path: root/src/fontloader/misc/fontloader-font-oup.lua
diff options
context:
space:
mode:
Diffstat (limited to 'src/fontloader/misc/fontloader-font-oup.lua')
-rw-r--r--src/fontloader/misc/fontloader-font-oup.lua13
1 files changed, 11 insertions, 2 deletions
diff --git a/src/fontloader/misc/fontloader-font-oup.lua b/src/fontloader/misc/fontloader-font-oup.lua
index e2d209a..571c69f 100644
--- a/src/fontloader/misc/fontloader-font-oup.lua
+++ b/src/fontloader/misc/fontloader-font-oup.lua
@@ -1302,7 +1302,8 @@ function readers.pack(data)
local r = rule.before if r then for i=1,#r do r[i] = pack_boolean(r[i]) end end
local r = rule.after if r then for i=1,#r do r[i] = pack_boolean(r[i]) end end
local r = rule.current if r then for i=1,#r do r[i] = pack_boolean(r[i]) end end
- local r = rule.replacements if r then rule.replacements = pack_flat (r) end -- can have holes
+ local r = rule.lookups if r then rule.lookups = pack_mixed (r) end
+ local r = rule.replacements if r then rule.replacements = pack_flat (r) end
end
end
end
@@ -1703,9 +1704,16 @@ function readers.unpack(data)
end
end
end
+ local lookups = rule.lookups
+ if lookups then
+ local tv = tables[lookups]
+ if tv then
+ rule.lookups = tv
+ end
+ end
local replacements = rule.replacements
if replacements then
- local tv = tables[replace]
+ local tv = tables[replacements]
if tv then
rule.replacements = tv
end
@@ -2171,6 +2179,7 @@ function readers.expand(data)
local lookups = rule.lookups or false
local subtype = nil
if lookups then
+ -- is now indexed
for k, v in next, lookups do
local lookup = sublookups[v]
if lookup then