Skip to content

Commit

Permalink
Merge branch 'uptex_ofm' (#170)
Browse files Browse the repository at this point in the history
  • Loading branch information
t-tk committed Oct 20, 2024
2 parents 5d2f950 + d19272d commit 578771d
Show file tree
Hide file tree
Showing 101 changed files with 24,105 additions and 173 deletions.
7 changes: 6 additions & 1 deletion source/texk/dvipdfm-x/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -250,10 +250,12 @@ TESTS = xdvipdfmx.test xdvipdfm-ann.test xdvipdfm-bad.test xdvipdfm-bb.test
TESTS += xdvipdfm-bkm.test xdvipdfm-psz.test xdvipdfm-ptx.test xdvipdfm-res.test
TESTS += xdvipdfm-rev.test xdvipdfm-ttc.test
TESTS += dvipdfmx-upjf.test dvipdfmx-upjf2.test dvipdfmx-upjf3.test dvipdfmx-incl.test
TESTS += dvipdfmx-lmr0.test dvipdfmx-lmr1.test
xdvipdfmx.log xdvipdfm-ann.log xdvipdfm-bad.log xdvipdfm-bb.log \
xdvipdfm-bkm.log xdvipdfm-psz.log xdvipdfm-ptx.log xdvipdfm-res.log \
xdvipdfm-rev.log xdvipdfm-ttc.log \
dvipdfmx-upjf.log dvipdfmx-upjf2.log dvipdfmx-upjf3.log dvipdfmx-incl.log: \
dvipdfmx-upjf.log dvipdfmx-upjf2.log dvipdfmx-upjf3.log dvipdfmx-incl.log \
dvipdfmx-lmr0.log dvipdfmx-lmr1.log: \
xdvipdfmx$(EXEEXT)
EXTRA_DIST = $(TESTS)
## xdvipdfmx.test
Expand Down Expand Up @@ -328,5 +330,8 @@ DISTCLEANFILES += upjf3_*.pdf
## dvipdfmx-incl.test
EXTRA_DIST += tests/multi_incl.dvi tests/multi_incl.tex tests/sue-mp.pdf
DISTCLEANFILES += multi_incl.pdf
## dvipdfmx-lmr0.test, dvipdfmx-lmr1.test
EXTRA_DIST += tests/lmr0.tex tests/lmr0-al.dvi tests/lmr0-up.dvi
DISTCLEANFILES += lmr0-*.pdf
##
EXTRA_DIST += tests/fullmap.dvi tests/fullmap.tex
12 changes: 8 additions & 4 deletions source/texk/dvipdfm-x/Makefile.in
Original file line number Diff line number Diff line change
Expand Up @@ -833,12 +833,14 @@ dist_cmapdata_DATA = data/EUC-UCS2
DISTCLEANFILES = config.force image*.pdf xbmc*.pdf annot*.pdf pic*.* \
bookm*.pdf paper*.pdf ptex*.pdf resrc*.pdf reverse.pdf \
ttc*.pdf upjf.vf upjv.vf upjf-*.ofm upjv-*.ofm upjf-*.tfm \
upjf_*.pdf upjf1_*.pdf upjf2_*.pdf upjf3_*.pdf multi_incl.pdf
upjf_*.pdf upjf1_*.pdf upjf2_*.pdf upjf3_*.pdf multi_incl.pdf \
lmr0-*.pdf
TESTS = xdvipdfmx.test xdvipdfm-ann.test xdvipdfm-bad.test \
xdvipdfm-bb.test xdvipdfm-bkm.test xdvipdfm-psz.test \
xdvipdfm-ptx.test xdvipdfm-res.test xdvipdfm-rev.test \
xdvipdfm-ttc.test dvipdfmx-upjf.test dvipdfmx-upjf2.test \
dvipdfmx-upjf3.test dvipdfmx-incl.test
dvipdfmx-upjf3.test dvipdfmx-incl.test dvipdfmx-lmr0.test \
dvipdfmx-lmr1.test
EXTRA_DIST = $(TESTS) tests/dvipdfmx.cfg tests/psfonts.map \
tests/cmr10.pfb tests/cmr10.tfm tests/image.dvi \
tests/image.tex tests/xbmc.dvi tests/xbmc.tex \
Expand Down Expand Up @@ -874,7 +876,8 @@ EXTRA_DIST = $(TESTS) tests/dvipdfmx.cfg tests/psfonts.map \
tests/upjv4_full.zvp0 tests/upjv4_full.vf tests/upjf-hu.tfm \
tests/upjf-hi.tfm tests/upjv-hu.tfm tests/upjv-hi.tfm \
tests/upjf-noto.map tests/upjf-ipa.map tests/multi_incl.dvi \
tests/multi_incl.tex tests/sue-mp.pdf tests/fullmap.dvi \
tests/multi_incl.tex tests/sue-mp.pdf tests/lmr0.tex \
tests/lmr0-al.dvi tests/lmr0-up.dvi tests/fullmap.dvi \
tests/fullmap.tex
all: config.h
$(MAKE) $(AM_MAKEFLAGS) all-am
Expand Down Expand Up @@ -2062,7 +2065,8 @@ config.force: $(ZLIB_DEPEND) $(LIBPNG_DEPEND) $(KPATHSEA_DEPEND) $(LIBPAPER_DEPE
xdvipdfmx.log xdvipdfm-ann.log xdvipdfm-bad.log xdvipdfm-bb.log \
xdvipdfm-bkm.log xdvipdfm-psz.log xdvipdfm-ptx.log xdvipdfm-res.log \
xdvipdfm-rev.log xdvipdfm-ttc.log \
dvipdfmx-upjf.log dvipdfmx-upjf2.log dvipdfmx-upjf3.log dvipdfmx-incl.log: \
dvipdfmx-upjf.log dvipdfmx-upjf2.log dvipdfmx-upjf3.log dvipdfmx-incl.log \
dvipdfmx-lmr0.log dvipdfmx-lmr1.log: \
xdvipdfmx$(EXEEXT)

# Tell versions [3.59,3.63) of GNU make to not export all variables.
Expand Down
45 changes: 45 additions & 0 deletions source/texk/dvipdfm-x/dvipdfmx-lmr0.test
Original file line number Diff line number Diff line change
@@ -0,0 +1,45 @@
#! /bin/sh -vx
# $Id$
# Copyright 2024 Japanese TeX Development Community <[email protected]>
# You may freely use, modify and/or distribute this file.

KpsDir=${KpsDir:-../kpathsea}
BinDir=${BinDir:-.}
ExeExt=${ExeExt:-}
_kpsewhich=$KpsDir/kpsewhich$ExeExt
_xdvipdfmx=$BinDir/xdvipdfmx$ExeExt

TEXMFCNF=$srcdir/../kpathsea
TFMFONTS=".;$srcdir/tests;$srcdir/data;$srcdir/../web2c/tests"
T1FONTS="$srcdir/tests;$srcdir/data;$srcdir/../web2c/tests"
TEXFONTMAPS="$srcdir/tests;$srcdir/data"
DVIPDFMXINPUTS="$srcdir/tests;$srcdir/data"
TEXPICTS=$srcdir/tests
TEXFONTS="./tmp100;$srcdir/tests;$srcdir/../web2c/tests"
SOURCE_DATE_EPOCH=1588474800
export TEXMFCNF TFMFONTS T1FONTS TEXFONTMAPS DVIPDFMXINPUTS TEXPICTS TEXFONTS SOURCE_DATE_EPOCH

failed=

test -d tmp100 || mkdir -p tmp100

rm -f ./tmp100/eu3-lmr10*.ovf ./tmp100/eu3-lmr10*.ofm

echo "*** dvipdfmx: test for lmr0-al-8bit.pdf" && echo \
&& cp $srcdir/../web2c/tests/eu3-lmr10.ovf ./tmp100/eu3-lmr10.ovf \
&& cp $srcdir/../web2c/tests/eu3-lmr10.ofm ./tmp100/eu3-lmr10.ofm \
&& $_xdvipdfmx --dvipdfmx -vv -o lmr0-al-8bit.pdf $srcdir/tests/lmr0-al.dvi \
&& echo && echo "dvipdfmx-lmr0-al-8bit tests OK" && echo \
|| failed="$failed dvipdfmx-lmr0-al-8bit"

echo "*** dvipdfmx: test for lmr0-up-8bit.pdf" && echo \
&& cp $srcdir/tests/upjf_omit.vf ./tmp100/upjf.vf \
&& $_xdvipdfmx --dvipdfmx -vv -f upjf.map -o lmr0-up-8bit.pdf $srcdir/tests/lmr0-up.dvi \
&& echo && echo "dvipdfmx-lmr0-up-8bit tests OK" && echo \
|| failed="$failed dvipdfmx-lmr0-up-8bit"


test -z "$failed" && exit 0
echo
echo "failed tests:$failed"
exit 1
69 changes: 69 additions & 0 deletions source/texk/dvipdfm-x/dvipdfmx-lmr1.test
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
#! /bin/sh -vx
# $Id$
# Copyright 2024 Japanese TeX Development Community <[email protected]>
# You may freely use, modify and/or distribute this file.

KpsDir=${KpsDir:-../kpathsea}
BinDir=${BinDir:-.}
ExeExt=${ExeExt:-}
_kpsewhich=$KpsDir/kpsewhich$ExeExt
_xdvipdfmx=$BinDir/xdvipdfmx$ExeExt

if type kpsewhich > /dev/null 2>&1; then
otfpath=".//;"`kpsewhich -show-path='opentype fonts'`
otfpath=`echo $otfpath | sed -e 's,!!,,g'`
fi

TEXMFCNF=$srcdir/../kpathsea
TFMFONTS=".;$srcdir/tests;$srcdir/data;$srcdir/../web2c/tests"
T1FONTS="$srcdir/tests;$srcdir/data;$srcdir/../web2c/tests"
TEXFONTMAPS="$srcdir/tests;$srcdir/data"
DVIPDFMXINPUTS="$srcdir/tests;$srcdir/data"
TEXPICTS=$srcdir/tests
TEXFONTS="./tmp101;$srcdir/tests;$srcdir/../web2c/tests"
SOURCE_DATE_EPOCH=1588474800
export TEXMFCNF TFMFONTS T1FONTS TEXFONTMAPS DVIPDFMXINPUTS TEXPICTS TEXFONTS SOURCE_DATE_EPOCH

if type kpsewhich > /dev/null 2>&1; then
echo $otfpath
else
otfpath=".//;"`$_kpsewhich -show-path='opentype fonts'`
echo $otfpath
fi
OPENTYPEFONTS=`$_kpsewhich "--cnf-line=OPENTYPEFONTS=$otfpath" -show-path='opentype fonts'`
export OPENTYPEFONTS
echo "OPENTYPEFONTS::" $OPENTYPEFONTS

failed=

test -d tmp101 || mkdir -p tmp101

rm -f ./tmp101/eu3-lmr10*.ovf ./tmp101/eu3-lmr10*.ofm

##### following tests require Latin Modern OpenType fonts #####

$_kpsewhich lmroman10-regular.otf || exit 77

echo "*** dvipdfmx: test for lmr0-al-ucs.pdf" && echo \
&& cp $srcdir/../web2c/tests/eu3-lmr10.ovf ./tmp101/eu3-lmr10.ovf \
&& cp $srcdir/../web2c/tests/eu3-lmr10.ofm ./tmp101/eu3-lmr10.ofm \
&& cp $srcdir/tests/upjf_omit.vf ./tmp101/upjf.vf \
&& $_xdvipdfmx --dvipdfmx -vv -f lm.map -o lmr0-al-ucs.pdf $srcdir/tests/lmr0-al.dvi \
&& echo && echo "dvipdfmx-lmr0-al-ucs tests OK" && echo \
|| failed="$failed dvipdfmx-lmr0-al-ucs"

##### following tests require HaranoAji fonts #####

$_kpsewhich HaranoAjiMincho-Regular.otf || exit 77
$_kpsewhich HaranoAjiGothic-Normal.otf || exit 77

echo "*** dvipdfmx: test for lmr0-up-ucs.pdf" && echo \
&& $_xdvipdfmx --dvipdfmx -vv -f lm.map -f upjf-hara.map -o lmr0-up-ucs.pdf $srcdir/tests/lmr0-up.dvi \
&& echo && echo "dvipdfmx-lmr0-up-ucs tests OK" && echo \
|| failed="$failed dvipdfmx-lmr0-up-ucs"


test -z "$failed" && exit 0
echo
echo "failed tests:$failed"
exit 1
9 changes: 7 additions & 2 deletions source/texk/dvipdfm-x/tests/UPJF-UTF16-H
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,10 @@ endcodespacerange
<0000> <001f> 1
endnotdefrange

7 begincidchar
10 begincidchar
<00a7> 720
<00d7> 695
<00f7> 696
<31f7> 16243
<537f> 1698
<6674> 2646
Expand All @@ -49,7 +52,9 @@ endnotdefrange
<d87edc33> 13719
endcidchar

14 begincidrange
16 begincidrange
<2018> <2019> 670
<201C> <201D> 672
<2600> <2603> 8215
<3000> <3002> 633
<3005> <3007> 657
Expand Down
1 change: 1 addition & 0 deletions source/texk/dvipdfm-x/tests/lm.map
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
eu3-lmr10_ucs unicode lmroman10-regular.otf
Binary file added source/texk/dvipdfm-x/tests/lmr0-al.dvi
Binary file not shown.
Binary file added source/texk/dvipdfm-x/tests/lmr0-up.dvi
Binary file not shown.
107 changes: 107 additions & 0 deletions source/texk/dvipdfm-x/tests/lmr0.tex
Original file line number Diff line number Diff line change
@@ -0,0 +1,107 @@
%% plain Aleph or plain upTeX
% You may freely use, modify and/or distribute this file.
%
\parindent=0pt

\font\eulmr=eu3-lmr10
\font\eclmr=ec-lmr10
\font\lylmr=texnansi-lmr10

% for aleph
\ifx\ocp\undefined\else
\ocp\ORGin=inutf8
\InputTranslation currentfile \ORGin
\fi

% for {,e}uptex
\ifx\kcatcode\undefined\else
\kcatcode"C6=14
\kcatcode"110=14
\kcatcode"152=14
\kcatcode"237=14
\kcatcode"2039=14
\kcatcode"2423=14
\kcatcode"AB=14
\fi

\catcode"C6=11 % Æ
\catcode"E6=11 % æ
\catcode"152=11 % Œ
\catcode"153=11 % œ
\catcode"131=11 % ı
\catcode"132=11 % IJ
\catcode"133=11 % ij
\catcode"237=11 % ȷ
\catcode"D0=11 % Ð
\catcode"F0=11 % ð
\catcode"110=11 % Đ
\catcode"111=11 % đ
\catcode"2018=12 %
\catcode"2019=12 %
\catcode"201C=12 %
\catcode"201D=12 %
\catcode"2039=12 %
\catcode"203A=12 %
\catcode"AB=12 % «
\catcode"BB=12 % »
\catcode"2423=12 %

\eulmr

Ææ Œœ IJij ıȷ

dh:Ðð dj:Đđ

ff fi fl ffi ffl ``'' `' !`! ?`?

‹› «» ␣

{
\eclmr

^^c6^^e6 ^^d7^^f7 ^^9c^^bc ^^19^^1a

dh:^^d0^^f0 dj:^^d0^^9e

ff fi fl ffi ffl ``'' `' !`! ?`?

^^0e^^0f ^^13^^14 %
\catcode"20=12 ^^20
}

% for {,e}uptex
\ifx\kcatcode\undefined\else
\kcatcode"86=14
\kcatcode"A5=14
\kcatcode"192=14
\fi

\catcode"A2=12 % ¢
\catcode"A5=12 % ¥
\catcode"A7=12 % §
\catcode"D7=12 % ×
\catcode"F7=12 % ÷
\catcode"192=12 % ƒ
\catcode"2020=12 %
\catcode"2021=12 %

×÷§ ¢¥ƒ †‡

{
\lylmr

^^d7^^f7^^a7 ^^a2^^a5^^83 ^^86^^87
}

\ifx\kcatcode\undefined\else
\font\upjf=upjf at 10pt
\upjf

\kcatcode"86=18
\kcatcode"A5=18
\kcatcode"2018=18

×÷§ “” ‘’
\fi

\bye
4 changes: 4 additions & 0 deletions source/texk/dvipdfm-x/tests/psfonts.map
Original file line number Diff line number Diff line change
@@ -1 +1,5 @@
cmr10 CMR10 <cmr10.pfb

ec-lmr10 LMRoman10-Regular "enclmec ReEncodeFont" <lm-ec.enc <lmr10.pfb
texnansi-lmr10 LMRoman10-Regular "enclmtexnansi ReEncodeFont" <lm-texnansi.enc <lmr10.pfb

Binary file modified source/texk/dvipdfm-x/tests/upjf1_full.vf
Binary file not shown.
51 changes: 51 additions & 0 deletions source/texk/dvipdfm-x/tests/upjf1_full.zvp0
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,57 @@
(FONTAT R 1.0)
(FONTDSIZE R 10.0)
)
(CHARACTER H A7
(CHARWD R 1.0)
(MAP
(SELECTFONT D 0)
(SETCHAR H A7)
)
)
(CHARACTER H D7
(CHARWD R 1.0)
(MAP
(SELECTFONT D 1)
(SETCHAR H D7)
)
)
(CHARACTER H F7
(CHARWD R 1.0)
(MAP
(SELECTFONT D 1)
(SETCHAR H F7)
)
)
(CHARACTER H 2018
(CHARWD R 0.5)
(MAP
(MOVERIGHT R -0.5)
(SELECTFONT D 0)
(SETCHAR H 2018)
)
)
(CHARACTER H 2019
(CHARWD R 0.5)
(MAP
(SELECTFONT D 0)
(SETCHAR H 2019)
)
)
(CHARACTER H 201C
(CHARWD R 0.5)
(MAP
(MOVERIGHT R -0.5)
(SELECTFONT D 0)
(SETCHAR H 201C)
)
)
(CHARACTER H 201D
(CHARWD R 0.5)
(MAP
(SELECTFONT D 0)
(SETCHAR H 201D)
)
)
(CHARACTER H 2600
(CHARWD R 1.0)
(MAP
Expand Down
Binary file modified source/texk/dvipdfm-x/tests/upjf1_omit.vf
Binary file not shown.
Loading

0 comments on commit 578771d

Please sign in to comment.