From 68eaaa92a2235f4b56f45168e987146171cb1518 Mon Sep 17 00:00:00 2001 From: Philipp Gesang Date: Mon, 21 Dec 2015 21:17:36 +0100 Subject: [features] import latest changes to the feature handler --- src/luaotfload-features.lua | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) (limited to 'src/luaotfload-features.lua') diff --git a/src/luaotfload-features.lua b/src/luaotfload-features.lua index d212df5..fc04bce 100644 --- a/src/luaotfload-features.lua +++ b/src/luaotfload-features.lua @@ -1110,7 +1110,7 @@ local function ancient_addfeature (data, feature, specifications) end end -local function current_addfeature(data,feature,specifications) +local function addfeature(data,feature,specifications) local descriptions = data.descriptions local resources = data.resources local features = resources.features @@ -1158,18 +1158,17 @@ local function current_addfeature(data,feature,specifications) end local askedfeatures = specification.features or everywhere local askedsteps = specifications.steps or specification.subtables or { specification.data } or { } - local defaulttype = specification.type or "substitution" + local featuretype = normalized[specification.type or "substitution"] or "substitution" local featureflags = specification.flags or noflags local featureorder = specification.order or { feature } local added = false local nofsteps = 0 local steps = { } for i=1,#askedsteps do - local list = askedsteps[i] - local coverage = { } - local cover = coveractions[featuretype] - local format = nil - local featuretype = normalized[list.type or defaulttype] or "substitution" + local list = askedsteps[i] + local coverage = { } + local cover = coveractions[featuretype] + local format = nil if not cover then -- unknown elseif featuretype == "substitution" then @@ -1355,7 +1354,6 @@ local function current_addfeature(data,feature,specifications) end end - ---[[ end snippet from font-otc.lua ]] local tlig_order = { "tlig" } -- cgit v1.2.3