% For eplatex or euplatex

% autodetect kanji-internal code
\ifnum\jis"2121="3000
% euplatex
\documentclass{ujarticle}
\def\pLaTeXorupLaTeX{$\epsilon$-up\LaTeX}
\else
% eplatex
\documentclass{jarticle}
\def\pLaTeXorupLaTeX{$\epsilon$-p\LaTeX}
\fi

\DeclareFontShape{OT1}{cmr}{bxrev}{n}{<-> xbmc10}{} % for right-to-left text
\DeclareTextFontCommand{\revrm}{\fontseries{bxrev}\fontshape{n}\selectfont}
\def\TeXXeT{\TeX-\revrm{\TeXXeTstate=1\beginR\TeX-\endR}}

\begin{document}

\section{\TeXXeT $B$N%F%9%H(B}
\pLaTeXorupLaTeX $B$G%F%9%H$7$F$$$^$9!#(B

\parindent0mm

``Yes, we can.'' offline enilffo shuffle elffuhs file elif

\TeXXeTstate=1\beginR
``Yes, we can.'' offline enilffo shuffle elffuhs file elif
\endR

$B%b!<%K%s%0L<!#(B $BK\EDH~F`;R!%(B $B$H$i$d(B

\TeXXeTstate=1\beginR
$B%b!<%K%s%0L<!#(B $BK\EDH~F`;R!%(B $B$H$i$d(B
\endR

\end{document}
