summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/platex/base/ascmac.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/source/platex/base/ascmac.dtx')
-rw-r--r--Master/texmf-dist/source/platex/base/ascmac.dtx34
1 files changed, 31 insertions, 3 deletions
diff --git a/Master/texmf-dist/source/platex/base/ascmac.dtx b/Master/texmf-dist/source/platex/base/ascmac.dtx
index b9f06627127..84f2197343f 100644
--- a/Master/texmf-dist/source/platex/base/ascmac.dtx
+++ b/Master/texmf-dist/source/platex/base/ascmac.dtx
@@ -1,7 +1,7 @@
% \iffalse meta-comment
%
% Copyright (c) 2010 ASCII MEDIA WORKS
-% Copyright (c) 2016 Japanese TeX Development Community
+% Copyright (c) 2016-2017 Japanese TeX Development Community
%
% This file is part of the pLaTeX2e system (community edition).
% -------------------------------------------------------------
@@ -11,6 +11,9 @@
%
% \iffalse
%
+% 2017/07/22 v2.0d
+% - Check existing \Return definition and throw an error
+% if it is not compatible with ascmac.
% 2016/08/21 v2.0c
% - Support pdfLaTeX, XeLaTeX and LuaLaTeX.
% 2016/04/15 v2.0b
@@ -62,7 +65,7 @@
%</driver>
%<tascmac>\ProvidesPackage{tascmac}
%<ascmac>\ProvidesPackage{ascmac}
- [2016/08/21 v2.0c
+ [2017/07/22 v2.0d
%<driver|tascmac> ascmac package (community edition)
%<ascmac> ascmac wrapper (community edition)
]
@@ -554,9 +557,34 @@ Q \iftdir\yoko\fi
%
% \begin{macro}{\return}
% \begin{macro}{\Return}
-% $B2~9T5-9f$G$9!#(B
+% $B2~9T5-9f$G$9!#(B|\return|$B$d(B|\Return|$B$H$$$&L>>N$O$"$j$U$l$F$$$k$N$G!"(B
+% ascmac$B%Q%C%1!<%8$NDj5A$,JL$N%Q%C%1!<%8$H>WFM$9$k>l9g$,$"$j$^$9(B
+% $B!JNc!'(Balgorithm2e$B%Q%C%1!<%8!K!#(B
+% $B$=$3$G!"(B|\Return|$B$H$$$&L?Na$,4{$KDj5A$5$l$F$$$F!"$+$D(Bascgrp$B%U%)%s%H$,(B
+% $BIT;HMQ$HH=CG$5$l$k>l9g$O%(%i!<$r=P$7$^$9!#K\Mh$J$i$P(B|\return|$B$bF1MM$K(B
+% $B%A%'%C%/$7$?$$$N$G$9$,!"!V(Bokumacro$B%Q%C%1!<%8$N8e$K(Bascmac$B%Q%C%1!<%8$r(B
+% $BFI$_9~$`$H!"%(%i!<$J$7$K(Bascmac$B%Q%C%1!<%8$NDj5A$,>!$D!W$H$$$&=>Mh$N5sF0(B
+% $B$r0];}$9$k$?$a!"8=;~E@$G$O%A%'%C%/$7$^$;$s!#(B
% \begin{macrocode}
%% return-key
+\begingroup
+\def\ascmac@definable{\PackageInfo{ascmac}{Command
+ \@backslashchar\reserved@a\space already defined, but
+ compatible with\MessageBreak ascmac package, overwriting}}
+\def\ascmac@check#1{\ifx#1\@undefined\else\ascmac@parse{#1}\fi}
+\def\ascmac@parse#1{\edef\reserved@a{\expandafter\@gobble\string #1}%
+ \edef\ascmac@parse@tmp{\meaning#1 \string\@ascgrp}%
+ \expandafter\ascmac@parse@i\ascmac@parse@tmp\@nil}
+\expandafter\def\expandafter\ascmac@parse@i
+ \expandafter#\expandafter1\string\@ascgrp#2\@nil{\ifx\relax#2\relax
+ \@notdefinable\else\ascmac@definable\fi}
+%\ascmac@check{\return}% conflict with okumacro, no check
+\ascmac@check{\Return}
+\endgroup
+% \end{macrocode}
+%
+% $B2~9T5-9f$NDj5A$NK\BN$G$9!#(B
+% \begin{macrocode}
\def\return{\leavevmode\hbox{%
Q \iftdir\yoko\fi
\@ascgrp\char"20}}