diff options
author | Khaled Hosny <khaledhosny@eglug.org> | 2010-06-14 14:02:28 +0300 |
---|---|---|
committer | Khaled Hosny <khaledhosny@eglug.org> | 2010-06-14 16:14:44 +0300 |
commit | c0641b1563ce1b0219724e19c772bbc180e86c2a (patch) | |
tree | 8374a5aee4f561b4531fd5d4d7783fa3f65f5f67 /otfl-node-inj.lua | |
parent | 550be8c7b6ff8a0e50ac9e2f1f31d8b053b13cdf (diff) | |
download | luaotfload-c0641b1563ce1b0219724e19c772bbc180e86c2a.tar.gz |
Sync with ConTeXt beta (beta 2010.06.14)
Fixes several bugs, including math bugs.
Diffstat (limited to 'otfl-node-inj.lua')
-rw-r--r-- | otfl-node-inj.lua | 92 |
1 files changed, 28 insertions, 64 deletions
diff --git a/otfl-node-inj.lua b/otfl-node-inj.lua index 9c4612a..579a266 100644 --- a/otfl-node-inj.lua +++ b/otfl-node-inj.lua @@ -342,39 +342,21 @@ function nodes.inject_kerns(head,where,keep) -- only w can be nil, can be sped up when w == nil local rl, x, w, r2l = k[1], k[2] or 0, k[4] or 0, k[6] local wx = w - x ---~ if rl < 0 then ---~ if r2l then ---~ if wx ~= 0 then ---~ insert_node_before(head,n,newkern(wx)) ---~ end ---~ if x ~= 0 then ---~ insert_node_after (head,n,newkern(x)) ---~ end ---~ else ---~ if x ~= 0 then ---~ insert_node_before(head,n,newkern(x)) ---~ end ---~ if wx ~= 0 then ---~ insert_node_after(head,n,newkern(wx)) ---~ end ---~ end ---~ else - if r2l then - if wx ~= 0 then - insert_node_before(head,n,newkern(wx)) - end - if x ~= 0 then - insert_node_after (head,n,newkern(x)) - end - else - if x ~= 0 then - insert_node_before(head,n,newkern(x)) - end - if wx ~= 0 then - insert_node_after(head,n,newkern(wx)) - end + if r2l then + if wx ~= 0 then + insert_node_before(head,n,newkern(wx)) + end + if x ~= 0 then + insert_node_after (head,n,newkern(x)) + end + else + if x ~= 0 then + insert_node_before(head,n,newkern(x)) + end + if wx ~= 0 then + insert_node_after(head,n,newkern(wx)) end ---~ end + end end end if next(cx) then @@ -413,39 +395,21 @@ function nodes.inject_kerns(head,where,keep) -- copied from above local r2l = kk[6] local wx = w - x ---~ if rl < 0 then ---~ if r2l then ---~ if x ~= 0 then ---~ insert_node_before(head,n,newkern(x)) ---~ end ---~ if wx ~= 0 then ---~ insert_node_after(head,n,newkern(wx)) ---~ end ---~ else ---~ if wx ~= 0 then ---~ insert_node_before(head,n,newkern(wx)) ---~ end ---~ if x ~= 0 then ---~ insert_node_after (head,n,newkern(x)) ---~ end ---~ end ---~ else - if r2l then - if wx ~= 0 then - insert_node_before(head,n,newkern(wx)) - end - if x ~= 0 then - insert_node_after (head,n,newkern(x)) - end - else - if x ~= 0 then - insert_node_before(head,n,newkern(x)) - end - if wx ~= 0 then - insert_node_after(head,n,newkern(wx)) - end + if r2l then + if wx ~= 0 then + insert_node_before(head,n,newkern(wx)) + end + if x ~= 0 then + insert_node_after (head,n,newkern(x)) + end + else + if x ~= 0 then + insert_node_before(head,n,newkern(x)) end ---~ end + if wx ~= 0 then + insert_node_after(head,n,newkern(wx)) + end + end else -- simple (e.g. kernclass kerns) if x ~= 0 then |