diff options
author | Karl Berry <karl@freefriends.org> | 2016-03-31 21:16:29 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2016-03-31 21:16:29 +0000 |
commit | 6ae83d3bdc0271cb972fd7e6c763c848e564635b (patch) | |
tree | 79f742e15cf1d655b4725e20bb753d4d344a20c9 /Master/texmf-dist/tex/luatex/luatexja/ltj-jfmglue.lua | |
parent | d8dd2c6b804770d2b5c55edc1bfb2d5786e95386 (diff) |
luatexja (31mar16)
git-svn-id: svn://tug.org/texlive/trunk@40198 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/luatex/luatexja/ltj-jfmglue.lua')
-rw-r--r-- | Master/texmf-dist/tex/luatex/luatexja/ltj-jfmglue.lua | 22 |
1 files changed, 14 insertions, 8 deletions
diff --git a/Master/texmf-dist/tex/luatex/luatexja/ltj-jfmglue.lua b/Master/texmf-dist/tex/luatex/luatexja/ltj-jfmglue.lua index a63c270e676..9a638e38928 100644 --- a/Master/texmf-dist/tex/luatex/luatexja/ltj-jfmglue.lua +++ b/Master/texmf-dist/tex/luatex/luatexja/ltj-jfmglue.lua @@ -3,7 +3,7 @@ -- luatexbase.provides_module({ name = 'luatexja.jfmglue', - date = '2015/05/03', + date = '2016/03/31', description = 'Insertion process of JFM glues and kanjiskip', }) module('luatexja.jfmglue', package.seeall) @@ -283,8 +283,8 @@ do local traverse = Dnode.traverse local function check_next_ickern(lp) - if lp and getid(lp) == id_kern and ITALIC == get_attr_icflag(lp) then - set_attr(lp, attr_icflag, IC_PROCESSED) + if lp and getid(lp) == id_kern and ( getsubtype(lp)==3 or ITALIC == get_attr_icflag(lp)) then + set_attr(lp, attr_icflag, IC_PROCESSED); Np.last = lp; return node_next(lp) else Np.last = Np.nuc; return lp @@ -318,6 +318,7 @@ end local ltjw_apply_ashift_math = ltjw.apply_ashift_math local ltjw_apply_ashift_disc = ltjw.apply_ashift_disc local min, max = math.min, math.max +local rule_subtype = (status.luatex_version>=85) and 3 or 0 local function calc_np_aux_glyph_common(lp) Np.nuc = lp Np.first= (Np.first or lp) @@ -366,7 +367,7 @@ local function calc_np_aux_glyph_common(lp) lx = node_next(node_next(lx)) elseif ls==0 then Np.last = lx - elseif (ls==1 and lai==ITALIC) then + elseif (ls==3) or (lai==ITALIC) then Np.last = lx; set_attr(lx, attr_icflag, IC_PROCESSED) else lp=lx; break @@ -378,7 +379,7 @@ local function calc_np_aux_glyph_common(lp) end local r if adj_depth>node_depth then - r = node_new(id_rule) + r = node_new(id_rule,rule_subtype) setfield(r, 'width', 0); setfield(r, 'height', 0) setfield(r, 'depth',adj_depth); setfield(r, 'dir', tex_dir) set_attr(r, attr_icflag, PROCESSED) @@ -519,7 +520,11 @@ local calc_np_auxtable = { end, } calc_np_auxtable[id_rule] = calc_np_auxtable.box_like -calc_np_auxtable[13] = calc_np_auxtable.box_like +if status.luatex_version>=85 then + calc_np_auxtable[15] = calc_np_auxtable.box_like +else + calc_np_auxtable[13] = calc_np_auxtable.box_like +end calc_np_auxtable[id_ins] = calc_np_auxtable.skip calc_np_auxtable[id_mark] = calc_np_auxtable.skip calc_np_auxtable[id_adjust] = calc_np_auxtable.skip @@ -541,7 +546,7 @@ function calc_np(last, lp) for k = 1,#Bp do Bp[k] = nil end while lp ~= last do local lpa = has_attr(lp, attr_icflag) or 0 - -- unbox 由来ノードの検出 + -- unbox 由来ノードの検出 if lpa>=PACKED then if lpa%PROCESSED_BEGIN_FLAG == BOXBDD then local lq = node_next(lp) @@ -1196,7 +1201,8 @@ function main(ahead, mode, dir) lp = calc_np(last, lp) if Np then handle_list_head(par_indented) - lp = calc_np(last,lp); while Np do + lp = calc_np(last,lp); + while Np do adjust_nq(); local pid, pm = Np.id, Np.met -- 挿入部 |