diff options
Diffstat (limited to 'Master/texmf-dist/tex/luatex/luatexja/ltj-setwidth.lua')
-rw-r--r-- | Master/texmf-dist/tex/luatex/luatexja/ltj-setwidth.lua | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/Master/texmf-dist/tex/luatex/luatexja/ltj-setwidth.lua b/Master/texmf-dist/tex/luatex/luatexja/ltj-setwidth.lua index 38dec61d2e8..5878595f281 100644 --- a/Master/texmf-dist/tex/luatex/luatexja/ltj-setwidth.lua +++ b/Master/texmf-dist/tex/luatex/luatexja/ltj-setwidth.lua @@ -64,6 +64,7 @@ local attr_icflag = luatexbase.attributes['ltj@icflag'] local attr_vert_ori = luatexbase.attributes['ltj@vert@ori'] local ltjf_font_extra_info = ltjf.font_extra_info +local ltjs_orig_char_table = ltjs.orig_char_table local PACKED = luatexja.icflag_table.PACKED local PROCESSED = luatexja.icflag_table.PROCESSED @@ -191,8 +192,15 @@ local function capsule_glyph_tate(p, met, char_data, head, dir) local feir = ltjf_font_extra_info[pf] if met.rotation and met.vert_activated then local f = font_getfont(pf) - local r, l = met.rotation[pc], f.properties and f.properties.language - if ((r==true) or (type(r)=="table" and not r[l])) and (get_attr(p, attr_vert_ori) or 0)<=0 then + local pco = ltjs_orig_char_table[p] or pc + local r = met.rotation[pco] + local l = f.properties and f.properties.language + r = (r==true) or (type(r)=="table" and not r[l]) + if r then + r = met.rotation[pc] + r = (r==true) or (type(r)=="table" and not r[l]) + end + if r and (get_attr(p, attr_vert_ori) or 0)<=0 then return capsule_glyph_tate_rot(p, met, char_data, head, dir, 0.5*(get_ascender(pf)-get_descender(pf))) end |