summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/uplatex/base/uplvers.dtx
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2016-05-09 23:41:02 +0000
committerKarl Berry <karl@freefriends.org>2016-05-09 23:41:02 +0000
commitc143a4632d967b1831be9a77ea54f6ceac5da3ec (patch)
treecb2748d331ea49b43cf691a5d819bc4a2400f921 /Master/texmf-dist/source/uplatex/base/uplvers.dtx
parent91d417296c636d06a8b3e4800715e6f87c900e46 (diff)
uplatex (9may16)
git-svn-id: svn://tug.org/texlive/trunk@40991 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/uplatex/base/uplvers.dtx')
-rw-r--r--Master/texmf-dist/source/uplatex/base/uplvers.dtx242
1 files changed, 186 insertions, 56 deletions
diff --git a/Master/texmf-dist/source/uplatex/base/uplvers.dtx b/Master/texmf-dist/source/uplatex/base/uplvers.dtx
index 4f48cc14a53..bdfe0850619 100644
--- a/Master/texmf-dist/source/uplatex/base/uplvers.dtx
+++ b/Master/texmf-dist/source/uplatex/base/uplvers.dtx
@@ -1,16 +1,20 @@
% \iffalse meta-comment
-%% File: uplvers
+%% File: uplvers.dtx
%
% pLaTeX version setting file:
% Copyright 1995-2006 ASCII Corporation.
% and modified for upLaTeX
%
-% This file is part of the upLaTeX2e system.
-% -----------------------------------------
+% Copyright (c) 2010 ASCII MEDIA WORKS
+% Copyright (c) 2016 Takuji Tanaka
+% Copyright (c) 2016 Japanese TeX Development Community
+%
+% This file is part of the upLaTeX2e system (community edition).
+% --------------------------------------------------------------
%
% \fi
%
-% \CheckSum{92}
+% \CheckSum{204}
%% \CharacterTable
%% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
%% Lower-case \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
@@ -32,9 +36,40 @@
% \StopEventually{}
%
% \iffalse
+% \changes{v1.0}{1995/05/16}{p\LaTeXe\ 用に\file{ltvers.dtx}を修正}
+% \changes{v1.0a}{1995/08/30}{\LaTeX\ \texttt{!<1995/06/01!>}版用に修正}
+% \changes{v1.0b}{1996/01/31}{\LaTeX\ \texttt{!<1995/12/01!>}版用に修正}
+% \changes{v1.0c}{1997/01/11}{\LaTeX\ \texttt{!<1996/06/01!>}版用に修正}
+% \changes{v1.0d}{1997/01/23}{\LaTeX\ \texttt{!<1996/12/01!>}版用に修正}
+% \changes{v1.0e}{1997/07/02}{\LaTeX\ \texttt{!<1997/06/01!>}版用に修正}
+% \changes{v1.0f}{1998/02/17}{\LaTeX\ \texttt{!<1997/12/01!>}版用に修正}
+% \changes{v1.0g}{1998/09/01}{\LaTeX\ \texttt{!<1998/06/01!>}版用に修正}
+% \changes{v1.0h}{1999/04/05}{\LaTeX\ \texttt{!<1998/12/01!>}版用に修正}
+% \changes{v1.0i}{1999/08/09}{\LaTeX\ \texttt{!<1999/06/01!>}版用に修正}
+% \changes{v1.0j}{2000/02/29}{\LaTeX\ \texttt{!<1999/12/01!>}版用に修正}
+% \changes{v1.0k}{2000/11/03}{\LaTeX\ \texttt{!<2000/06/01!>}版用に修正}
+% \changes{v1.0l}{2001/09/04}{\LaTeX\ \texttt{!<2001/06/01!>}版用に修正}
+% \changes{v1.0m}{2004/08/10}{\LaTeX\ \texttt{!<2003/12/01!>}版対応確認}
+% \changes{v1.0n}{2005/01/04}{plfonts.dtxバグ修正}
+% \changes{v1.0o}{2006/01/04}{plfonts.dtxバグ修正}
+% \changes{v1.0p}{2006/06/27}{plfonts.dtx \LaTeX\ \texttt{!<2005/12/01!>}対応}
+% \changes{v1.0q}{2006/11/10}{plfonts.dtxバグ修正}
+% \changes{v1.0q-u00}{2011/05/07}{p\LaTeX{}用からup\LaTeX{}用に修正。}
+% \changes{v1.0r}{2016/01/26}{plcore.dtx p\TeX\ (r28720)対応}
+% \changes{v1.0s}{2016/02/01}{\LaTeX\ \texttt{!<2015/01/01!>}のlatexreleaseに
+% 対応するためのコードを導入}
+% \changes{v1.0t}{2016/02/03}{\cs{plIncludeInRelease}と
+% \cs{plEndIncludeInRelease}を新設。}
+% \changes{v1.0t-u00}{2016/04/06}{p\LaTeX{}の変更に追随。}
+% \changes{v1.0u-u00}{2016/04/17}{\LaTeX\ \texttt{!<2016/03/31!>}版対応確認}
+% \changes{v1.0v-u00}{2016/05/07}{パッチファイルをロードするのをやめた。}
+% \changes{v1.0v-u00}{2016/05/07}{起動時の文字列を最新の\LaTeX{}に合わせた。}
+% \fi
+%
+% \iffalse
%<*driver>
% \fi
-\ProvidesFile{uplvers.dtx}[2011/05/07 v1.0q_u00 upLaTeX Kernel (Version Info)]
+\ProvidesFile{uplvers.dtx}[2016/05/07 v1.0v-u00 upLaTeX Kernel (Version Info)]
% \iffalse
\documentclass{jltxdoc}
\GetFileInfo{uplvers.dtx}
@@ -49,8 +84,8 @@
% \fi
%
% \section{バージョンの設定}
-% まず、このディストリビューションでのp\LaTeXe{}の日付とバージョン番号
-% を定義します。また、p\LaTeXe{}が起動されたときに表示される文字列の
+% まず、このディストリビューションでのup\LaTeXe{}の日付とバージョン番号
+% を定義します。また、up\LaTeXe{}が起動されたときに表示される文字列の
% 設定もします。
%
% \changes{v1.0}{1995/05/16}{p\LaTeXe\ 用に\file{ltvers.dtx}を修正}
@@ -67,75 +102,95 @@
% \changes{v1.0k}{2000/11/03}{\LaTeX\ \texttt{!<2000/06/01!>}版用に修正}
% \changes{v1.0l}{2001/09/04}{\LaTeX\ \texttt{!<2001/06/01!>}版用に修正}
% \changes{v1.0m}{2004/08/10}{\LaTeX\ \texttt{!<2003/12/01!>}版対応確認}
-% \changes{v1.0n}{2005/01/04}{plfonts.dtxバグ修正}
-% \changes{v1.0o}{2006/01/04}{plfonts.dtxバグ修正}
-% \changes{v1.0p}{2006/06/27}{plfonts.dtx LaTeX <2005/12/01>対応}
-% \changes{v1.0q}{2006/11/10}{plfonts.dtxバグ修正}
-% \changes{v0.0q_u00}{2011/05/07}{pLaTeX用からupLaTeX用に修正。}
+% \changes{v1.0s}{2016/02/01}{\LaTeX\ \texttt{!<2015/01/01!>}版用に修正}
+% \changes{v1.0u-u00}{2016/04/17}{\LaTeX\ \texttt{!<2016/03/31!>}版対応確認}
%
-% このバージョンのp\LaTeXe{}は、次のバージョンの\LaTeX{}\footnote{%
-% LaTeX authors: Johannes Braams, David Carlisle, Alan Jeffrey,
+% このバージョンのup\LaTeXe{}は、次のバージョンの\LaTeX{}\footnote{%
+% \LaTeX\ authors: Johannes Braams, David Carlisle, Alan Jeffrey,
% Leslie Lamport, Frank Mittelbach, Chris Rowley, Rainer Sch\"opf}を
% もとにしています。
% \begin{macrocode}
-%<2ekernel>\def\fmtname{LaTeX2e}
-%<2ekernel>\def\fmtversion{2003/12/01}
+%<*2ekernel>
+%\def\fmtname{LaTeX2e}
+%\edef\fmtversion
+%</2ekernel>
+%<latexrelease>\edef\latexreleaseversion
+%<platexrelease>\edef\p@known@latexreleaseversion
+%<*2ekernel|latexrelease|platexrelease>
+ {2016/03/31}
+%</2ekernel|latexrelease|platexrelease>
% \end{macrocode}
%
-% p\LaTeXe{}のフォーマットファイル名とバージョンです。
+% up\LaTeXe{}のフォーマットファイル名とバージョンです。
%
+% \begin{macro}{\pfmtname}
+% \begin{macro}{\pfmtversion}
% \begin{macrocode}
%<*plcore>
\def\pfmtname{pLaTeX2e}
-\def\pfmtversion{2011/05/07u00}
+\def\pfmtversion
%</plcore>
+%<platexrelease>\edef\platexreleaseversion
+%<*plcore|platexrelease>
+ {2016/05/07u00}
+%</plcore|platexrelease>
% \end{macrocode}
+% \end{macro}
+% \end{macro}
%
% \subsection{パッチファイルのロード}
%
-% 次の部分は、p\LaTeXe{}のパッチファイルをロードするためのコードです。
+% 次の部分は、up\LaTeXe{}のパッチファイルをロードするためのコードです。
% バグを修正するためのパッチを配布するかもしれません。
+%
+% パッチファイルをロードするコードはコメントアウトしました。
+% \changes{v1.0v-u00}{2016/05/07}{パッチファイルをロードするのをやめた。}
% \begin{macrocode}
%<*plfinal>
-\IfFileExists{uplpatch.ltx}
- {\typeout{************************************^^J%
- * Appliying patch file uplpatch.ltx *^^J%
- ************************************}
- \def\pfmtversion@topatch{unknown}
- \input{uplpatch.ltx}
- \ifx\pfmtversion\pfmtversion@topatch
- \ifx\ppatch@level\@undefined
- \typeout{^^J^^J^^J%
- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!^^J%
- !! Patch file `uplpatch.ltx' (for version <\pfmtversion@topatch>)^^J%
- !! is not suitable for version <\pfmtversion> of pLaTeX.^^J^^J%
- !! Please check if iniptex found an old patch file:^^J%
- !! --- if so, rename it or delete it, and redo the^^J%
- !! iniptex run.^^J%
- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!^^J}%
- \batchmode \@@end
- \fi
- \else
- \typeout{^^J^^J^^J%
- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!^^J%
- !! Patch file `uplpatch.ltx' (for version <\pfmtversion@topatch>)^^J%
- !! is not suitable for version <\pfmtversion> of pLaTeX.^^J%
- !!^^J%
- !! Please check if iniptex found an old patch file:^^J%
- !! --- if so, rename it or delete it, and redo the^^J%
- !! iniptex run.^^J%
- !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!^^J}%
- \batchmode \@@end
- \fi
- \let\pfmtversion@topatch\relax
- }{}
+%\IfFileExists{uplpatch.ltx}
+% {\typeout{************************************^^J%
+% * Appliying patch file uplpatch.ltx *^^J%
+% ************************************}
+% \def\pfmtversion@topatch{unknown}
+% \input{uplpatch.ltx}
+% \ifx\pfmtversion\pfmtversion@topatch
+% \ifx\ppatch@level\@undefined
+% \typeout{^^J^^J^^J%
+% !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!^^J%
+% !! Patch file `uplpatch.ltx' (for version <\pfmtversion@topatch>)^^J%
+% !! is not suitable for version <\pfmtversion> of upLaTeX.^^J^^J%
+% !! Please check if iniptex found an old patch file:^^J%
+% !! --- if so, rename it or delete it, and redo the^^J%
+% !! iniptex run.^^J%
+% !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!^^J}%
+% \batchmode \@@end
+% \fi
+% \else
+% \typeout{^^J^^J^^J%
+% !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!^^J%
+% !! Patch file `uplpatch.ltx' (for version <\pfmtversion@topatch>)^^J%
+% !! is not suitable for version <\pfmtversion> of upLaTeX.^^J%
+% !!^^J%
+% !! Please check if iniptex found an old patch file:^^J%
+% !! --- if so, rename it or delete it, and redo the^^J%
+% !! iniptex run.^^J%
+% !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!^^J}%
+% \batchmode \@@end
+% \fi
+% \let\pfmtversion@topatch\relax
+% }{}
% \end{macrocode}
%
% 起動時に表示される文字列です。
% \LaTeX{}にパッチがあてられている場合は、それも表示します。
+% \changes{v1.0v-u00}{2016/05/07}{起動時の文字列を最新の\LaTeX{}に合わせた。}
% \begin{macrocode}
-\ifx\patch@level\@undefined
- \ifx\ppatch@level\@undefined
+\ifx\patch@level\@undefined % fallback if undefined in LaTeX
+ \def\patch@level{0}\fi
+\ifx\ppatch@level\@undefined % fallback if undefined in upLaTeX
+ \def\ppatch@level{0}\fi
+\ifnum\patch@level=0
+ \ifnum\ppatch@level=0
\everyjob{\typeout{%
\pfmtname\space<\pfmtversion>\space
(based on \fmtname\space<\fmtversion>)}}
@@ -144,8 +199,8 @@
\pfmtname\space<\pfmtversion>+\ppatch@level\space
(based on \fmtname\space<\fmtversion>)}}
\fi
-\else
- \ifx\ppatch@level\@undefined
+\else\ifnum\patch@level>0
+ \ifnum\ppatch@level=0
\everyjob{\typeout{%
\pfmtname\space<\pfmtversion>\space
(based on \fmtname\space<\fmtversion>\space
@@ -156,7 +211,82 @@
(based on \fmtname\space<\fmtversion>\space
patch level \patch@level)}}
\fi
-\fi
+\else
+ \ifnum\ppatch@level=0
+ \everyjob{\typeout{%
+ \pfmtname\space<\pfmtversion>\space
+ (based on \fmtname\space<\fmtversion>\space
+ pre-release\patch@level)}}
+ \else
+ \everyjob{\typeout{%
+ \pfmtname\space<\pfmtversion>+\ppatch@level\space
+ (based on \fmtname\space<\fmtversion>\space
+ pre-release\patch@level)}}
+ \fi
+\fi\fi
+%</plfinal>
+% \end{macrocode}
+%
+% \subsection{latexreleaseパッケージへの対応}
+%
+% 最後に、latexreleaseパッケージへの対応です。
+% \begin{macro}{\plIncludeInRelease}
+% \changes{v1.0t}{2016/02/03}{\cs{plIncludeInRelease}と
+% \cs{plEndIncludeInRelease}を新設。}
+% \begin{macrocode}
+%<*plcore|platexrelease>
+\def\plIncludeInRelease#1{\kernel@ifnextchar[%
+ {\@plIncludeInRelease{#1}}
+ {\@plIncludeInRelease{#1}[#1]}}
+% \end{macrocode}
+%
+% \begin{macrocode}
+\def\@plIncludeInRelease#1[#2]{\@plIncludeInRele@se{#2}}
+% \end{macrocode}
+%
+% \begin{macrocode}
+\def\@plIncludeInRele@se#1#2#3{%
+ \toks@{[#1] #3}%
+ \expandafter\ifx\csname\string#2+\@currname+IIR\endcsname\relax
+ \ifnum\expandafter\@parse@version#1//00\@nil
+ >\expandafter\@parse@version\pfmtversion//00\@nil
+ \GenericInfo{}{Skipping: \the\toks@}%
+ \expandafter\expandafter\expandafter\@gobble@plIncludeInRelease
+ \else
+ \GenericInfo{}{Applying: \the\toks@}%
+ \expandafter\let\csname\string#2+\@currname+IIR\endcsname\@empty
+ \fi
+ \else
+ \GenericInfo{}{Already applied: \the\toks@}%
+ \expandafter\@gobble@plIncludeInRelease
+ \fi
+}
+% \end{macrocode}
+%
+% \begin{macrocode}
+\long\def\@gobble@plIncludeInRelease#1\plEndIncludeInRelease{}
+\let\plEndIncludeInRelease\relax
+%</plcore|platexrelease>
+% \end{macrocode}
+% \end{macro}
+%
+% \LaTeXe{}が提供するlatexreleaseパッケージが読み込まれていて、
+% かつp\LaTeXe{}が提供するplatexreleaseパッケージが読み込まれていない
+% 場合は、警告を出します。
+% \changes{v1.0s}{2016/02/01}{latexrelease利用時に警告を出すようにした}
+% \begin{macrocode}
+%<*plfinal>
+\AtBeginDocument{%
+ \@ifpackageloaded{latexrelease}{%
+ \@ifpackageloaded{platexrelease}{}{%
+ \@latex@warning@no@line{%
+ Package latexrelease is loaded.\MessageBreak
+ Some patches in pLaTeX2e core may be overwritten.\MessageBreak
+ Consider using platexrelease.\MessageBreak
+ See platex.pdf for detail}%
+ }%
+ }{}%
+}
%</plfinal>
% \end{macrocode}
%