summaryrefslogtreecommitdiff
path: root/tex/context/base/scrp-ini.lua
diff options
context:
space:
mode:
authorHans Hagen <pragma@wxs.nl>2013-03-05 16:40:00 +0100
committerHans Hagen <pragma@wxs.nl>2013-03-05 16:40:00 +0100
commit7be0d39244155e874321d77ef81078c5bd2817a9 (patch)
tree0c09404e97c825961c5ee25a31ecab080eff54e6 /tex/context/base/scrp-ini.lua
parent4eeccc18e84e817ecf7045bcb0a8d35875006f42 (diff)
downloadcontext-7be0d39244155e874321d77ef81078c5bd2817a9.tar.gz
beta 2013.03.05 16:40
Diffstat (limited to 'tex/context/base/scrp-ini.lua')
-rw-r--r--tex/context/base/scrp-ini.lua16
1 files changed, 7 insertions, 9 deletions
diff --git a/tex/context/base/scrp-ini.lua b/tex/context/base/scrp-ini.lua
index 16d33d5d7..e75a32dd2 100644
--- a/tex/context/base/scrp-ini.lua
+++ b/tex/context/base/scrp-ini.lua
@@ -18,8 +18,6 @@ local report_preprocessing = logs.reporter("scripts","preprocessing")
local utfchar = utf.char
-local set_attribute = node.set_attribute
-local has_attribute = node.has_attribute
local first_glyph = node.first_glyph or node.first_character
local traverse_id = node.traverse_id
@@ -347,7 +345,7 @@ scripts.numbertocategory = numbertocategory
local function colorize(start,stop)
for n in traverse_id(glyph_code,start) do
- local kind = numbertocategory[has_attribute(n,a_prestat)]
+ local kind = numbertocategory[n[a_prestat]]
if kind then
local ac = scriptcolors[kind]
if ac then
@@ -388,7 +386,7 @@ function scripts.preprocess(head)
while start do
local id = start.id
if id == glyph_code then
- local a = has_attribute(start,a_preproc)
+ local a = start[a_preproc]
if a then
if a ~= last_a then
if first then
@@ -426,7 +424,7 @@ function scripts.preprocess(head)
end
local h = hash[c]
if h then
- set_attribute(start,a_prestat,categorytonumber[h])
+ start[a_prestat] = categorytonumber[h]
if not first then
first, last = start, start
else
@@ -535,13 +533,13 @@ setmetatableindex(cache_nop,function(t,k) local v = { } t[k] = v return v end)
function autofontfeature.handler(head)
for n in traverse_id(glyph_code,head) do
- -- if has_attribute(n,a_preproc) then
+ -- if n[a_preproc] then
-- -- already tagged by script feature, maybe some day adapt
-- else
local char = n.char
local script = otfscripts[char]
if script then
- local dynamic = has_attribute(n,0) or 0
+ local dynamic = n[0] or 0
local font = n.font
if dynamic > 0 then
local slot = cache_yes[font]
@@ -554,7 +552,7 @@ function autofontfeature.handler(head)
end
end
if attr ~= 0 then
- set_attribute(n,0,attr)
+ n[0] = attr
-- maybe set preproc when associated
end
else
@@ -568,7 +566,7 @@ function autofontfeature.handler(head)
end
end
if attr ~= 0 then
- set_attribute(n,0,attr)
+ n[0] = attr
-- maybe set preproc when associated
end
end