diff options
author | Marius <mariausol@gmail.com> | 2012-10-20 04:00:13 +0300 |
---|---|---|
committer | Marius <mariausol@gmail.com> | 2012-10-20 04:00:13 +0300 |
commit | 1fbec75954e7911bd1546a04af666fc1a3827a54 (patch) | |
tree | 16f39836f5e13bd1220a2ffc55e11912dde5bd82 /tex/context/base/font-otn.lua | |
parent | c36e19abdfd15bf6cae6fa379c6ce51f3ef5332d (diff) | |
download | context-1fbec75954e7911bd1546a04af666fc1a3827a54.tar.gz |
beta 2012.10.20 02:07
Diffstat (limited to 'tex/context/base/font-otn.lua')
-rw-r--r-- | tex/context/base/font-otn.lua | 44 |
1 files changed, 22 insertions, 22 deletions
diff --git a/tex/context/base/font-otn.lua b/tex/context/base/font-otn.lua index 2c670825a..6e465ece9 100644 --- a/tex/context/base/font-otn.lua +++ b/tex/context/base/font-otn.lua @@ -639,7 +639,7 @@ function handlers.gsub_ligature(start,kind,lookupname,ligature,sequence) if marks[startchar] then while s do local id = s.id - if id == glyph_code and s.subtype<256 and s.font == currentfont then + if id == glyph_code and s.font == currentfont and s.subtype<256 then local lg = ligature[s.char] if lg then stop = s @@ -724,12 +724,12 @@ function handlers.gpos_mark2base(start,kind,lookupname,markanchors,sequence) local markchar = start.char if marks[markchar] then local base = start.prev -- [glyph] [start=mark] - if base and base.id == glyph_code and base.subtype<256 and base.font == currentfont then + if base and base.id == glyph_code and base.font == currentfont and base.subtype<256 then local basechar = base.char if marks[basechar] then while true do base = base.prev - if base and base.id == glyph_code and base.subtype<256 and base.font == currentfont then + if base and base.id == glyph_code and base.font == currentfont and base.subtype<256 then basechar = base.char if not marks[basechar] then break @@ -785,12 +785,12 @@ function handlers.gpos_mark2ligature(start,kind,lookupname,markanchors,sequence) local markchar = start.char if marks[markchar] then local base = start.prev -- [glyph] [optional marks] [start=mark] - if base and base.id == glyph_code and base.subtype<256 and base.font == currentfont then + if base and base.id == glyph_code and base.font == currentfont and base.subtype<256 then local basechar = base.char if marks[basechar] then while true do base = base.prev - if base and base.id == glyph_code and base.subtype<256 and base.font == currentfont then + if base and base.id == glyph_code and base.font == currentfont and base.subtype<256 then basechar = base.char if not marks[basechar] then break @@ -863,7 +863,7 @@ function handlers.gpos_mark2mark(start,kind,lookupname,markanchors,sequence) end end end - if base and base.id == glyph_code and base.subtype<256 and base.font == currentfont then -- subtype test can go + if base and base.id == glyph_code and base.font == currentfont and base.subtype<256 then -- subtype test can go local basechar = base.char local baseanchors = descriptions[basechar] if baseanchors then @@ -914,7 +914,7 @@ function handlers.gpos_cursive(start,kind,lookupname,exitanchors,sequence) -- to end else local nxt = start.next - while not done and nxt and nxt.id == glyph_code and nxt.subtype<256 and nxt.font == currentfont do + while not done and nxt and nxt.id == glyph_code and nxt.font == currentfont and nxt.subtype<256 do local nextchar = nxt.char if marks[nextchar] then -- should not happen (maybe warning) @@ -978,7 +978,7 @@ function handlers.gpos_pair(start,kind,lookupname,kerns,sequence) local prev, done = start, false local factor = tfmdata.parameters.factor local lookuptype = lookuptypes[lookupname] - while snext and snext.id == glyph_code and snext.subtype<256 and snext.font == currentfont do + while snext and snext.id == glyph_code and snext.font == currentfont and snext.subtype<256 do local nextchar = snext.char local krn = kerns[nextchar] if not krn and marks[nextchar] then @@ -1370,12 +1370,12 @@ function chainprocs.gpos_mark2base(start,stop,kind,chainname,currentcontext,look end if markanchors then local base = start.prev -- [glyph] [start=mark] - if base and base.id == glyph_code and base.subtype<256 and base.font == currentfont then + if base and base.id == glyph_code and base.font == currentfont and base.subtype<256 then local basechar = base.char if marks[basechar] then while true do base = base.prev - if base and base.id == glyph_code and base.subtype<256 and base.font == currentfont then + if base and base.id == glyph_code and base.font == currentfont and base.subtype<256 then basechar = base.char if not marks[basechar] then break @@ -1434,12 +1434,12 @@ function chainprocs.gpos_mark2ligature(start,stop,kind,chainname,currentcontext, end if markanchors then local base = start.prev -- [glyph] [optional marks] [start=mark] - if base and base.id == glyph_code and base.subtype<256 and base.font == currentfont then + if base and base.id == glyph_code and base.font == currentfont and base.subtype<256 then local basechar = base.char if marks[basechar] then while true do base = base.prev - if base and base.id == glyph_code and base.subtype<256 and base.font == currentfont then + if base and base.id == glyph_code and base.font == currentfont and base.subtype<256 then basechar = base.char if not marks[basechar] then break @@ -1520,7 +1520,7 @@ function chainprocs.gpos_mark2mark(start,stop,kind,chainname,currentcontext,look end end end - if base and base.id == glyph_code and base.subtype<256 and base.font == currentfont then -- subtype test can go + if base and base.id == glyph_code and base.font == currentfont and base.subtype<256 then -- subtype test can go local basechar = base.char local baseanchors = descriptions[basechar].anchors if baseanchors then @@ -1580,7 +1580,7 @@ function chainprocs.gpos_cursive(start,stop,kind,chainname,currentcontext,lookup end else local nxt = start.next - while not done and nxt and nxt.id == glyph_code and nxt.subtype<256 and nxt.font == currentfont do + while not done and nxt and nxt.id == glyph_code and nxt.font == currentfont and nxt.subtype<256 do local nextchar = nxt.char if marks[nextchar] then -- should not happen (maybe warning) @@ -1661,7 +1661,7 @@ function chainprocs.gpos_pair(start,stop,kind,chainname,currentcontext,lookuphas local lookuptype = lookuptypes[lookupname] local prev, done = start, false local factor = tfmdata.parameters.factor - while snext and snext.id == glyph_code and snext.subtype<256 and snext.font == currentfont do + while snext and snext.id == glyph_code and snext.font == currentfont and snext.subtype<256 do local nextchar = snext.char local krn = kerns[nextchar] if not krn and marks[nextchar] then @@ -1754,7 +1754,7 @@ local function normal_handle_contextchain(start,kind,chainname,contexts,sequence -- f..l = mid string if s == 1 then -- never happens - match = current.id == glyph_code and current.subtype<256 and current.font == currentfont and seq[1][current.char] + match = current.id == glyph_code and current.font == currentfont and current.subtype<256 and seq[1][current.char] else -- maybe we need a better space check (maybe check for glue or category or combination) -- we cannot optimize for n=2 because there can be disc nodes @@ -1774,7 +1774,7 @@ local function normal_handle_contextchain(start,kind,chainname,contexts,sequence if last then local id = last.id if id == glyph_code then - if last.subtype<256 and last.font == currentfont then + if last.font == currentfont and last.subtype<256 then local char = last.char local ccd = descriptions[char] if ccd then @@ -1824,7 +1824,7 @@ local function normal_handle_contextchain(start,kind,chainname,contexts,sequence if prev then local id = prev.id if id == glyph_code then - if prev.subtype<256 and prev.font == currentfont then -- normal char + if prev.font == currentfont and prev.subtype<256 then -- normal char local char = prev.char local ccd = descriptions[char] if ccd then @@ -1885,7 +1885,7 @@ local function normal_handle_contextchain(start,kind,chainname,contexts,sequence if current then local id = current.id if id == glyph_code then - if current.subtype<256 and current.font == currentfont then -- normal char + if current.font == currentfont and current.subtype<256 then -- normal char local char = current.char local ccd = descriptions[char] if ccd then @@ -2227,7 +2227,7 @@ local function featuresprocessor(head,font,attr) while start do local id = start.id if id == glyph_code then - if start.subtype<256 and start.font == font then + if start.font == font and start.subtype<256 then local a = has_attribute(start,0) if a then a = a == attr @@ -2279,7 +2279,7 @@ local function featuresprocessor(head,font,attr) while start do local id = start.id if id == glyph_code then - if start.subtype<256 and start.font == font then + if start.font == font and start.subtype<256 then local a = has_attribute(start,0) if a then a = (a == attr) and (not attribute or has_attribute(start,state,attribute)) @@ -2352,7 +2352,7 @@ local function featuresprocessor(head,font,attr) while start do local id = start.id if id == glyph_code then - if start.subtype<256 and start.font == font then + if start.font == font and start.subtype<256 then local a = has_attribute(start,0) if a then a = (a == attr) and (not attribute or has_attribute(start,state,attribute)) |