summaryrefslogtreecommitdiff
path: root/otfl-font-map.lua
diff options
context:
space:
mode:
authorKhaled Hosny <khaledhosny@eglug.org>2011-03-02 20:10:46 +0200
committerKhaled Hosny <khaledhosny@eglug.org>2011-03-02 20:57:11 +0200
commit654f5f46c8c7bc43b73ce46035f3f6c1d5e9bbe5 (patch)
tree3df613c3e05ca044d521bfc872f0d28028cb15f8 /otfl-font-map.lua
parenta0e1a5594231d9f3789c51f04fdfb24680ca2516 (diff)
downloadluaotfload-654f5f46c8c7bc43b73ce46035f3f6c1d5e9bbe5.tar.gz
Sync with ConTeXt 2011.02.25 22:03
This commit overrides all our local modification to ConTeXt file and is not tested at all.
Diffstat (limited to 'otfl-font-map.lua')
-rw-r--r--otfl-font-map.lua10
1 files changed, 5 insertions, 5 deletions
diff --git a/otfl-font-map.lua b/otfl-font-map.lua
index b206632..26b22b6 100644
--- a/otfl-font-map.lua
+++ b/otfl-font-map.lua
@@ -14,7 +14,7 @@ local utfbyte = utf.byte
local trace_loading = false trackers.register("otf.loading", function(v) trace_loading = v end)
local trace_unimapping = false trackers.register("otf.unimapping", function(v) trace_unimapping = v end)
-local report_otf = logs.new("load otf")
+local report_otf = logs.reporter("fonts","otf loading")
--[[ldx--
<p>Eventually this code will disappear because map files are kind
@@ -163,11 +163,11 @@ fonts.map.addtounicode = function(data,filename)
cidcodes = usedmap.unicodes
end
uparser = makenameparser()
- local aglmap = fonts.enc and fonts.enc.agl -- to name
+ local unicodevector = fonts.enc.agl.unicodes -- loaded runtime in context
for index, glyph in next, data.glyphs do
local name, unic = glyph.name, glyph.unicode or -1 -- play safe
if unic == -1 or unic >= private or (unic >= 0xE000 and unic <= 0xF8FF) or unic == 0xFFFE or unic == 0xFFFF then
- local unicode = (lumunic and lumunic[name]) or (aglmap and aglmap[name])
+ local unicode = (lumunic and lumunic[name]) or unicodevector[name]
if unicode then
originals[index], tounicode[index], ns = unicode, tounicode16(unicode), ns + 1
end
@@ -211,7 +211,7 @@ fonts.map.addtounicode = function(data,filename)
-- skip
elseif nplit == 1 then
local base = split[1]
- unicode = unicodes[base] or (aglmap and aglmap[base])
+ unicode = unicodes[base] or unicodevector[base]
if unicode then
if type(unicode) == "table" then
unicode = unicode[1]
@@ -222,7 +222,7 @@ fonts.map.addtounicode = function(data,filename)
local t, n = { }, 0
for l=1,nplit do
local base = split[l]
- local u = unicodes[base] or (aglmap and aglmap[base])
+ local u = unicodes[base] or unicodevector[base]
if not u then
break
elseif type(u) == "table" then