summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2019-04-06 21:13:13 +0000
committerKarl Berry <karl@freefriends.org>2019-04-06 21:13:13 +0000
commit6dd274fd46387055077dd8ba34bc0439abefed88 (patch)
tree2671fc2a915f05ee7a3a3e5d13ccc5051693f415
parentfe0b87e788298b4508d2de9935559365831f8782 (diff)
luatexko (6apr19)
git-svn-id: svn://tug.org/texlive/trunk@50816 c570f23f-e606-0410-a88d-b1316a301751
-rw-r--r--Master/texmf-dist/doc/luatex/luatexko/ChangeLog6
-rw-r--r--Master/texmf-dist/doc/luatex/luatexko/README2
-rw-r--r--Master/texmf-dist/doc/luatex/luatexko/luatexko-doc.pdfbin232572 -> 232522 bytes
-rw-r--r--Master/texmf-dist/doc/luatex/luatexko/luatexko-doc.tex2
-rw-r--r--Master/texmf-dist/tex/luatex/luatexko/luatexko.lua25
-rw-r--r--Master/texmf-dist/tex/luatex/luatexko/luatexko.sty2
6 files changed, 20 insertions, 17 deletions
diff --git a/Master/texmf-dist/doc/luatex/luatexko/ChangeLog b/Master/texmf-dist/doc/luatex/luatexko/ChangeLog
index 25586c3b0a9..431557df9b3 100644
--- a/Master/texmf-dist/doc/luatex/luatexko/ChangeLog
+++ b/Master/texmf-dist/doc/luatex/luatexko/ChangeLog
@@ -1,3 +1,9 @@
+2019-04-06 Dohyun Kim <nomos at ktug org>
+
+ Version 1.24
+
+ * luatexko.lua: fix a bug regarding vertical typesetting
+
2019-03-24 Dohyun Kim <nomos at ktug org>
Version 1.23
diff --git a/Master/texmf-dist/doc/luatex/luatexko/README b/Master/texmf-dist/doc/luatex/luatexko/README
index 828e5ed1268..e043a8588d1 100644
--- a/Master/texmf-dist/doc/luatex/luatexko/README
+++ b/Master/texmf-dist/doc/luatex/luatexko/README
@@ -1,4 +1,4 @@
-LuaTeX-ko Package version 1.23 (2019/03/24)
+LuaTeX-ko Package version 1.24 (2019/04/06)
===========================================
This is a Lua(La)TeX macro package that supports typesetting Korean
diff --git a/Master/texmf-dist/doc/luatex/luatexko/luatexko-doc.pdf b/Master/texmf-dist/doc/luatex/luatexko/luatexko-doc.pdf
index 07df87b0014..3a0d874edb8 100644
--- a/Master/texmf-dist/doc/luatex/luatexko/luatexko-doc.pdf
+++ b/Master/texmf-dist/doc/luatex/luatexko/luatexko-doc.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/luatex/luatexko/luatexko-doc.tex b/Master/texmf-dist/doc/luatex/luatexko/luatexko-doc.tex
index 1685f6d28bd..0e8e708c95f 100644
--- a/Master/texmf-dist/doc/luatex/luatexko/luatexko-doc.tex
+++ b/Master/texmf-dist/doc/luatex/luatexko/luatexko-doc.tex
@@ -65,7 +65,7 @@
\author{Dohyun Kim \normalsize |<nomos at ktug org>| \and
Soojin Nam \normalsize |<jsunam at gmail com>| \and
\normalsize <\url{http://github.com/dohyunkim/luatexko}>}
-\date{Version 1.23\quad 2019/03/24}
+\date{Version 1.24\quad 2019/04/06}
\maketitle
\begin{quote}\small
diff --git a/Master/texmf-dist/tex/luatex/luatexko/luatexko.lua b/Master/texmf-dist/tex/luatex/luatexko/luatexko.lua
index ce98b315257..73acf5a4291 100644
--- a/Master/texmf-dist/tex/luatex/luatexko/luatexko.lua
+++ b/Master/texmf-dist/tex/luatex/luatexko/luatexko.lua
@@ -13,8 +13,8 @@
luatexbase.provides_module {
name = 'luatexko',
- date = '2019/03/24',
- version = '1.23',
+ date = '2019/04/06',
+ version = '1.24',
description = 'Korean linebreaking and font-switching',
author = 'Dohyun Kim, Soojin Nam',
license = 'LPPL v1.3+',
@@ -844,8 +844,8 @@ local function cjk_spacing_linebreak (head)
d_set_attribute(curr, finemathattr, 1)
cjk_insert_nodes(head,curr,0,nil,prevchar,prevfont,was_penalty)
d_unset_attribute(curr,finemathattr)
+ prevchar,prevfont,prevfine = 0,nil,nil -- treat \verb as latin character.
end
- prevchar,prevfont,prevfine = 0,nil,nil -- treat \verb as latin character.
end
curr = d_getnext(curr)
end
@@ -2048,18 +2048,16 @@ local function cjk_vertical_font (vf)
return
end
- local id = fontdefine(table.copy(vf)) -- fastcopy takes time too long.
-
- vf.type = 'virtual'
- vf.fonts = {{ id = id }}
local params = vf.parameters or {}
local shared = vf.shared or {}
local quad = params.quad or 655360
local ascender = params.ascender or quad*0.8
+ local descender = params.descender or quad*0.2
local factor = params.factor or 655.36
local xheight = params.x_height or quad/2
local goffset = xheight/2 - quad/2
local descriptions = shared.rawdata and shared.rawdata.descriptions
+ local spbp = 65536*(7227/7200)
for i,v in pairs(vf.characters) do
local dsc = descriptions[i]
local gl = v.index
@@ -2070,19 +2068,18 @@ local function cjk_vertical_font (vf)
local asc = bb4 and tsb and (bb4+tsb)*factor or ascender
local hw = v.width or quad
local offset = hw/2 + goffset
- local vh = hw > 0 and hw/2 or nil
+ local vh = hw > 0 and hw or 0
+ asc = asc/spbp; offset = offset/spbp
v.commands = {
- {'right', asc}, -- bbox4 + top_side_bearing
- {'down', offset},
- {'special', 'pdf: q 0 1 -1 0 0 0 cm'},
+ {'special', stringformat('pdf:q 0 1 -1 0 %.3f %.3f cm', asc, -offset)},
{'push'},
{'char', i},
{'pop'},
- {'special', 'pdf: Q'},
+ {'special', 'pdf:Q'},
}
v.width = vw
- v.height = vh
- v.depth = vh
+ v.height = vh*(ascender/quad)
+ v.depth = vh*(descender/quad)
v.italic = nil
end
--- vertical gpos
diff --git a/Master/texmf-dist/tex/luatex/luatexko/luatexko.sty b/Master/texmf-dist/tex/luatex/luatexko/luatexko.sty
index e229b58fbfc..a54b14ade60 100644
--- a/Master/texmf-dist/tex/luatex/luatexko/luatexko.sty
+++ b/Master/texmf-dist/tex/luatex/luatexko/luatexko.sty
@@ -23,7 +23,7 @@
\expandafter\endinput
\fi
-\ProvidesPackage{luatexko}[2019/03/24 v1.23 Typesetting Korean with LuaLaTeX]
+\ProvidesPackage{luatexko}[2019/04/06 v1.24 Typesetting Korean with LuaLaTeX]
\ifdefined\adjustspacing\else % luatex < 0.87
\let\adjustspacing\pdfadjustspacing