Skip to content

Commit

Permalink
platex.dtx, plcore.dtx: Improve banner adjustment.
Browse files Browse the repository at this point in the history
  • Loading branch information
aminophen committed Sep 14, 2016
1 parent 0e75665 commit f93557f
Show file tree
Hide file tree
Showing 4 changed files with 74 additions and 21 deletions.
49 changes: 46 additions & 3 deletions platex.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,14 @@
% \changes{v1.0l}{2016/06/19}{$B%Q%C%A%l%Y%k$r(B\file{plvers.dtx}$B$+$i<hF@(B}
% \changes{v1.0m}{2016/08/26}{\file{platex.cfg}$B$NFI$_9~$_$r(B
% \file{plcore.ltx}$B$+$i(B\file{platex.ltx}$B$X0\F0(B}
% \changes{v1.0n}{2016/09/14}{\LaTeX{}$B$N%P%J!<$NJ]B8$7$+$?$r2~NI(B}
% \fi
%
% \iffalse
%<*driver>
\NeedsTeXFormat{pLaTeX2e}
% \fi
\ProvidesFile{platex.dtx}[2016/08/26 v1.0m pLaTeX document file]
\ProvidesFile{platex.dtx}[2016/09/14 v1.0n pLaTeX document file]
% \iffalse
\documentclass{jltxdoc}
\usepackage{plext}
Expand Down Expand Up @@ -235,11 +236,53 @@
\let\dump\relax
% \end{macrocode}
%
% \file{latex.ltx}$B$rFI$_9~$_!"5/F0;~$N%P%J!<$rJ]B8$7$^$9!#(B
% \file{latex.ltx}$B$rFI$_9~$_!"5/F0;~$N%P%J!<$rJ]B8$7$^$9!#(B\TeX\ Live$B$NI8=`E*(B
% $B%$%s%9%H!<%k$G$O!"$3$NCf$G(BBabel$BM3Mh$N%O%$%U%M!<%7%g%s!&%Q%?!<%s(B
% \file{hyphen.cfg}$B$,FI$_9~$^$l!"$=$N%P!<%8%g%s$b4^$a$FJ]B8$5$l$k$O$:$G$9!#(B
%
%\iffalse
% 2016/05/07$B$N<BAu$G$O!"(B\file{platex.ltx}$B$N$J$+$G(B
%\begin{verbatim}
% \edef\platexBANNER{\the\everyjob}
%\end{verbatim}
% $B$H$7$F%P%J!<$rJ]B8$7!"$3$NFbMF$,(B
%\begin{verbatim}
% \typeout{LaTeX2e version}\typeout{Babel version}
%\end{verbatim}
% $B$H$$$&(B4$B$D$N%H!<%/%s$+$i@.$k$H2>Dj$7$F!"(B\file{plcore.ltx}$B$N$J$+$G(B
%\begin{verbatim}
% \def\parse@@BANNER#1#2#3#4{#2}
%\end{verbatim}
% $B$N$h$&$K%Q!<%9$7$F$$$^$7$?!#$H$3$m$,!"$3$N!V(B4$B$D$N%H!<%/%s$+$i@.$k!W$H(B
% $B$$$&2>Dj$O(BBabel$BM3Mh$N(B\file{hyphen.cfg}$B$r;HMQ$7$?>l9g$N$_@.$jN)$A!"(B
% $B$=$l0J30$NFCJL$J(B\file{hyphen.cfg}$B$d(B\file{hyphen.ltx}$B$r;HMQ$7$?>l9g$K(B
% $B%(%i!<$K$J$C$F$7$^$$$^$9!#(B
% $B$=$3$G!"?7$?$K(B2016/09/14$B$N<BAu$G$O!"(B\file{platex.ltx}$B$N$J$+$G(B
%\begin{verbatim}
% \edef\platexBANNER{\the\everyjob\noexpand\typeout{}\relax}
%\end{verbatim}
% $B$H$7$F%@%_!<$rDI2C$7$^$9!J(B|\relax|$B$O$?$@$N6h@Z$j%H!<%/%s$NLr3d!K!#(B
% $B$3$&$9$k$H!"(B|\platexBANNER|$B$NFbMF$O!"(BBabel$B$N(B\file{hyphen.cfg}$B$N$H$-(B
%\begin{verbatim}
% \typeout{LaTeX2e version}\typeout{Babel version}\typeout{}\relax
%\end{verbatim}
% $B$H$J$j!"$=$l0J30$N$H$-(B
%\begin{verbatim}
% \typeout{LaTeX2e version}\typeout{}\relax
%\end{verbatim}
% $B$H$J$k$O$:$G$9!#$3$N$h$&$K!">/$J$/$H$b(B|\typeout|$B$,(B2$B2s4^$^$l$F$$$^$9(B
% $B$N$G!"(B\file{plcore.ltx}$B$N$J$+$G(B
%\begin{verbatim}
% \def\parse@@BANNER\typeout#1\typeout#2#3\relax{#1}
%\end{verbatim}
% $B$H%Q!<%9$9$k$3$H$,$G$-$k$h$&$K$J$j$^$9!#(B
%\fi
%
% \changes{v1.0g}{2016/05/07}{$B%U%)!<%^%C%H:n@.;~$K(B\LaTeX{}$B$N%P%J!<$r0lC6J]B8(B}
% \changes{v1.0n}{2016/09/14}{\LaTeX{}$B$N%P%J!<$NJ]B8$7$+$?$r2~NI(B}
% \begin{macrocode}
\input latex.ltx
\edef\platexBANNER{\the\everyjob}% save LaTeX banner
\edef\platexBANNER{\the\everyjob\noexpand\typeout{}\relax}% save LaTeX banner
% \end{macrocode}
%
% \file{plcore.ltx}$B$rFI$_9~$_!"$3$N(Bp\LaTeX{}$B$N%P!<%8%g%s$rI=<($7$^$9!#(B
Expand Down
2 changes: 1 addition & 1 deletion platex.ltx
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
\let\orgdump\dump
\let\dump\relax
\input latex.ltx
\edef\platexBANNER{\the\everyjob}% save LaTeX banner
\edef\platexBANNER{\the\everyjob\noexpand\typeout{}\relax}% save LaTeX banner
\typeout{**************************^^J%
*^^J%
* making pLaTeX format^^J%
Expand Down
12 changes: 5 additions & 7 deletions plcore.ltx
Original file line number Diff line number Diff line change
Expand Up @@ -1010,26 +1010,24 @@
\ifx\ppatch@level\@undefined % fallback if undefined in pLaTeX
\def\ppatch@level{0}\fi
\begingroup
\def\parse@BANNER#1{\expandafter\parse@@BANNER#1}
\def\parse@@BANNER#1#2#3#4{#2}
\def\parse@@BANNER\typeout#1\typeout#2#3\relax{#1}
\edef\platexTMP{%
\ifnum\ppatch@level=0
\everyjob{\noexpand\typeout{%
\pfmtname\space<\pfmtversion>\space
(based on \parse@BANNER{\platexBANNER})}}%
(based on \expandafter\parse@@BANNER\platexBANNER)}}%
\else
\everyjob{\noexpand\typeout{%
\pfmtname\space<\pfmtversion>+\ppatch@level\space
(based on \parse@BANNER{\platexBANNER})}}%
(based on \expandafter\parse@@BANNER\platexBANNER)}}%
\fi
}
\expandafter
\endgroup \platexTMP
\begingroup
\def\parse@BANNER#1{\expandafter\parse@@BANNER#1}
\def\parse@@BANNER#1#2#3#4{#4}
\def\parse@@BANNER\typeout#1\typeout#2#3\relax{#2}
\edef\platexTMP{%
\the\everyjob\noexpand\typeout{\parse@BANNER{\platexBANNER}}%
\the\everyjob\noexpand\typeout{\expandafter\parse@@BANNER\platexBANNER}%
}
\everyjob=\expandafter{\platexTMP}%
\edef\platexTMP{%
Expand Down
32 changes: 22 additions & 10 deletions plvers.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -49,12 +49,13 @@
% \changes{v1.0y}{2016/06/27}{\file{platex.cfg}$B$NFI$_9~$_$rDI2C(B}
% \changes{v1.0z}{2016/08/26}{\file{platex.cfg}$B$NFI$_9~$_$r(B
% \file{plcore.ltx}$B$+$i(B\file{platex.ltx}$B$X0\F0(B}
% \changes{v1.1}{2016/09/14}{$B5/F0;~$N%P%J!<$r<hF@$9$k%3!<%I$r2~NI(B}
% \fi
%
% \iffalse
%<*driver>
% \fi
\ProvidesFile{plvers.dtx}[2016/08/26 v1.0z pLaTeX Kernel (Version Info)]
\ProvidesFile{plvers.dtx}[2016/09/14 v1.1 pLaTeX Kernel (Version Info)]
% \iffalse
\documentclass{jltxdoc}
\GetFileInfo{plvers.dtx}
Expand Down Expand Up @@ -173,43 +174,54 @@
%
% $B5/F0;~$KI=<($5$l$kJ8;zNs$G$9!#(B
% \LaTeX{}$B$K%Q%C%A$,$"$F$i$l$F$$$k>l9g$O!"$=$l$bI=<($7$^$9!#(B
%
%\iffalse
% $B$3$N<BAu$K$D$$$F$O(B\file{platex.dtx}$B$N%3%a%s%H$r;2>H!#(B(2016/09/14)
%\fi
%
% \changes{v1.0v}{2016/05/07}{$B5/F0;~$NJ8;zNs$r:G?7$N(B\LaTeX{}$B$K9g$o$;$?!#(B}
% \changes{v1.0w}{2016/05/12}{$B5/F0;~$NJ8;zNs$KF~$l$k(B\LaTeX{}$B$N%P!<%8%g%s$r(B
% $B85$N(B\LaTeX{}$B$N%P%J!<$+$i0z$-7Q$0$h$&$K2~NI(B}
% \changes{v1.1}{2016/09/14}{$B5/F0;~$N%P%J!<$r<hF@$9$k%3!<%I$r2~NI(B}
% \begin{macrocode}
\ifx\patch@level\@undefined % fallback if undefined in LaTeX
\def\patch@level{0}\fi
\ifx\ppatch@level\@undefined % fallback if undefined in pLaTeX
\def\ppatch@level{0}\fi
\begingroup
\def\parse@BANNER#1{\expandafter\parse@@BANNER#1}
\def\parse@@BANNER#1#2#3#4{#2}
\def\parse@@BANNER\typeout#1\typeout#2#3\relax{#1}
\edef\platexTMP{%
\ifnum\ppatch@level=0
\everyjob{\noexpand\typeout{%
\pfmtname\space<\pfmtversion>\space
(based on \parse@BANNER{\platexBANNER})}}%
(based on \expandafter\parse@@BANNER\platexBANNER)}}%
\else
\everyjob{\noexpand\typeout{%
\pfmtname\space<\pfmtversion>+\ppatch@level\space
(based on \parse@BANNER{\platexBANNER})}}%
(based on \expandafter\parse@@BANNER\platexBANNER)}}%
\fi
}
\expandafter
\endgroup \platexTMP
% \end{macrocode}
%
% p\LaTeX{}$B$O!"FH<+$N%O%$%U%M!<%7%g%s!&%Q%?!<%s$rDj5A$7$F$$$^$;$s!#(B
% $BBe$o$j$K!"(B\LaTeX{}$B$,FI$_9~$s$G$$$k(BBabel$B%Q%C%1!<%8$N$b$N$,E,MQ$5$l$^$9!#(B
% $B5/F0;~$NJ8;zNs$K$b(B\file{hyphen.cfg}$B$N%P!<%8%g%s$rH?1G$7$^$9!#(B
% \TeX\ Live$B$NI8=`E*%$%s%9%H!<%k$G$O!"Be$o$j$K(B\LaTeX{}$B$,FI$_9~$s$G$$$k(B
% Babel$B%Q%C%1!<%8$N$b$N$,E,MQ$5$l$k$O$:$G$9$+$i!"5/F0;~$NJ8;zNs$K$b(B
% \file{hyphen.cfg}$B$N%P!<%8%g%s$rH?1G$7$^$9!J(BBabel$B%Q%C%1!<%8$N(B
% \file{hyphen.cfg}$B$G$J$$>l9g$O!"2?$bI=<($5$l$:6u9T$K$J$k$O$:$G$9!K!#(B
%
%\iffalse
% $B$3$N<BAu$K$D$$$F$O(B\file{platex.dtx}$B$N%3%a%s%H$r;2>H!#(B(2016/09/14)
%\fi
%
% \changes{v1.0w}{2016/05/12}{$B5/F0;~$NJ8;zNs$KF~$l$k(BBabel$B$N%P!<%8%g%s$r(B
% $B85$N(B\LaTeX{}$B$N%P%J!<$+$i<hF@$9$k%3!<%I$r(B\file{platex.ini}$B$+$i<h$jF~$l$?(B}
% \begin{macrocode}
\begingroup
\def\parse@BANNER#1{\expandafter\parse@@BANNER#1}
\def\parse@@BANNER#1#2#3#4{#4}
\def\parse@@BANNER\typeout#1\typeout#2#3\relax{#2}
\edef\platexTMP{%
\the\everyjob\noexpand\typeout{\parse@BANNER{\platexBANNER}}%
\the\everyjob\noexpand\typeout{\expandafter\parse@@BANNER\platexBANNER}%
}
\everyjob=\expandafter{\platexTMP}%
\edef\platexTMP{%
Expand Down

0 comments on commit f93557f

Please sign in to comment.