summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/luatex/luatexja/ltj-otf.lua
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2013-03-18 22:35:48 +0000
committerKarl Berry <karl@freefriends.org>2013-03-18 22:35:48 +0000
commitd40cbce1401307dacf242faddc54bc3eb8651595 (patch)
tree35f82af7bfd3f3afc76fa87f0d255071422af922 /Master/texmf-dist/tex/luatex/luatexja/ltj-otf.lua
parent8cd524f9b8baa45ef34f1683ca7b2aa151af9098 (diff)
luatexja (18mar13)
git-svn-id: svn://tug.org/texlive/trunk@29424 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/luatex/luatexja/ltj-otf.lua')
-rw-r--r--Master/texmf-dist/tex/luatex/luatexja/ltj-otf.lua9
1 files changed, 5 insertions, 4 deletions
diff --git a/Master/texmf-dist/tex/luatex/luatexja/ltj-otf.lua b/Master/texmf-dist/tex/luatex/luatexja/ltj-otf.lua
index 71f974979e9..c16e15b8f9c 100644
--- a/Master/texmf-dist/tex/luatex/luatexja/ltj-otf.lua
+++ b/Master/texmf-dist/tex/luatex/luatexja/ltj-otf.lua
@@ -33,13 +33,14 @@ local attr_ykblshift = luatexbase.attributes['ltj@ykblshift']
local ltjf_font_metric_table = ltjf.font_metric_table
local ltjf_find_char_class = ltjf.find_char_class
+local OTF = luatexja.userid_table.OTF
-- Append a whatsit node to the list.
-- This whatsit node will be extracted to a glyph_node
function append_jglyph(char)
local p = node_new(id_whatsit,sid_user)
local v = tex.attribute[attr_curjfnt]
- p.user_id=30113; p.type=100; p.value=char
+ p.user_id=OTF; p.type=100; p.value=char
set_attr(p, attr_yablshift, tex.attribute[attr_ykblshift])
node.write(p)
end
@@ -52,7 +53,7 @@ function cid(key)
curjfnt.cidinfo.ordering ~= "Korea1" then
ltjb.package_error('luatexja-otf',
'Current Japanese font (or other CJK font) "'..curjfnt.psname..'" is not a CID-Keyed font (Adobe-Japan1 etc.)',
- 'Select a CID-Keyed font using \jfont.')
+ 'Select a CID-Keyed font using \\jfont.')
return
end
local char = curjfnt.unicodes[curjfnt.cidinfo.ordering..'.'..tostring(key)]
@@ -70,7 +71,7 @@ function extract(head)
local v
while p do
if p.id==id_whatsit then
- if p.subtype==sid_user and p.user_id==30113 then
+ if p.subtype==sid_user and p.user_id==OTF then
local g = node_new(id_glyph)
g.subtype = 0; g.char = p.value
v = has_attr(p, attr_curjfnt); g.font = v
@@ -112,7 +113,7 @@ local function cid_to_char(fmtable, fn)
local fi = fonts.ids[fn]
if fi.cidinfo and fi.cidinfo.ordering == "Japan1" then
fmtable.cid_char_type = {}
- for i, v in pairs(fmtable.size_cache.chars) do
+ for i, v in pairs(fmtable.chars) do
local j = string.match(i, "^AJ1%-([0-9]*)")
if j then
j = tonumber(fi.unicodes['Japan1.'..tostring(j)])