summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/platex
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2023-08-18 21:27:48 +0000
committerKarl Berry <karl@freefriends.org>2023-08-18 21:27:48 +0000
commite207dd4519a04a6395a3c91142ca693d514fb3a8 (patch)
tree486bde1f316e2a236f49915b31c1990bdf3626ec /Master/texmf-dist/tex/platex
parentd744f4f2a0a3980e1c911f407adaaebbb0f7f9c2 (diff)
pxchfon (18aug23)
git-svn-id: svn://tug.org/texlive/trunk@67972 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/platex')
-rw-r--r--Master/texmf-dist/tex/platex/pxchfon/pxchfon.sty42
1 files changed, 40 insertions, 2 deletions
diff --git a/Master/texmf-dist/tex/platex/pxchfon/pxchfon.sty b/Master/texmf-dist/tex/platex/pxchfon/pxchfon.sty
index 8c94cb3ab65..8ba5fce6b38 100644
--- a/Master/texmf-dist/tex/platex/pxchfon/pxchfon.sty
+++ b/Master/texmf-dist/tex/platex/pxchfon/pxchfon.sty
@@ -10,7 +10,7 @@
%% package declaration
\NeedsTeXFormat{pLaTeX2e}
-\ProvidesPackage{pxchfon}[2023/02/22 v1.9a]
+\ProvidesPackage{pxchfon}[2023/08/18 v1.9b]
\def\pxcz@pkgname{pxchfon}
%--------------------------------------- general
@@ -208,6 +208,7 @@
\let\pxcz@legacycode\relax
\let\pxcz@expert\relax
\newif\ifpxcz@glyphid
+\newif\ifpxcz@autojfmsync
%% process options
% drivers
@@ -274,6 +275,9 @@
% (no)glyphid
\DeclareOption{glyphid}{\pxcz@glyphidtrue}
\DeclareOption{noglyphid}{\pxcz@glyphidfalse}
+% (no)autojfmsync
+\DeclareOption{autojfmsync}{\pxcz@autojfmsynctrue}
+\DeclareOption{noautojfmsync}{\pxcz@autojfmsyncfalse}
% preset spec options
\pxcz@onlypreamble@def\pxcz@all@main@preset{%
noembed,%
@@ -1557,8 +1561,9 @@
\DeclareRobustCommand*{\gid}[1]{%
\begingroup
\kanjishape{dirgid}\selectfont
- \kchar#1\relax
+ \kchar#1\pxcz@gid@jfm@sync
\endgroup}
+\let\pxcz@gid@jfm@sync\relax
\def\pxcz@hy@gid#1{?}
\g@addto@macro\pdfstringdefPreHook{%
\let\gid\pxcz@hy@gid
@@ -2073,6 +2078,39 @@
\pxcz@dump@spec@to{#2.map}}
\fi
+%--------------------------------------- JFM sync
+
+%%<+> \jfmsync
+\DeclareRobustCommand*{\jfmsync}{%
+ \pxcz@jfm@sync}
+%% \pxcz@jfm@sync
+\let\pxcz@jfm@sync\relax
+
+%%<+> \jfmsyncbox{<width>}{<text>}
+\DeclareRobustCommand*{\jfmsyncbox}[2]{%
+ \makebox[#1][l]{#2\jfmsync}}
+\g@addto@macro\pdfstringdefPreHook{%
+ \let\jfmsyncbox\@secondoftwo}
+
+\ifpxcz@enabled %---- when using dvipdfmx
+
+\def\pxcz@jfm@sync{%
+ % force to break text stream
+ \special{ps:}}
+
+\ifpxcz@autojfmsync %---- <*autojfmsync>
+% Makes \git/\CID/\UTF do automatically jfmsync
+\let\pxcz@gid@jfm@sync\pxcz@jfm@sync
+\AtBeginDocument{%
+ \ifx\put@character\@undefined\else
+ \g@addto@macro\put@character{\pxcz@jfm@sync}%
+ \fi
+ \ifx\put@character@\@undefined\else
+ \g@addto@macro\put@character@{\pxcz@jfm@sync}%
+ \fi}
+\fi %---- </autojfmsync>
+\fi %----
+
%--------------------------------------- preset japanese font mappings
%% \pxcz@declare@preset{<name>}{<text>}