\expandafter\let\csname ifltj@in@latex\expandafter\endcsname
\csname iftrue\endcsname
\NeedsTeXFormat{LaTeX2e}
- \ProvidesPackage{luatexja-compat}[2011/04/01 v0.1]
+ \ProvidesPackage{luatexja-compat}[2013/12/22 Compatibility with pTeX]
\fi %</LaTeX>
-%% If the engine is pTeX, then load the module for it and exit.
-\edef\ltj@@tempa{\string\kansuji}
-\edef\ltj@@tempb{\meaning\kansuji}
-\ifx\ltj@@tempa\ltj@@tempb %<*pTeX>
- \let\ltj@@compat@pTeX=t
- \ifltj@in@latex %<*LaTeX>
- \RequirePackage{luatexja-compat-ptex}[2011/04/01]
- \else %<*!LaTeX>
- \input luatexja-compat-ptex.sty %
- \fi %</LaTeX>
- \ltj@compat@AtEnd
-\expandafter\endinput\fi\relax %</pTeX>
+% ltj-compat-ptex.sty is not maintained for a long time.
+% %% If the engine is pTeX, then load the module for it and exit.
+% \edef\ltj@@tempa{\string\kansuji}
+% \edef\ltj@@tempb{\meaning\kansuji}
+% \ifx\ltj@@tempa\ltj@@tempb %<*pTeX>
+% \let\ltj@@compat@pTeX=t
+% \ifltj@in@latex %<*LaTeX>
+% \RequirePackage{ltj-compat-ptex}[2012/04/21]
+% \else %<*!LaTeX>
+% \input ltj-compat-ptex.sty %
+% \fi %</LaTeX>
+% \ltj@compat@AtEnd
+% \expandafter\endinput\fi\relax %</pTeX>
% Load core module if not yet.
\ifx\luatexjacoreLoaded\@undefined
\ifltj@in@latex %<*LaTeX>
- \RequirePackage{luatexja-core}[2012/04/20]
+ \RequirePackage{luatexja-core}[2013/05/14]
\else %<*!LaTeX>
\input luatexja-core.sty %
\fi %</LaTeX>
% not yet implemented.
%%------------------
-
-\directlua{
- luatexja.load_module('jisx0208');
- luatexja.load_module('compat');
-}
+\RequireLuaTeXjaSubmodule{compat}
\def\euc{\ltj@code@conv{euc}}
\def\kuten{\ltj@code@conv{kuten}}
\ltj@code@convB\ltj@grab@num
}
\def\ltj@code@convB#1{%
- \directlua{luatexja._cc_next(\ltj@safe@num{#1}) }%
+ \directlua{luatexja._cc_next(\ltj@safe@num@or{nil}{#1}) }%
}
\def\kansuji{%
-\tracingall
\expandafter\expandafter\expandafter
\ltj@kansujiA\ltj@grab@num
}
\directlua{luatexja.compat.to_kansuji(\ltj@safe@num{#1}) }%
}
\define@key[ltj]{japaram}{kansujichar}{%
- \expandafter\ltj@@set@stack#1:{ksj}{0}{0x7FFFFFFF}}
+ \expandafter\ltj@@set@stack#1:{KSJ}{0}{0x7FFFFFFF}}
\ltjsetparameter{kansujichar={0,`〇}}
\ltjsetparameter{kansujichar={1,`一}}
\ltjsetparameter{kansujichar={7,`七}}
\ltjsetparameter{kansujichar={8,`八}}
\ltjsetparameter{kansujichar={9,`九}}
+\ltj@@decl@array@param{kansujichar}
\ifltj@in@latex
\newcommand\printglossary{\@input@{\jobname.gls}}