From 3ebff037dbea5e7f832f1b69e71662f206b791e3 Mon Sep 17 00:00:00 2001
From: Karl Berry <karl@freefriends.org>
Date: Wed, 17 Aug 2016 21:34:51 +0000
Subject: bxjscls (17aug16)

git-svn-id: svn://tug.org/texlive/trunk@41878 c570f23f-e606-0410-a88d-b1316a301751
---
 .../tex/latex/bxjscls/bxjsja-minimal.def           | 43 +++++++++++++++++++++-
 1 file changed, 42 insertions(+), 1 deletion(-)

(limited to 'Master/texmf-dist/tex/latex/bxjscls/bxjsja-minimal.def')

diff --git a/Master/texmf-dist/tex/latex/bxjscls/bxjsja-minimal.def b/Master/texmf-dist/tex/latex/bxjscls/bxjsja-minimal.def
index 86983756bd0..7b9cd7eb544 100644
--- a/Master/texmf-dist/tex/latex/bxjscls/bxjsja-minimal.def
+++ b/Master/texmf-dist/tex/latex/bxjscls/bxjsja-minimal.def
@@ -36,7 +36,7 @@
 %%   Grave accent  \`     Left brace    \{     Vertical bar  \|
 %%   Right brace   \}     Tilde         \~}
 \ProvidesFile{bxjsja-minimal.def}
-  [2016/08/01 v1.2 BXJS document classes]
+  [2016/08/16 v1.2a BXJS document classes]
 %% このファイルは日本語文字を含みます
 \def\DeclareJaTextFontCommand#1#2{%
   \DeclareRobustCommand#1[1]{%
@@ -147,8 +147,11 @@
 \fi
 \def\bxjs@tmpa#1/#2/#3/#4/#5\relax{%
   \def\bxjs@y{#5}}
+\ifjsWithpTeXng \def\bxjs@y{10}%
+\else
 \expandafter\expandafter\expandafter\bxjs@tmpa
  \expandafter\string\the\jfont\relax
+\fi
 \@for\bxjs@x:={\jsc@JYn/mc/m/n,\jsc@JYn/gt/m/n,%
                \jsc@JTn/mc/m/n,\jsc@JTn/gt/m/n}\do
   {\expandafter\let\csname\bxjs@x/10\endcsname=\@undefined
@@ -285,6 +288,44 @@
     \bxjs@do@precisetext
   \fi
 \fi
+\ifbxjs@fancyhdr
+\@onlypreamble\bxjs@adjust@fancyhdr
+\def\bxjs@adjust@fancyhdr{%
+  \def\bxjs@tmpa{\fancyplain{}{\sl\rightmark}\strut}%
+  \def\bxjs@tmpb{\fancyplain{}{\rightmark}\strut}%
+  \ifx\f@ncyelh\bxjs@tmpa \global\let\f@ncyelh\bxjs@tmpb \fi
+  \ifx\f@ncyerh\bxjs@tmpa \global\let\f@ncyerh\bxjs@tmpb \fi
+  \ifx\f@ncyolh\bxjs@tmpa \global\let\f@ncyolh\bxjs@tmpb \fi
+  \ifx\f@ncyorh\bxjs@tmpa \global\let\f@ncyorh\bxjs@tmpb \fi
+  \def\bxjs@tmpa{\fancyplain{}{\sl\leftmark}\strut}%
+  \def\bxjs@tmpb{\fancyplain{}{\leftmark}\strut}%
+  \ifx\f@ncyelh\bxjs@tmpa \global\let\f@ncyelh\bxjs@tmpb \fi
+  \ifx\f@ncyerh\bxjs@tmpa \global\let\f@ncyerh\bxjs@tmpb \fi
+  \ifx\f@ncyolh\bxjs@tmpa \global\let\f@ncyolh\bxjs@tmpb \fi
+  \ifx\f@ncyorh\bxjs@tmpa \global\let\f@ncyorh\bxjs@tmpb \fi
+  \def\bxjs@tmpa{\rm\thepage\strut}%
+  \def\bxjs@tmpb{\thepage\strut}%
+  \ifx\f@ncyecf\bxjs@tmpa \global\let\f@ncyecf\bxjs@tmpb \fi
+  \ifx\f@ncyocf\bxjs@tmpa \global\let\f@ncyocf\bxjs@tmpb \fi
+  \ifx\fullwidth\@undefined\else \ifdim\textwidth<\fullwidth
+    \setlength{\@tempdima}{\fullwidth-\textwidth}%
+    \edef\bxjs@tmpa{\noexpand\fancyhfoffset[EL,OR]{\the\@tempdima}%
+    }\bxjs@tmpa
+  \fi\fi
+  \PackageInfo\bxjs@clsname
+   {Patch to fancyhdr is applied\@gobble}}
+\def\bxjs@pagestyle@hook{%
+  \@ifpackageloaded{fancyhdr}{%
+    \bxjs@adjust@fancyhdr
+    \global\let\bxjs@adjust@fancyhdr\relax
+  }{}}
+\let\bxjs@org@pagestyle\pagestyle
+\def\pagestyle{%
+  \bxjs@pagestyle@hook \bxjs@org@pagestyle}
+\AtBeginDocument{%
+  \bxjs@pagestyle@hook
+  \global\let\bxjs@pagestyle@hook\relax}
+\fi
 \endinput
 %%
 %% End of file `bxjsja-minimal.def'.
-- 
cgit v1.2.3

