X-Git-Url: http://git.osdn.jp/view?a=blobdiff_plain;f=src%2Fltjbook.cls;h=6ad203fcce0aa918c675d61b3ed0304d53b01527;hb=f078ac2f7998a102c7ec765e725f2269eed9f872;hp=8da3e9a2daf89ef5c80567578c080f74b2f02e1b;hpb=871900f0dca66ffbd2b0d6802c5d83a119b89448;p=luatex-ja%2Fluatexja.git diff --git a/src/ltjbook.cls b/src/ltjbook.cls index 8da3e9a..6ad203f 100644 --- a/src/ltjbook.cls +++ b/src/ltjbook.cls @@ -21,9 +21,10 @@ %% same distribution. (The sources need not necessarily be %% in the same archive or directory.) %% File: ltjclasses.dtx + \NeedsTeXFormat{LaTeX2e} \ProvidesClass{ltjbook} - [2018/10/08 v1.8-ltj-16 + [2019/04/06 v1.8b-ltj-16 Standard LuaLaTeX-ja class] \RequirePackage{luatexja} \newcounter{@paper} @@ -777,7 +778,7 @@ \def\addcontentsline#1#2#3{% \protected@write\@auxout {\let\label\@gobble \let\index\@gobble \let\glossary\@gobble -\@temptokena{\thepage}}% + \@temptokena{\thepage}}% {\string\@writefile{#1}% {\protect\contentsline{#2}{#3}{\the\@temptokena}% \protected@file@percent}}% @@ -887,32 +888,37 @@ \newif\if西暦 \西暦true \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\fi + \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}% + 昭和\pltx@today@year@{1925}% \else\ifnum\numexpr\year*10000+\month*100+\day<20190501 -平成\pltx@today@year@{1988}% + 平成\pltx@today@year@{1988}% \else -〓〓\pltx@today@year@{2018}% + 令和\pltx@today@year@{2018}% \fi\fi} \def\today{{% \if西暦 - \ifnum\ltjgetparameter{direction}=3 \kansuji\year\else\number\year\fi 年 + \ifnum\ltjgetparameter{direction}=3 \kansuji\year + \else\number\year\nobreak\fi 年 \else -\pltx@today@year + \pltx@today@year \fi \ifnum\ltjgetparameter{direction}=3 -\kansuji\month 月 + \kansuji\month 月 \kansuji\day 日 \else - \number\month~月 - \number\day~日 + \number\month\nobreak 月 + \number\day\nobreak 日 \fi}} \newcommand{\prepartname}{第} \newcommand{\postpartname}{部}