X-Git-Url: http://git.osdn.jp/view?a=blobdiff_plain;f=src%2Fltjsreport.cls;h=f28caebdc95eccc538ced933462762a5feafcbbc;hb=f078ac2f7998a102c7ec765e725f2269eed9f872;hp=86766cfd888fdd6b2a26d56e98d85b51d9be8a91;hpb=cbf24f6e7335927b0d4a804dfeba4e2dd4c2a9a5;p=luatex-ja%2Fluatexja.git diff --git a/src/ltjsreport.cls b/src/ltjsreport.cls index 86766cf..f28caeb 100644 --- a/src/ltjsreport.cls +++ b/src/ltjsreport.cls @@ -38,8 +38,9 @@ %% Right brace \} Tilde \~} \NeedsTeXFormat{LaTeX2e} \ProvidesClass{ltjsreport} - [2018/06/09 ltjsclasses ] + [2019/04/06 ltjsclasses ] \def\jsc@clsname{ltjsreport} +\def\Cjascale{0.924715} \RequirePackage{luatexja} \newif\if@restonecol \newif\if@titlepage @@ -197,8 +198,6 @@ option, since LuaTeX does not support \string\mag\MessageBreak in pdf output}% &\global\@eqcnt\thr@@ \hb@xt@\z@\bgroup\hss##\egroup \tabskip\z@skip\cr }} -\DeclareOption{disablejfam}{% - \ClassWarningNoLine{\jsc@clsname}{The class option 'disablejfam' is obsolete}} \DeclareOption{draft}{\setlength\overfullrule{5pt}} \DeclareOption{final}{\setlength\overfullrule{0pt}} \newif\ifmingoth @@ -208,11 +207,11 @@ option, since LuaTeX does not support \string\mag\MessageBreak in pdf output}% \newif\ifptexjis \ptexjisfalse \DeclareOption{winjis}{% - \ClassWarningNoLine{\jsc@clsname}{The \jsc@clsname\space class does not support `winjis' option}} + \ClassWarningNoLine{\jsc@clsname}{this class does not support `winjis' option}} \DeclareOption{uplatex}{% - \ClassErrorNoLine{\jsc@clsname}{The \jsc@clsname\space class does not support `uplatex' option}} + \ClassError{\jsc@clsname}{this class does not support `uplatex' option}} \DeclareOption{autodetect-engine}{% - \ClassWarningNoLine{\jsc@clsname}{The \jsc@clsname\space class does not support `autodetect-engine' option}} + \ClassWarningNoLine{\jsc@clsname}{this class does not support `autodetect-engine' option}} \DeclareOption{mingoth}{\mingothtrue} \DeclareOption{ptexjis}{\ptexjistrue} \DeclareOption{jis}{\jisfonttrue} @@ -245,7 +244,7 @@ option, since LuaTeX does not support \string\mag\MessageBreak in pdf output}% \ifdim\jsc@mpt=1.2\p@ \renewcommand{\@ptsize}{2}\else \renewcommand{\@ptsize}{-20}\fi\fi \ifjsc@mag@xreal -\ifdim\jsc@mpt=\p@\else +\ifdim\jsc@mpt=\p@\jsc@mag@xrealfalse\else \expandafter\let\csname OT1/cmr/m/n/10\endcsname\relax \expandafter\let\csname TU/lmr/m/n/10\endcsname\relax \expandafter\let\csname OMX/cmex/m/n/10\endcsname\relax @@ -311,7 +310,6 @@ option, since LuaTeX does not support \string\mag\MessageBreak in pdf output}% \setlength{\pageheight}{\paperheight} \fi \fi - \def\Cjascale{0.924715} \expandafter\let\csname JY3/mc/m/n/10\endcsname\relax \ifmingoth \DeclareFontShape{JY3}{mc}{m}{n}{<-> s * [\Cjascale] \ltj@stdmcfont:jfm=min}{} @@ -320,13 +318,8 @@ option, since LuaTeX does not support \string\mag\MessageBreak in pdf output}% \ifptexjis \DeclareFontShape{JY3}{mc}{m}{n}{<-> s * [\Cjascale] \ltj@stdmcfont:jfm=jis}{} \DeclareFontShape{JY3}{gt}{m}{n}{<-> s * [\Cjascale] \ltj@stdgtfont:jfm=jis}{} - \else - \DeclareFontShape{JY3}{mc}{m}{n}{<-> s * [\Cjascale] \ltj@stdmcfont:jfm=ujis}{} - \DeclareFontShape{JY3}{gt}{m}{n}{<-> s * [\Cjascale] \ltj@stdgtfont:jfm=ujis}{} \fi \fi -\DeclareFontShape{JT3}{mc}{m}{n}{<-> s * [\Cjascale] \ltj@stdmcfont:jfm=ujisv}{} -\DeclareFontShape{JT3}{gt}{m}{n}{<-> s * [\Cjascale] \ltj@stdgtfont:jfm=ujisv}{} \DeclareFontShape{JY3}{mc}{bx}{n}{<->ssub*gt/m/n}{} \DeclareFontShape{JY3}{gt}{bx}{n}{<->ssub*gt/m/n}{} \DeclareFontShape{JY3}{mc}{b}{n}{<->ssub*gt/m/n}{} @@ -356,8 +349,11 @@ option, since LuaTeX does not support \string\mag\MessageBreak in pdf output}% \renewcommand\jttdefault{\gtdefault}\@ltj@match@familytrue %% \AtBeginDocument{% - \reDeclareMathAlphabet{\mathrm}{\mathrm}{\mathmc} - \reDeclareMathAlphabet{\mathbf}{\mathbf}{\mathgt}}% + \unless\ifltj@disablejfam + \reDeclareMathAlphabet{\mathrm}{\mathrm}{\mathmc} + \reDeclareMathAlphabet{\mathbf}{\mathbf}{\mathgt} + \fi +}% \ltjsetparameter{jaxspmode={`!,2}} \ltjsetparameter{jaxspmode={`〒,1}} \ltjsetparameter{alxspmode={`+,3}} @@ -1355,6 +1351,8 @@ class has defined the old font commands like\MessageBreak \@dottedtocline{5}{\@tempdima}{6.5\zw}} \newdimen\@lnumwidth \def\numberline#1{\hb@xt@\@lnumwidth{#1\hfil}\hspace{0pt}} +\def\jsTocLine{\leaders\hbox{% + $\m@th \mkern \@dotsep mu\hbox{.}\mkern \@dotsep mu$}\hfill} \def\@dottedtocline#1#2#3#4#5{\ifnum #1>\c@tocdepth \else \vskip \z@ \@plus.2\jsc@mpt {\leftskip #2\relax \rightskip \@tocrmarg \parfillskip -\rightskip @@ -1364,8 +1362,7 @@ class has defined the old font commands like\MessageBreak \@lnumwidth #3\relax \advance\leftskip \@lnumwidth \null\nobreak\hskip -\leftskip {#4}\nobreak - \leaders\hbox{$\m@th \mkern \@dotsep mu\hbox{.}\mkern \@dotsep - mu$}\hfill \nobreak\hb@xt@\@pnumwidth{% + \jsTocLine \nobreak\hb@xt@\@pnumwidth{% \hfil\normalfont \normalcolor #5}\par}\fi} \newcommand{\listoffigures}{% \if@twocolumn\@restonecoltrue\onecolumn @@ -1716,23 +1713,42 @@ class has defined the old font commands like\MessageBreak \def\西暦{\西暦true} \def\和暦{\西暦false} \newcount\heisei \heisei\year \advance\heisei-1988\relax +\def\pltx@today@year@#1{% + \ifnum\numexpr\year-#1=1 元\else + \ifnum\ltjgetparameter{direction}=3 + \kansuji\numexpr\year-#1\relax + \else + \number\numexpr\year-#1\relax\nobreak + \fi + \fi 年 +} +\def\pltx@today@year{% + \ifnum\numexpr\year*10000+\month*100+\day<19890108 + 昭和\pltx@today@year@{1925}% + \else\ifnum\numexpr\year*10000+\month*100+\day<20190501 + 平成\pltx@today@year@{1988}% + \else + 令和\pltx@today@year@{2018}% + \fi\fi} \def\today{% \if@english \ifcase\month\or January\or February\or March\or April\or May\or June\or July\or August\or September\or October\or November\or December\fi \space\number\day, \number\year + \else\if西暦 + \ifnum\ltjgetparameter{direction}=3 \kansuji\year + \else\number\year\nobreak\fi 年 \else - \if西暦 - \number\year 年 - \number\month 月 - \number\day 日 - \else - 平成\number\heisei 年 - \number\month 月 - \number\day 日 - \fi - \fi} + \pltx@today@year + \fi + \ifnum\ltjgetparameter{direction}=3 + \kansuji\month 月 + \kansuji\day 日 + \else + \number\month\nobreak 月 + \number\day\nobreak 日 + \fi\fi} \hyphenation{ado-be post-script ghost-script phe-nom-e-no-log-i-cal man-u-script} \pagestyle{plain} \pagenumbering{arabic}