summaryrefslogtreecommitdiff
path: root/otfl-font-def.lua
diff options
context:
space:
mode:
authorKhaled Hosny <khaledhosny@eglug.org>2011-10-19 03:28:47 +0200
committerKhaled Hosny <khaledhosny@eglug.org>2011-10-19 03:28:47 +0200
commitf2b2b467de8e4c58a19859a713694ae50afb00be (patch)
tree9320b025aa773302fc1ebe51c09f0e614914cfc7 /otfl-font-def.lua
parent2b0964ac028a724842ad37514d30c8bccbf9c354 (diff)
downloadluaotfload-f2b2b467de8e4c58a19859a713694ae50afb00be.tar.gz
Sync with ConTeXt beta 2011.10.19 00:02
Diffstat (limited to 'otfl-font-def.lua')
-rw-r--r--otfl-font-def.lua32
1 files changed, 16 insertions, 16 deletions
diff --git a/otfl-font-def.lua b/otfl-font-def.lua
index 63d3e2c..5f79170 100644
--- a/otfl-font-def.lua
+++ b/otfl-font-def.lua
@@ -248,27 +248,27 @@ features (esp in virtual fonts) so let's not do that now.</p>
specification yet.</p>
--ldx]]--
--- not in context, at least not now:
---
--- function definers.applypostprocessors(tfmdata)
--- local postprocessors = tfmdata.postprocessors
--- if postprocessors then
--- for i=1,#postprocessors do
--- local extrahash = postprocessors[i](tfmdata) -- after scaling etc
--- if type(extrahash) == "string" and extrahash ~= "" then
--- -- e.g. a reencoding needs this
--- extrahash = gsub(lower(extrahash),"[^a-z]","-")
--- tfmdata.properties.fullname = format("%s-%s",tfmdata.properties.fullname,extrahash)
--- end
--- end
--- end
--- return tfmdata
--- end
+-- very experimental:
function definers.applypostprocessors(tfmdata)
+ local postprocessors = tfmdata.postprocessors
+ if postprocessors then
+ for i=1,#postprocessors do
+ local extrahash = postprocessors[i](tfmdata) -- after scaling etc
+ if type(extrahash) == "string" and extrahash ~= "" then
+ -- e.g. a reencoding needs this
+ extrahash = gsub(lower(extrahash),"[^a-z]","-")
+ tfmdata.properties.fullname = format("%s-%s",tfmdata.properties.fullname,extrahash)
+ end
+ end
+ end
return tfmdata
end
+-- function definers.applypostprocessors(tfmdata)
+-- return tfmdata
+-- end
+
function definers.loadfont(specification)
local hash = constructors.hashinstance(specification)
local tfmdata = loadedfonts[hash] -- hashes by size !