From 2bcd5ae4c8abdbb0c9d0f035c1c5d2e54ac688ee Mon Sep 17 00:00:00 2001 From: Hironobu Yamashita Date: Sat, 18 Aug 2018 12:36:44 +0000 Subject: pmpostdir: support new jfm spec (H. Kitagawa) git-svn-id: svn://tug.org/texlive/trunk@48431 c570f23f-e606-0410-a88d-b1316a301751 --- Build/source/texk/web2c/pmpostdir/ChangeLog | 7 ++++ Build/source/texk/web2c/pmpostdir/ptfmin.ch | 9 ++++-- .../source/texk/web2c/pmpostdir/tests/testnewu.mp | 36 +++++++++++++++++++++ .../source/texk/web2c/pmpostdir/tests/testnewu.tex | 7 ++++ .../source/texk/web2c/pmpostdir/tests/testnewu.tfm | Bin 0 -> 388 bytes 5 files changed, 56 insertions(+), 3 deletions(-) create mode 100644 Build/source/texk/web2c/pmpostdir/tests/testnewu.mp create mode 100644 Build/source/texk/web2c/pmpostdir/tests/testnewu.tex create mode 100644 Build/source/texk/web2c/pmpostdir/tests/testnewu.tfm (limited to 'Build/source/texk/web2c/pmpostdir') diff --git a/Build/source/texk/web2c/pmpostdir/ChangeLog b/Build/source/texk/web2c/pmpostdir/ChangeLog index 14728c8fff6..923987ec713 100644 --- a/Build/source/texk/web2c/pmpostdir/ChangeLog +++ b/Build/source/texk/web2c/pmpostdir/ChangeLog @@ -1,3 +1,10 @@ +2018-08-16 Hironori Kitagawa + + * ptfmin.ch: Support new JFM spec, which allows 3-byte + characters in TYPE > 0. + * tests/testnewu.{mp,tex,tfm}: Added. (File testnewu.tfm + is the same as uptexdir/tests.) + 2018-03-26 Akira Kakuto * pmpost.ch: Use UTF-8 as a default encoding also on diff --git a/Build/source/texk/web2c/pmpostdir/ptfmin.ch b/Build/source/texk/web2c/pmpostdir/ptfmin.ch index 2990dc11044..296a98a74df 100644 --- a/Build/source/texk/web2c/pmpostdir/ptfmin.ch +++ b/Build/source/texk/web2c/pmpostdir/ptfmin.ch @@ -36,6 +36,10 @@ @d read_pair(A) { (A)=tfbyte; tfget; (A)=(A)*0400+tfbyte; } +@d read_triplekanji(A) { (A)=tfbyte; + tfget; (A)=(A)*0400+tfbyte; + tfget; (A)=(A)+tfbyte*0200000; +} @d read_two(A) { (A)=tfbyte; @z @@ -91,10 +95,9 @@ tf_ignore(4*(tfm_lh-2)) ii=mp->ctype_base[n]+nt; i=mp->ctype_base[n]; while ( ifont_info[i].hh.LH=ct; - tfget; read_two(ct); - mp->font_info[i].hh.RH=ct; + tfget; mp->font_info[i].hh.RH=tfbyte; incr(i); } @z diff --git a/Build/source/texk/web2c/pmpostdir/tests/testnewu.mp b/Build/source/texk/web2c/pmpostdir/tests/testnewu.mp new file mode 100644 index 00000000000..6cc60d3b095 --- /dev/null +++ b/Build/source/texk/web2c/pmpostdir/tests/testnewu.mp @@ -0,0 +1,36 @@ +prologues:=0; +beginfig(1); + u:=.5cm; h:=0; v:=0; + picture pct; string FONT; + bboxmargin:=-0pt; + def TEST(expr a)= + pct:=(a if length(FONT)>0: infont FONT fi); + draw bbox pct shifted (h,v) withcolor (blue+green); + draw pct shifted (h,v); + h:=h+xpart(urcorner pct-ulcorner pct); v:=v+0.1u; + enddef; + + FONT:="cmr10"; + TEST("VAr10"); + h:=0; v:=v+u; FONT:="cmss10"; + TEST("VAss10"); + h:=0; v:=v+u; FONT:="uprml-h"; + TEST("あ,臼𦥑あ"); % upjisr-h: error + h:=0; v:=v+u; + TEST("あ" ); + TEST("," ); + TEST("臼" ); + TEST("𦥑" ); + TEST("あ" ); + h:=0; v:=v+u; FONT:="testnewu"; + TEST("あ,臼𦥑あ"); + h:=0; v:=v+u; + TEST("あ" ); + TEST("," ); + TEST("臼" ); + TEST("𦥑" ); + TEST("あ" ); + h:=0; v:=v+u; FONT:=""; + TEST(btex あ,臼𦥑あ etex); +endfig; +end; diff --git a/Build/source/texk/web2c/pmpostdir/tests/testnewu.tex b/Build/source/texk/web2c/pmpostdir/tests/testnewu.tex new file mode 100644 index 00000000000..5c524efecbf --- /dev/null +++ b/Build/source/texk/web2c/pmpostdir/tests/testnewu.tex @@ -0,0 +1,7 @@ +%#!uplatex +\documentclass{ujarticle} +\usepackage[dvipdfmx]{graphicx} +\begin{document} +\special{pdf:mapline testnewu UniJIS-UTF16-H ipaexg.ttf}% +\fbox{\includegraphics{testnewu.1}} +\end{document} \ No newline at end of file diff --git a/Build/source/texk/web2c/pmpostdir/tests/testnewu.tfm b/Build/source/texk/web2c/pmpostdir/tests/testnewu.tfm new file mode 100644 index 00000000000..6860278f2ca Binary files /dev/null and b/Build/source/texk/web2c/pmpostdir/tests/testnewu.tfm differ -- cgit v1.2.3