summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/platex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2013-05-18 22:10:31 +0000
committerKarl Berry <karl@freefriends.org>2013-05-18 22:10:31 +0000
commit832a3a4dd14c4a5e569c22d8119ac7f689d87b15 (patch)
treebc72778a43abf25cdcfb786ee996bbc0da3cb86d /Master/texmf-dist/tex/platex
parent0ee744b73c1c0e6ead0d311c9ceeaa96c0a3ee7b (diff)
pxchfon (18may13)
git-svn-id: svn://tug.org/texlive/trunk@30556 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/platex')
-rw-r--r--Master/texmf-dist/tex/platex/pxchfon/pxchfon.sty87
1 files changed, 66 insertions, 21 deletions
diff --git a/Master/texmf-dist/tex/platex/pxchfon/pxchfon.sty b/Master/texmf-dist/tex/platex/pxchfon/pxchfon.sty
index 52938d8ff44..0afbeae93e0 100644
--- a/Master/texmf-dist/tex/platex/pxchfon/pxchfon.sty
+++ b/Master/texmf-dist/tex/platex/pxchfon/pxchfon.sty
@@ -4,7 +4,7 @@
%%%% package declaration
\NeedsTeXFormat{pLaTeX2e}
-\ProvidesPackage{pxchfon}[2013/04/20 v0.6c]
+\ProvidesPackage{pxchfon}[2013/05/18 v0.7a]
\def\pxcz@pkgname{pxchfon}
%%%% definitions
@@ -34,6 +34,7 @@
\let\pxcz@alphabet=n
\DeclareOption{alphabet}{\let\pxcz@alphabet=t}
\DeclareOption{noalphabet}{\let\pxcz@alphabet=f}
+\DeclareOption{relfont}{\let\pxcz@alphabet=r}
\newif\ifpxcz@otf \pxcz@otftrue
\DeclareOption{otf}{\pxcz@otftrue}
\DeclareOption{nootf}{\pxcz@otffalse}
@@ -82,9 +83,10 @@
\newif\ifpxcz@alpha
\if t\pxcz@alphabet \pxcz@alphatrue
\else\if f\pxcz@alphabet \pxcz@alphafalse
+\else\if r\pxcz@alphabet \pxcz@alphafalse
\else\if\pxcz@main@preset\relax \pxcz@alphatrue
\else \pxcz@alphafalse
-\fi\fi\fi
+\fi\fi\fi\fi
\ifpxcz@alpha
\IfFileExists{pxchfon0.def}{\relax}{%
\pxcz@error{Option 'alphabet' not available in Lite edition}%
@@ -93,6 +95,31 @@
\pxcz@alphafalse}
\fi
+%% \ifpxcz@rel
+\newif\ifpxcz@rel
+\if r\pxcz@alphabet \pxcz@reltrue
+\else \pxcz@relfalse
+\fi
+\ifpxcz@rel
+ \IfFileExists{pxchfon0.def}{\relax}{%
+ \pxcz@error{Option 'relfont' not available in Lite edition}%
+ {You must install full edition of PXchfon bundle.}%
+ \pxcz@relfalse}
+\fi
+
+%% \ifpxcz@alphafont
+% Whether or not alphabet fonts are used.
+\newif\ifpxcz@alphafont
+\ifpxcz@alpha \pxcz@alphafonttrue
+\else\ifpxcz@rel \pxcz@alphafonttrue
+\else \pxcz@alphafontfalse
+\fi\fi
+
+%% \ifpxcz@otf@deluxe
+\newif\ifpxcz@otf@deluxe \pxcz@otf@deluxefalse
+\@ifpackagewith{otf}{deluxe}{\pxcz@otf@deluxetrue}{}
+\@ifpackagewith{pxotf}{deluxe}{\pxcz@otf@deluxetrue}{}
+
%%------------------ user interface
%%%%<*> \setminchofont/\setgothicfont/etc.
@@ -174,8 +201,10 @@
%% \pxcz@unidirect
\let\pxcz@unidirect\@empty
+\let\pxcz@unidirect@wopt\@empty
\ifpxcz@directunicode
-\def\pxcz@unidirect#1-H{unicode}
+\def\pxcz@unidirect#116-#2{unicode}
+\def\pxcz@unidirect@wopt{ -w 1}
\fi
%% \pxcz@addtospec{<id>}
@@ -183,6 +212,7 @@
\bgroup \let\Entry\pxcz@Entry
\let\ \space \let\UniCMap\pxcz@unicmap
\let\*\pxcz@pfx@jis \let\+\pxcz@unidirect
+ \let\w\pxcz@unidirect@wopt
\let\UniJIS\pxcz@pfx@unijis
\@nameuse{pxcz@ME/#1}\egroup}
\def\pxcz@Entry#1{%
@@ -235,73 +265,73 @@
}
\pxcz@mapentry{OTF}{%
\Entry{mnl}{otf-ujml-h \+UniJIS-UTF16-H \FONTo}%
-\Entry{mnl}{otf-ujml-v UniJIS-UTF16-V \FONTo}%
+\Entry{mnl}{otf-ujml-v \+UniJIS-UTF16-V \FONTo\w}%
\Entry{mnl}{otf-cjml-h Identity-H \FONT/AJ16}%
\Entry{mnl}{otf-cjml-v Identity-V \FONT/AJ16}%
\Entry{mnl}{hminl-h H \FONTo}%
\Entry{mnl}{hminl-v V \FONTo}%
\Entry{mnl}{otf-ujmln-h \+UniJIS2004-UTF16-H \FONT}%
-\Entry{mnl}{otf-ujmln-v UniJIS2004-UTF16-V \FONT}%
+\Entry{mnl}{otf-ujmln-v \+UniJIS2004-UTF16-V \FONT\w}%
\Entry{mnl}{hminln-h H \FONT}%
\Entry{mnl}{hminln-v V \FONT}%
\Entry{mnr}{otf-ujmr-h \+UniJIS-UTF16-H \FONTo}%
-\Entry{mnr}{otf-ujmr-v UniJIS-UTF16-V \FONTo}%
+\Entry{mnr}{otf-ujmr-v \+UniJIS-UTF16-V \FONTo\w}%
\Entry{mnr}{otf-cjmr-h Identity-H \FONT/AJ16}%
\Entry{mnr}{otf-cjmr-v Identity-V \FONT/AJ16}%
\Entry{mnr}{hminr-h H \FONTo}%
\Entry{mnr}{hminr-v V \FONTo}%
\Entry{mnr}{otf-ujmrn-h \+UniJIS2004-UTF16-H \FONT}%
-\Entry{mnr}{otf-ujmrn-v UniJIS2004-UTF16-V \FONT}%
+\Entry{mnr}{otf-ujmrn-v \+UniJIS2004-UTF16-V \FONT\w}%
\Entry{mnr}{hminrn-h H \FONT}%
\Entry{mnr}{hminrn-v V \FONT}%
\Entry{mnb}{otf-ujmb-h \+UniJIS-UTF16-H \FONTo}%
-\Entry{mnb}{otf-ujmb-v UniJIS-UTF16-V \FONTo}%
+\Entry{mnb}{otf-ujmb-v \+UniJIS-UTF16-V \FONTo\w}%
\Entry{mnb}{otf-cjmb-h Identity-H \FONT/AJ16}%
\Entry{mnb}{otf-cjmb-v Identity-V \FONT/AJ16}%
\Entry{mnb}{hminb-h H \FONTo}%
\Entry{mnb}{hminb-v V \FONTo}%
\Entry{mnb}{otf-ujmbn-h \+UniJIS2004-UTF16-H \FONT}%
-\Entry{mnb}{otf-ujmbn-v UniJIS2004-UTF16-V \FONT}%
+\Entry{mnb}{otf-ujmbn-v \+UniJIS2004-UTF16-V \FONT\w}%
\Entry{mnb}{hminbn-h H \FONT}%
\Entry{mnb}{hminbn-v V \FONT}%
\Entry{gtr}{otf-ujgr-h \+UniJIS-UTF16-H \FONTo}%
-\Entry{gtr}{otf-ujgr-v UniJIS-UTF16-V \FONTo}%
+\Entry{gtr}{otf-ujgr-v \+UniJIS-UTF16-V \FONTo\w}%
\Entry{gtr}{otf-cjgr-h Identity-H \FONT/AJ16}%
\Entry{gtr}{otf-cjgr-v Identity-V \FONT/AJ16}%
\Entry{gtr}{hgothr-h H \FONTo}%
\Entry{gtr}{hgothr-v V \FONTo}%
\Entry{gtr}{otf-ujgrn-h \+UniJIS2004-UTF16-H \FONT}%
-\Entry{gtr}{otf-ujgrn-v UniJIS2004-UTF16-V \FONT}%
+\Entry{gtr}{otf-ujgrn-v \+UniJIS2004-UTF16-V \FONT\w}%
\Entry{gtr}{hgothrn-h H \FONT}%
\Entry{gtr}{hgothrn-v V \FONT}%
\Entry{gtb}{otf-ujgb-h \+UniJIS-UTF16-H \FONTo}%
-\Entry{gtb}{otf-ujgb-v UniJIS-UTF16-V \FONTo}%
+\Entry{gtb}{otf-ujgb-v \+UniJIS-UTF16-V \FONTo\w}%
\Entry{gtb}{otf-cjgb-h Identity-H \FONT/AJ16}%
\Entry{gtb}{otf-cjgb-v Identity-V \FONT/AJ16}%
\Entry{gtb}{hgothb-h H \FONTo}%
\Entry{gtb}{hgothb-v V \FONTo}%
\Entry{gtb}{otf-ujgbn-h \+UniJIS2004-UTF16-H \FONT}%
-\Entry{gtb}{otf-ujgbn-v UniJIS2004-UTF16-V \FONT}%
+\Entry{gtb}{otf-ujgbn-v \+UniJIS2004-UTF16-V \FONT\w}%
\Entry{gtb}{hgothbn-h H \FONT}%
\Entry{gtb}{hgothbn-v V \FONT}%
\Entry{gtx}{otf-ujge-h \+UniJIS-UTF16-H \FONTo}%
-\Entry{gtx}{otf-ujge-v UniJIS-UTF16-V \FONTo}%
+\Entry{gtx}{otf-ujge-v \+UniJIS-UTF16-V \FONTo\w}%
\Entry{gtx}{otf-cjge-h Identity-H \FONT/AJ16}%
\Entry{gtx}{otf-cjge-v Identity-V \FONT/AJ16}%
\Entry{gtx}{hgotheb-h H \FONTo}%
\Entry{gtx}{hgotheb-v V \FONTo}%
\Entry{gtx}{otf-ujgen-h \+UniJIS2004-UTF16-H \FONT}%
-\Entry{gtx}{otf-ujgen-v UniJIS2004-UTF16-V \FONT}%
+\Entry{gtx}{otf-ujgen-v \+UniJIS2004-UTF16-V \FONT\w}%
\Entry{gtx}{hgothebn-h H \FONT}%
\Entry{gtx}{hgothebn-v V \FONT}%
\Entry{mgr}{otf-ujmgr-h \+UniJIS-UTF16-H \FONTo}%
-\Entry{mgr}{otf-ujmgr-v UniJIS-UTF16-V \FONTo}%
+\Entry{mgr}{otf-ujmgr-v \+UniJIS-UTF16-V \FONTo\w}%
\Entry{mgr}{otf-cjmgr-h Identity-H \FONT/AJ16}%
\Entry{mgr}{otf-cjmgr-v Identity-V \FONT/AJ16}%
\Entry{mgr}{hmgothr-h H \FONTo}%
\Entry{mgr}{hmgothr-v V \FONTo}%
\Entry{mgr}{otf-ujmgrn-h \+UniJIS2004-UTF16-H \FONT}%
-\Entry{mgr}{otf-ujmgrn-v UniJIS2004-UTF16-V \FONT}%
+\Entry{mgr}{otf-ujmgrn-v \+UniJIS2004-UTF16-V \FONT\w}%
\Entry{mgr}{hmgothrn-h H \FONT}%
\Entry{mgr}{hmgothrn-v V \FONT}%
}
@@ -375,10 +405,8 @@
\let\pxcz@check@extra\@empty
\@onlypreamble\pxcz@check@extra
%
-\ifpxcz@alpha %---- <*alphabet>
-\@ifpackagewith{otf}{deluxe}{\pxcz@oktrue}{\pxcz@okfalse}
-\@ifpackagewith{pxotf}{deluxe}{\pxcz@oktrue}{}
-\ifpxcz@ok %---- <*otfdx> : otf with deluxe option
+\ifpxcz@alphafont %---- <*alphabet>
+\ifpxcz@otf@deluxe %---- <*otfdx> : otf with deluxe option
% define families cfjar & cfjas
\DeclareFontFamily{OT1}{cfjar}{}%
\pxcz@decl@shape{cfjar}{l}{cfjar-l-l0j}%
@@ -452,6 +480,13 @@
\renewcommand\encodingdefault{OT1}\normalfont
\pxcz@addtospec{ALPHA}%
\fi
+ \ifpxcz@rel
+ \pxcz@check@alldefined{mnl,mnr,mnb}%
+ \ifpxcz@ok \pxcz@decl@relfont\mcdefault{cfjar}{l}\fi
+ \pxcz@check@alldefined{gtr,gtb,gtx}%
+ \ifpxcz@ok \pxcz@decl@relfont\gtdefault{cfjas}{eb}\fi
+ \pxcz@addtospec{ALPHA}%
+ \fi
\ifpxcz@uptex \pxcz@addtospec{UPSTD}%
\else \pxcz@addtospec{STD}%
\fi
@@ -475,6 +510,16 @@
\pxcz@set@page@hook{\pxcz@spec}%
}
+%% \pxcz@decl@relfont
+\def\pxcz@decl@relfont#1#2#3{%
+ \DeclareRelationFont{\k@encoding}{#1}{m}{}{OT1}{#2}{m}{}%
+ \DeclareRelationFont{\k@encoding}{#1}{bx}{}{OT1}{#2}{bx}{}%
+ \ifpxcz@otf@deluxe
+ \DeclareRelationFont{\k@encoding}{#1}{#3}{}{OT1}{#2}{#3}{}%
+ \fi
+ \pxcz@warn{Relation font set for \k@encoding/#1}%
+}
+
%%------------------ preset japanese font mappings
%% \pxcz@declare@preset{<name>}{<text>}