summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/luatex/luatexja/ltj-jfont.lua
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2015-12-14 17:21:42 +0000
committerKarl Berry <karl@freefriends.org>2015-12-14 17:21:42 +0000
commit7e7b3ad9875434c71de5f91338327a5c82193d1d (patch)
tree6242dca91601ddad0f0bd98f5e3932ab0aeb8ea2 /Master/texmf-dist/tex/luatex/luatexja/ltj-jfont.lua
parent7039986c5ad79fac13b8b725dfee4001f7f85332 (diff)
luatexja (12dec15)
git-svn-id: svn://tug.org/texlive/trunk@39105 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/luatex/luatexja/ltj-jfont.lua')
-rw-r--r--Master/texmf-dist/tex/luatex/luatexja/ltj-jfont.lua5
1 files changed, 4 insertions, 1 deletions
diff --git a/Master/texmf-dist/tex/luatex/luatexja/ltj-jfont.lua b/Master/texmf-dist/tex/luatex/luatexja/ltj-jfont.lua
index 3e4e0b1522c..cfd544c0fe3 100644
--- a/Master/texmf-dist/tex/luatex/luatexja/ltj-jfont.lua
+++ b/Master/texmf-dist/tex/luatex/luatexja/ltj-jfont.lua
@@ -325,6 +325,8 @@ do
-- extract jfm_file_name and jfm_var
-- normalize position of 'jfm=' and 'jfmvar=' keys
local function extract_metric(name)
+ local is_braced = name:match('^{(.*)}$')
+ name= is_braced or name
jfm_file_name = ''; jfm_var = ''; jfm_ksp = true
local tmp, index = name:sub(1, 5), 1
if tmp == 'file:' or tmp == 'name:' or tmp == 'psft:' then
@@ -374,7 +376,7 @@ do
else
is_vert_enabled = nil
end
- return name
+ return is_braced and ('{' .. name .. '}') or name
end
-- define_font callback
@@ -383,6 +385,7 @@ do
function luatexja.font_callback(name, size, id)
local new_name = is_def_jfont and extract_metric(name) or name
is_def_jfont = false
+ --local res = otfl_fdr(new_name, size, id)
local res = ltjr_font_callback(new_name, size, id, otfl_fdr)
luatexbase.call_callback('luatexja.define_font', res, new_name, size, id)
-- this callback processes variation selector, so we execute it always