OSDN Git Service

fix #37610
authorHironori Kitagawa <h_kitagawa2001@yahoo.co.jp>
Sun, 29 Oct 2017 08:36:01 +0000 (17:36 +0900)
committerHironori Kitagawa <h_kitagawa2001@yahoo.co.jp>
Sun, 29 Oct 2017 08:36:01 +0000 (17:36 +0900)
src/ltj-jfmglue.lua

index 1e35416..ef05a67 100644 (file)
@@ -272,12 +272,12 @@ do
 
 local traverse = node.direct.traverse
 local function check_next_ickern(lp)
-  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
+   local lx = Np.nuc
+   while lp and getid(lp) == id_kern and ( getsubtype(lp)==3 or ITALIC == get_attr_icflag(lp)) do
+     set_attr(lp, attr_icflag, IC_PROCESSED);
+     lx, lp = lp, node_next(lp)
    end
+   Np.last = lx; return lp
 end
 
 local function calc_np_pbox(lp, last)