summaryrefslogtreecommitdiff
path: root/tex/context/base/mkiv/font-odv.lua
diff options
context:
space:
mode:
Diffstat (limited to 'tex/context/base/mkiv/font-odv.lua')
-rw-r--r--tex/context/base/mkiv/font-odv.lua52
1 files changed, 26 insertions, 26 deletions
diff --git a/tex/context/base/mkiv/font-odv.lua b/tex/context/base/mkiv/font-odv.lua
index 6b9a5a9e4..345b17a52 100644
--- a/tex/context/base/mkiv/font-odv.lua
+++ b/tex/context/base/mkiv/font-odv.lua
@@ -105,7 +105,7 @@ local glyph_code = nodecodes.glyph
local handlers = otf.handlers
local methods = fonts.analyzers.methods
-local otffeatures = fonts.constructors.newfeatures("otf")
+local otffeatures = fonts.constructors.features.otf
local registerotffeature = otffeatures.register
local nuts = nodes.nuts
@@ -126,9 +126,9 @@ local setprop = nuts.setprop
local insert_node_after = nuts.insert_after
local copy_node = nuts.copy
-local free_node = nuts.free
local remove_node = nuts.remove
local flush_list = nuts.flush_list
+local flush_node = nuts.flush_node
local copyinjection = nodes.injections.copy -- KE: is this necessary? HH: probably not as positioning comes later and we rawget/set
@@ -693,7 +693,7 @@ local function deva_reorder(head,start,stop,font,attr,nbspaces)
if current == stop then
stop = getprev(stop)
head = remove_node(head,current)
- free_node(current)
+ flush_node(current)
return head, stop, nbspaces
else
nbspaces = nbspaces + 1
@@ -714,9 +714,9 @@ local function deva_reorder(head,start,stop,font,attr,nbspaces)
local tmp = next and getnext(next) or nil -- needs checking
local changestop = next == stop
local tempcurrent = copy_node(next)
- copyinjection(tempcurrent,next)
+ copyinjection(tempcurrent,next)
local nextcurrent = copy_node(current)
- copyinjection(nextcurrent,current) -- KE: necessary? HH: probably not as positioning comes later and we rawget/set
+ copyinjection(nextcurrent,current) -- KE: necessary? HH: probably not as positioning comes later and we rawget/set
setnext(tempcurrent,nextcurrent)
setprev(nextcurrent,tempcurrent)
setprop(tempcurrent,a_state,s_blwf)
@@ -725,7 +725,7 @@ local function deva_reorder(head,start,stop,font,attr,nbspaces)
if getchar(next) == getchar(tempcurrent) then
flush_list(tempcurrent)
local n = copy_node(current)
- copyinjection(n,current) -- KE: necessary? HH: probably not as positioning comes later and we rawget/set
+ copyinjection(n,current) -- KE: necessary? HH: probably not as positioning comes later and we rawget/set
setchar(current,dotted_circle)
head = insert_node_after(head, current, n)
else
@@ -735,7 +735,7 @@ local function deva_reorder(head,start,stop,font,attr,nbspaces)
if tmp then
setprev(tmp,current)
end
- free_node(freenode)
+ flush_node(freenode)
flush_list(tempcurrent)
if changestop then
stop = current
@@ -1018,7 +1018,7 @@ local function deva_reorder(head,start,stop,font,attr,nbspaces)
if getchar(base) == c_nbsp then
nbspaces = nbspaces - 1
head = remove_node(head,base)
- free_node(base)
+ flush_node(base)
end
return head, stop, nbspaces
@@ -1269,7 +1269,7 @@ function handlers.devanagari_remove_joiners(head,start,kind,lookupname,replaceme
setnext(prev,stop)
end
if head == start then
- head = stop
+ head = stop
end
flush_list(start)
return head, stop, true
@@ -1548,7 +1548,7 @@ local function dev2_reorder(head,start,stop,font,attr,nbspaces) -- maybe do a pa
if current == stop then
stop = getprev(stop)
head = remove_node(head,current)
- free_node(current)
+ flush_node(current)
return head, stop, nbspaces
else
nbspaces = nbspaces + 1
@@ -1578,7 +1578,7 @@ local function dev2_reorder(head,start,stop,font,attr,nbspaces) -- maybe do a pa
if halant[getchar(current)] then
setnext(getnext(current),tmp)
local nc = copy_node(current)
- copyinjection(nc,current)
+ copyinjection(nc,current)
setchar(current,dotted_circle)
head = insert_node_after(head,current,nc)
else
@@ -1642,17 +1642,17 @@ local function dev2_reorder(head,start,stop,font,attr,nbspaces) -- maybe do a pa
local last = getnext(stop)
while current ~= last do
local char, target, cn = locl[current] or getchar(current), nil, getnext(current)
--- not so efficient (needed for malayalam)
-local tpm = twopart_mark[char]
-if tpm then
- local extra = copy_node(current)
- copyinjection(extra,current)
- char = tpm[1]
- setchar(current,char)
- setchar(extra,tpm[2])
- head = insert_node_after(head,current,extra)
-end
---
+ -- not so efficient (needed for malayalam)
+ local tpm = twopart_mark[char]
+ if tpm then
+ local extra = copy_node(current)
+ copyinjection(extra,current)
+ char = tpm[1]
+ setchar(current,char)
+ setchar(extra,tpm[2])
+ head = insert_node_after(head,current,extra)
+ end
+ --
if not moved[current] and dependent_vowel[char] then
if pre_mark[char] then -- Before first half form in the syllable
moved[current] = true
@@ -1767,7 +1767,7 @@ end
if getchar(base) == c_nbsp then
nbspaces = nbspaces - 1
head = remove_node(head, base)
- free_node(base)
+ flush_node(base)
end
return head, stop, nbspaces
@@ -2081,7 +2081,7 @@ end
local function inject_syntax_error(head,current,mark)
local signal = copy_node(current)
- copyinjection(signal,current)
+ copyinjection(signal,current)
if mark == pre_mark then
setchar(signal,dotted_circle)
else
@@ -2127,8 +2127,8 @@ function methods.deva(head,font,attr)
end
if standalone then
-- stand alone cluster (at the start of the word only): #[Ra+H]+NBSP+[N]+[<[<ZWJ|ZWNJ>]+H+C>]+[{M}+[N]+[H]]+[SM]+[(VD)]
- local syllableend = analyze_next_chars_one(c,font,2)
- current = getnext(syllableend)
+ local syllableend = analyze_next_chars_one(c,font,2)
+ current = getnext(syllableend)
if syllablestart ~= syllableend then
head, current, nbspaces = deva_reorder(head,syllablestart,syllableend,font,attr,nbspaces)
current = getnext(current)