OSDN Git Service

#40850
authorHironori Kitagawa <h_kitagawa2001@yahoo.co.jp>
Fri, 9 Oct 2020 23:10:47 +0000 (08:10 +0900)
committerHironori Kitagawa <h_kitagawa2001@yahoo.co.jp>
Fri, 9 Oct 2020 23:10:47 +0000 (08:10 +0900)
src/ltj-otf.lua

index 56c0154..4279276 100644 (file)
@@ -191,13 +191,13 @@ ltjb.add_to_callback('pre_linebreak_filter', extract,'ltj.otf',
 -- 和文フォント読み込み時に,ind -> unicode 対応をとっておく.
 local function ind_to_uni(fmtable, fn)
    if fn<0 then return end
-   local cid = ltju.get_cidinfo(fn);
+   local cid = ltju.get_cidinfo(fn)
    local t = ltjf_font_extra_info[fn]; t = t and t.ind_to_uni
    if t and cid.ordering == "Japan1" then
       for i, v in pairs(fmtable.chars) do
          local j = string.match(i, "^AJ1%-([0-9]*)")
          if j then
-            j = t[i]
+            j = t[tonumber(j)]
             if j then
                fmtable.cid_char_type = fmtable.cid_char_type  or {}
                fmtable.cid_char_type[j] = v