OSDN Git Service

19b68c7b230361618bec94f9eeca164e1d9e59bf
[luatex-ja/luatexja.git] / src / ltjtarticle.cls
1 %%
2 %% This is file `ltjtarticle.cls',
3 %% generated with the docstrip utility.
4 %%
5 %% The original source files were:
6 %%
7 %% ltjclasses.dtx  (with options: `article,tate')
8 %% 
9 %% IMPORTANT NOTICE:
10 %% 
11 %% For the copyright see the source file.
12 %% 
13 %% Any modified versions of this file must be renamed
14 %% with new filenames distinct from ltjtarticle.cls.
15 %% 
16 %% For distribution of the original source see the terms
17 %% for copying and modification in the file ltjclasses.dtx.
18 %% 
19 %% This generated file may be distributed as long as the
20 %% original source files, as listed above, are part of the
21 %% same distribution. (The sources need not necessarily be
22 %% in the same archive or directory.)
23 %% File: ltjclasses.dtx
24 \NeedsTeXFormat{LaTeX2e}
25 \ProvidesClass{ltjtarticle}
26   [2017/12/31 v1.7g-ltj-16
27  Standard LuaLaTeX-ja class]
28 \RequirePackage{luatexja}
29 \newcounter{@paper}
30 \newif\if@landscape \@landscapefalse
31 \newcommand{\@ptsize}{}
32 \newif\if@restonecol
33 \newif\if@titlepage
34 \@titlepagefalse
35 \hour\time \divide\hour by 60\relax
36 \@tempcnta\hour \multiply\@tempcnta 60\relax
37 \minute\time \advance\minute-\@tempcnta
38 \newif\if@stysize \@stysizefalse
39 \newif\if@mathrmmc \@mathrmmcfalse
40 \DeclareOption{a4paper}{\setcounter{@paper}{1}%
41   \setlength\paperheight {297mm}%
42   \setlength\paperwidth  {210mm}}
43 \DeclareOption{a5paper}{\setcounter{@paper}{2}%
44   \setlength\paperheight {210mm}
45   \setlength\paperwidth  {148mm}}
46 \DeclareOption{b4paper}{\setcounter{@paper}{3}%
47   \setlength\paperheight {364mm}
48   \setlength\paperwidth  {257mm}}
49 \DeclareOption{b5paper}{\setcounter{@paper}{4}%
50   \setlength\paperheight {257mm}
51   \setlength\paperwidth  {182mm}}
52 \DeclareOption{a4j}{\setcounter{@paper}{1}\@stysizetrue
53   \setlength\paperheight {297mm}%
54   \setlength\paperwidth  {210mm}}
55 \DeclareOption{a5j}{\setcounter{@paper}{2}\@stysizetrue
56   \setlength\paperheight {210mm}
57   \setlength\paperwidth  {148mm}}
58 \DeclareOption{b4j}{\setcounter{@paper}{3}\@stysizetrue
59   \setlength\paperheight {364mm}
60   \setlength\paperwidth  {257mm}}
61 \DeclareOption{b5j}{\setcounter{@paper}{4}\@stysizetrue
62   \setlength\paperheight {257mm}
63   \setlength\paperwidth  {182mm}}
64 \DeclareOption{a4p}{\setcounter{@paper}{1}\@stysizetrue
65   \setlength\paperheight {297mm}%
66   \setlength\paperwidth  {210mm}}
67 \DeclareOption{a5p}{\setcounter{@paper}{2}\@stysizetrue
68   \setlength\paperheight {210mm}
69   \setlength\paperwidth  {148mm}}
70 \DeclareOption{b4p}{\setcounter{@paper}{3}\@stysizetrue
71   \setlength\paperheight {364mm}
72   \setlength\paperwidth  {257mm}}
73 \DeclareOption{b5p}{\setcounter{@paper}{4}\@stysizetrue
74   \setlength\paperheight {257mm}
75   \setlength\paperwidth  {182mm}}
76 \if@compatibility
77   \renewcommand{\@ptsize}{0}
78 \else
79   \DeclareOption{10pt}{\renewcommand{\@ptsize}{0}}
80 \fi
81 \DeclareOption{11pt}{\renewcommand{\@ptsize}{1}}
82 \DeclareOption{12pt}{\renewcommand{\@ptsize}{2}}
83 \DeclareOption{landscape}{\@landscapetrue
84   \setlength\@tempdima{\paperheight}%
85   \setlength\paperheight{\paperwidth}%
86   \setlength\paperwidth{\@tempdima}}
87 \DeclareOption{tombow}{%
88   \tombowtrue \tombowdatetrue
89   \setlength{\@tombowwidth}{.1\p@}%
90   \@bannertoken{%
91      \jobname\space(\number\year-\two@digits\month-\two@digits\day
92      \space\two@digits\hour:\two@digits\minute)}%
93   \maketombowbox}
94 \DeclareOption{tombo}{%
95   \tombowtrue \tombowdatefalse
96   \setlength{\@tombowwidth}{.1\p@}%
97   \maketombowbox}
98 \DeclareOption{mentuke}{%
99   \tombowtrue \tombowdatefalse
100   \setlength{\@tombowwidth}{\z@}%
101   \maketombowbox}
102 \DeclareOption{tate}{%
103   \tate\AtBeginDocument{\message{《縦組モード》}\adjustbaseline}%
104 }
105 \AtEndOfPackageFile{everyshi}{%
106   \def\@EveryShipout@Output{%
107     \setbox8\vbox{%
108       \yoko
109       \@EveryShipout@Hook
110       \@EveryShipout@AtNextHook
111       \global\setbox\luatexoutputbox=\box\luatexoutputbox
112     }%
113     \gdef\@EveryShipout@AtNextHook{}%
114     \@EveryShipout@Org@Shipout\box\luatexoutputbox
115   }}
116 \DeclareOption{oneside}{\@twosidefalse}
117 \DeclareOption{twoside}{\@twosidetrue}
118 \DeclareOption{onecolumn}{\@twocolumnfalse}
119 \DeclareOption{twocolumn}{\@twocolumntrue}
120 \DeclareOption{titlepage}{\@titlepagetrue}
121 \DeclareOption{notitlepage}{\@titlepagefalse}
122 \DeclareOption{leqno}{\input{leqno.clo}}
123 \DeclareOption{fleqn}{\input{fleqn.clo}}
124 \DeclareOption{openbib}{%
125   \AtEndOfPackage{%
126    \renewcommand\@openbib@code{%
127       \advance\leftmargin\bibindent
128       \itemindent -\bibindent
129       \listparindent \itemindent
130       \parsep \z@
131       }%
132    \renewcommand\newblock{\par}}}
133 \if@compatibility
134   \@mathrmmctrue
135 \else
136   \DeclareOption{disablejfam}{%
137     \ClassWarningNoLine{\@currname}{The class option 'disablejfam' is obsolete}}
138   \DeclareOption{mathrmmc}{\@mathrmmctrue}
139 \fi
140 \DeclareOption{draft}{\setlength\overfullrule{5pt}}
141 \DeclareOption{final}{\setlength\overfullrule{0pt}}
142 \directlua{luatexbase.add_to_callback('luatexja.load_jfm',
143   function (ji, jn) ji.chars['parbdd'] = 0; return ji end,
144   'ltj.jclasses_load_jfm', 1)}
145 {\jfont\g=\ltj@stdmcfont:jfm=min } % loading jfm-min.lua
146 \expandafter\let\csname JY3/mc/m/n/10\endcsname\relax
147 \def\Cjascale{0.962216}
148 \DeclareFontShape{JY3}{mc}{m}{n}{<-> s * [0.962216] \ltj@stdmcfont:jfm=min}{}
149 \DeclareFontShape{JY3}{gt}{m}{n}{<-> s * [0.962216] \ltj@stdgtfont:jfm=min;jfmvar=goth}{}
150 \ltjglobalsetparameter{differentjfm=both}
151 \directlua{luatexbase.remove_from_callback('luatexja.load_jfm', 'ltj.jclasses_load_jfm')}
152 \ExecuteOptions{a4paper,10pt,oneside,onecolumn,final,tate}
153 \ProcessOptions\relax
154 \input{ltjtsize1\@ptsize.clo}
155 \RequirePackage{lltjext}
156 \if@stysize
157   \setlength\columnsep{3\Cwd}
158 \else
159   \setlength\columnsep{10\p@}
160 \fi
161 \setlength\columnseprule{0\p@}
162 \iftombow
163   \newlength{\stockwidth}
164   \newlength{\stockheight}
165   \setlength{\stockwidth}{\paperwidth}
166   \setlength{\stockheight}{\paperheight}
167   \advance \stockwidth 2in
168   \advance \stockheight 2in
169   \ifdefined\pdfpagewidth
170     \setlength{\pdfpagewidth}{\stockwidth}
171     \setlength{\pdfpageheight}{\stockheight}
172   \else
173     \setlength{\pagewidth}{\stockwidth}
174     \setlength{\pageheight}{\stockheight}
175   \fi
176 \else
177   \ifdefined\pdfpagewidth
178     \setlength{\pdfpagewidth}{\paperwidth}
179     \setlength{\pdfpageheight}{\paperheight}
180   \else
181     \setlength{\pagewidth}{\paperwidth}
182     \setlength{\pageheight}{\paperheight}
183   \fi
184 \fi
185 \setlength\lineskip{1\p@}
186 \setlength\normallineskip{1\p@}
187 \renewcommand{\baselinestretch}{}
188 \setlength\parskip{0\p@ \@plus \p@}
189 \setlength\parindent{1\Cwd}
190 \@lowpenalty   51
191 \@medpenalty  151
192 \@highpenalty 301
193 \setcounter{topnumber}{2}
194 \setcounter{bottomnumber}{1}
195 \setcounter{totalnumber}{3}
196 \setcounter{dbltopnumber}{2}
197 \renewcommand{\topfraction}{.7}
198 \renewcommand{\bottomfraction}{.3}
199 \renewcommand{\textfraction}{.2}
200 \renewcommand{\floatpagefraction}{.5}
201 \renewcommand{\dbltopfraction}{.7}
202 \renewcommand{\dblfloatpagefraction}{.5}
203 \def\pltx@cleartorightpage{\clearpage\if@twoside
204   \unless\ifodd\numexpr\c@page+\ltjgetparameter{direction}\relax
205     \hbox{}\thispagestyle{empty}\newpage
206     \if@twocolumn\hbox{}\newpage\fi
207   \fi\fi}
208 \def\pltx@cleartoleftpage{\clearpage\if@twoside
209   \ifodd\numexpr\c@page+\ltjgetparameter{direction}\relax
210     \hbox{}\thispagestyle{empty}\newpage
211     \if@twocolumn\hbox{}\newpage\fi
212   \fi\fi}
213 \def\pltx@cleartooddpage{\clearpage\if@twoside
214   \ifodd\c@page\else
215     \hbox{}\thispagestyle{empty}\newpage
216     \if@twocolumn\hbox{}\newpage\fi
217   \fi\fi}
218 \def\pltx@cleartoevenpage{\clearpage\if@twoside
219   \ifodd\c@page
220     \hbox{}\thispagestyle{empty}\newpage
221     \if@twocolumn\hbox{}\newpage\fi
222   \fi\fi}
223 \def\ps@plain{\let\@mkboth\@gobbletwo
224    \let\ps@jpl@in\ps@plain
225    \let\@oddhead\@empty
226    \def\@oddfoot{\reset@font\hfil\thepage\hfil}%
227    \let\@evenhead\@empty
228    \let\@evenfoot\@oddfoot}
229 \let\ps@jpl@in\ps@plain
230 \def\ps@headnombre{\let\@mkboth\@gobbletwo
231     \let\ps@jpl@in\ps@headnombre
232   \def\@evenhead{\hfil\thepage}%
233   \def\@oddhead{\thepage\hfil}%
234   \let\@oddfoot\@empty\let\@evenfoot\@empty}
235 \def\ps@footnombre{\let\@mkboth\@gobbletwo
236     \let\ps@jpl@in\ps@footnombre
237   \def\@evenfoot{\hfil\thepage}%
238   \def\@oddfoot{\thepage\hfil}%
239   \let\@oddhead\@empty\let\@evenhead\@empty}
240 \if@twoside
241   \def\ps@headings{\let\ps@jpl@in\ps@headnombre
242     \let\@oddfoot\@empty\let\@evenfoot\@empty
243     \def\@evenhead{{\leftmark}\hfil\thepage}%
244     \def\@oddhead{\thepage\hfil\rightmark}%
245     \let\@mkboth\markboth
246     \def\sectionmark##1{\markboth{%
247        \ifnum \c@secnumdepth >\z@ \thesection.\hskip1\zw\fi
248        ##1}{}}%
249     \def\subsectionmark##1{\markright{%
250        \ifnum \c@secnumdepth >\@ne \thesubsection.\hskip1\zw\fi
251        ##1}}%
252   }
253 \else % if not twoside
254   \def\ps@headings{\let\ps@jpl@in\ps@headnombre
255     \let\@oddfoot\@empty
256     \def\@oddhead{\thepage\hfil\rightmark}%
257     \let\@mkboth\markboth
258   \def\sectionmark##1{\markright{%
259      \ifnum \c@secnumdepth >\m@ne \thesection.\hskip1\zw\fi
260      ##1}}%
261   }
262 \fi
263 \if@twoside
264   \def\ps@bothstyle{\let\ps@jpl@in\ps@footnombre
265     \def\@evenhead{\hfil\leftmark}% right page
266     \def\@evenfoot{\hfil\thepage}% right page
267     \def\@oddhead{\rightmark\hfil}% left page
268     \def\@oddfoot{\thepage\hfil}% left page
269   \let\@mkboth\markboth
270   \def\sectionmark##1{\markboth{%
271      \ifnum \c@secnumdepth >\z@ \thesection.\hskip1\zw\fi
272      ##1}{}}%
273   \def\subsectionmark##1{\markright{%
274      \ifnum \c@secnumdepth >\@ne \thesubsection.\hskip1\zw\fi
275      ##1}}%
276   }
277 \else % if one column
278   \def\ps@bothstyle{\let\ps@jpl@in\ps@footnombre
279     \def\@oddhead{\rightmark\hfil}%
280     \def\@oddfoot{\thepage\hfil}%
281     \let\@mkboth\markboth
282   \def\sectionmark##1{\markright{%
283      \ifnum \c@secnumdepth >\m@ne \thesection.\hskip1\zw\fi
284      ##1}}%
285   }
286 \fi
287 \def\ps@myheadings{\let\ps@jpl@in\ps@plain%
288   \let\@oddfoot\@empty\let\@evenfoot\@empty
289   \def\@evenhead{{\leftmark}\hfil\thepage}%
290   \def\@oddhead{\thepage\hfil\rightmark}%
291   \let\@mkboth\@gobbletwo
292   \let\sectionmark\@gobble
293   \let\subsectionmark\@gobble
294 }
295 \if@compatibility
296 \newenvironment{titlepage}
297     {%
298      \if@twocolumn\@restonecoltrue\onecolumn
299      \else\@restonecolfalse\newpage\fi
300      \thispagestyle{empty}%
301      \setcounter{page}\z@
302     }%
303     {\if@restonecol\twocolumn\else\newpage\fi
304     }
305 \else
306 \newenvironment{titlepage}
307     {%
308       \if@twocolumn
309         \@restonecoltrue\onecolumn
310       \else
311         \@restonecolfalse\newpage
312       \fi
313       \thispagestyle{empty}%
314       \ifodd\c@page\setcounter{page}\@ne\else\setcounter{page}\z@\fi %% 2017/02/15
315     }%
316     {\if@restonecol\twocolumn \else \newpage \fi
317      \if@twoside\else
318         \setcounter{page}\@ne
319      \fi
320     }
321 \fi
322 \def\p@thanks#1{\footnotemark
323   \protected@xdef\@thanks{\@thanks
324     \protect{\noindent\hbox{\yoko$\m@th^\thefootnote$}#1\protect\par}}}
325 \if@titlepage
326   \newcommand{\maketitle}{\begin{titlepage}%
327   \let\footnotesize\small
328   \let\footnoterule\relax
329   \let\thanks\p@thanks
330   \let\footnote\thanks
331   \vbox to\textheight\bgroup\tate\hsize\textwidth
332   \null\vfil
333   \vskip 60\p@
334   \begin{center}%
335     {\LARGE \@title \par}%
336     \vskip 3em%
337     {\Large
338      \lineskip .75em%
339       \begin{tabular}[t]{c}%
340         \@author
341       \end{tabular}\par}%
342       \vskip 1.5em%
343     {\large \@date \par}%       % Set date in \large size.
344   \end{center}\par
345   \vfil{\centering\@thanks}\vfil\null
346   \egroup
347   \end{titlepage}%
348   \setcounter{footnote}{0}%
349   \global\let\thanks\relax
350   \global\let\maketitle\relax
351   \global\let\p@thanks\relax
352   \global\let\@thanks\@empty
353   \global\let\@author\@empty
354   \global\let\@date\@empty
355   \global\let\@title\@empty
356   \global\let\title\relax
357   \global\let\author\relax
358   \global\let\date\relax
359   \global\let\and\relax
360   }%
361 \else
362   \newcommand{\maketitle}{\par
363   \begingroup
364     \renewcommand{\thefootnote}{\fnsymbol{footnote}}%
365     \def\@makefnmark{\hbox{\unless\ifnum\ltjgetparameter{direction}=3 $\m@th^{\@thefnmark}$
366       \else\hbox{\yoko$\m@th^{\@thefnmark}$}\fi}}%
367     \long\def\@makefntext##1{\parindent 1\zw\noindent
368        \hb@xt@ 2\zw{\hss\@makefnmark}##1}%
369     \if@twocolumn
370       \ifnum \col@number=\@ne \@maketitle
371       \else \twocolumn[\@maketitle]%
372       \fi
373     \else
374       \newpage
375       \global\@topnum\z@   % Prevents figures from going at top of page.
376       \@maketitle
377     \fi
378      \thispagestyle{jpl@in}\@thanks
379   \endgroup
380   \setcounter{footnote}{0}%
381   \global\let\thanks\relax
382   \global\let\maketitle\relax
383   \global\let\@maketitle\relax
384   \global\let\p@thanks\relax
385   \global\let\@thanks\@empty
386   \global\let\@author\@empty
387   \global\let\@date\@empty
388   \global\let\@title\@empty
389   \global\let\title\relax
390   \global\let\author\relax
391   \global\let\date\relax
392   \global\let\and\relax
393   }
394   \def\@maketitle{%
395   \newpage\null
396   \vskip 2em%
397   \begin{center}%
398   \let\footnote\p@thanks
399     {\LARGE \@title \par}%
400     \vskip 1.5em%
401     {\large
402       \lineskip .5em%
403       \begin{tabular}[t]{c}%
404         \@author
405       \end{tabular}\par}%
406     \vskip 1em%
407     {\large \@date}%
408   \end{center}%
409   \par\vskip 1.5em}
410 \fi
411 \if@titlepage
412   \newenvironment{abstract}{%
413       \titlepage
414       \null\vfil
415       \@beginparpenalty\@lowpenalty
416       \begin{center}%
417         {\bfseries\abstractname}%
418         \@endparpenalty\@M
419       \end{center}}%
420       {\par\vfil\null\endtitlepage}
421 \else
422   \newenvironment{abstract}{%
423     \if@twocolumn
424       \section*{\abstractname}%
425     \else
426       \small
427       \begin{center}%
428         {\bfseries\abstractname\vspace{-.5em}\vspace{\z@}}%
429       \end{center}%
430       \quotation
431     \fi}{\if@twocolumn\else\endquotation\fi}
432 \fi
433 \setcounter{secnumdepth}{3}
434 \newcounter{part}
435 \newcounter{section}
436 \newcounter{subsection}[section]
437 \newcounter{subsubsection}[subsection]
438 \newcounter{paragraph}[subsubsection]
439 \newcounter{subparagraph}[paragraph]
440 \renewcommand{\thepart}{\rensuji{\@Roman\c@part}}
441 \renewcommand{\thesection}{\rensuji{\@arabic\c@section}}
442 \renewcommand{\thesubsection}{\thesection・\rensuji{\@arabic\c@subsection}}
443 \renewcommand{\thesubsubsection}{%
444    \thesubsection・\rensuji{\@arabic\c@subsubsection}}
445 \renewcommand{\theparagraph}{%
446    \thesubsubsection・\rensuji{\@arabic\c@paragraph}}
447 \renewcommand{\thesubparagraph}{%
448    \theparagraph・\rensuji{\@arabic\c@subparagraph}}
449 \newcommand{\part}{%
450   \if@noskipsec \leavevmode \fi
451   \par\addvspace{4ex}%
452   \@afterindenttrue
453   \secdef\@part\@spart}
454 \def\@part[#1]#2{%
455   \ifnum \c@secnumdepth >\m@ne
456     \refstepcounter{part}%
457     \addcontentsline{toc}{part}{%
458        \prepartname\thepart\postpartname\hspace{1\zw}#1}%
459   \else
460     \addcontentsline{toc}{part}{#1}%
461   \fi
462   \markboth{}{}%
463   {\parindent\z@\raggedright
464    \interlinepenalty\@M\normalfont
465    \ifnum \c@secnumdepth >\m@ne
466      \Large\bfseries\prepartname\thepart\postpartname
467      \par\nobreak
468    \fi
469    \huge\bfseries#2\par}%
470   \nobreak\vskip3ex\@afterheading}
471 \def\@spart#1{{%
472   \parindent\z@\raggedright
473   \interlinepenalty\@M\normalfont
474   \huge\bfseries#1\par}%
475   \nobreak\vskip3ex\@afterheading}
476 \newcommand{\section}{\@startsection{section}{1}{\z@}%
477    {1.5\Cvs \@plus.5\Cvs \@minus.2\Cvs}%
478    {.5\Cvs \@plus.3\Cvs}%
479    {\normalfont\Large\bfseries}}
480 \newcommand{\subsection}{\@startsection{subsection}{2}{\z@}%
481    {1.5\Cvs \@plus.5\Cvs \@minus.2\Cvs}%
482    {.5\Cvs \@plus.3\Cvs}%
483    {\normalfont\large\bfseries}}
484 \newcommand{\subsubsection}{\@startsection{subsubsection}{3}{\z@}%
485    {1.5\Cvs \@plus.5\Cvs \@minus.2\Cvs}%
486    {.5\Cvs \@plus.3\Cvs}%
487    {\normalfont\normalsize\bfseries}}
488 \newcommand{\paragraph}{\@startsection{paragraph}{4}{\z@}%
489    {3.25ex \@plus 1ex \@minus .2ex}%
490    {-1em}%
491    {\normalfont\normalsize\bfseries}}
492 \newcommand{\subparagraph}{\@startsection{subparagraph}{5}{\z@}%
493    {3.25ex \@plus 1ex \@minus .2ex}%
494    {-1em}%
495    {\normalfont\normalsize\bfseries}}
496 \newcommand{\appendix}{\par
497   \setcounter{section}{0}%
498   \setcounter{subsection}{0}%
499   \renewcommand{\thesection}{\rensuji{\@Alph\c@section}}}
500 \if@twocolumn
501   \setlength\leftmargini {2em}
502 \else
503   \setlength\leftmargini {2.5em}
504 \fi
505 \setlength\leftmarginii  {2.2em}
506 \setlength\leftmarginiii {1.87em}
507 \setlength\leftmarginiv  {1.7em}
508 \if@twocolumn
509   \setlength\leftmarginv {.5em}
510   \setlength\leftmarginvi{.5em}
511 \else
512   \setlength\leftmarginv {1em}
513   \setlength\leftmarginvi{1em}
514 \fi
515 \setlength  \labelsep  {.5em}
516 \setlength  \labelwidth{\leftmargini}
517 \addtolength\labelwidth{-\labelsep}
518 \@beginparpenalty -\@lowpenalty
519 \@endparpenalty   -\@lowpenalty
520 \@itempenalty     -\@lowpenalty
521 \renewcommand{\theenumi}{\rensuji{\@arabic\c@enumi}}
522 \renewcommand{\theenumii}{\rensuji{(\@alph\c@enumii)}}
523 \renewcommand{\theenumiii}{\rensuji{\@roman\c@enumiii}}
524 \renewcommand{\theenumiv}{\rensuji{\@Alph\c@enumiv}}
525 \newcommand{\labelenumi}{\theenumi}
526 \newcommand{\labelenumii}{\theenumii}
527 \newcommand{\labelenumiii}{\theenumiii}
528 \newcommand{\labelenumiv}{\theenumiv}
529 \renewcommand{\p@enumii}{\theenumi}
530 \renewcommand{\p@enumiii}{\theenumi(\theenumii)}
531 \renewcommand{\p@enumiv}{\p@enumiii\theenumiii}
532 \renewenvironment{enumerate}
533   {\ifnum \@enumdepth >\thr@@\@toodeep\else
534    \advance\@enumdepth\@ne
535    \edef\@enumctr{enum\romannumeral\the\@enumdepth}%
536    \expandafter \list \csname label\@enumctr\endcsname{%
537       \ifnum\ltjgetparameter{direction}=3
538          \ifnum \@listdepth=\@ne \topsep.5\normalbaselineskip
539            \else\topsep\z@\fi
540          \parskip\z@ \itemsep\z@ \parsep\z@
541          \labelwidth1\zw \labelsep.3\zw
542          \ifnum \@enumdepth=\@ne \leftmargin1\zw\relax
543            \else\leftmargin\leftskip\fi
544          \advance\leftmargin 1\zw
545       \fi
546          \usecounter{\@enumctr}%
547          \def\makelabel##1{\hss\llap{##1}}}%
548    \fi}{\endlist}
549 \newcommand{\labelitemi}{\textbullet}
550 \newcommand{\labelitemii}{%
551   \ifnum\ltjgetparameter{direction}=3
552      {\textcircled{~}}
553   \else
554      {\normalfont\bfseries\textendash}
555   \fi
556 }
557 \newcommand{\labelitemiii}{\textasteriskcentered}
558 \newcommand{\labelitemiv}{\textperiodcentered}
559 \renewenvironment{itemize}
560   {\ifnum \@itemdepth >\thr@@\@toodeep\else
561    \advance\@itemdepth\@ne
562    \edef\@itemitem{labelitem\romannumeral\the\@itemdepth}%
563    \expandafter \list \csname \@itemitem\endcsname{%
564       \ifnum\ltjgetparameter{direction}=3
565          \ifnum \@listdepth=\@ne \topsep.5\normalbaselineskip
566            \else\topsep\z@\fi
567          \parskip\z@ \itemsep\z@ \parsep\z@
568          \labelwidth1\zw \labelsep.3\zw
569          \ifnum \@itemdepth =\@ne \leftmargin1\zw\relax
570            \else\leftmargin\leftskip\fi
571          \advance\leftmargin 1\zw
572       \fi
573          \def\makelabel##1{\hss\llap{##1}}}%
574    \fi}{\endlist}
575 \newenvironment{description}
576   {\list{}{\labelwidth\z@ \itemindent-\leftmargin
577    \ifnum\ltjgetparameter{direction}=3
578      \leftmargin\leftskip \advance\leftmargin3\Cwd
579      \rightmargin\rightskip
580      \labelsep=1\zw \itemsep\z@
581      \listparindent\z@ \topskip\z@ \parskip\z@ \partopsep\z@
582    \fi
583            \let\makelabel\descriptionlabel}}{\endlist}
584 \newcommand{\descriptionlabel}[1]{%
585    \hspace\labelsep\normalfont\bfseries #1}
586 \newenvironment{verse}
587   {\let\\\@centercr
588    \list{}{\itemsep\z@ \itemindent -1.5em%
589            \listparindent\itemindent
590            \rightmargin\leftmargin \advance\leftmargin 1.5em}%
591            \item\relax}{\endlist}
592 \newenvironment{quotation}
593   {\list{}{\listparindent 1.5em%
594            \itemindent\listparindent
595            \rightmargin\leftmargin
596            \parsep\z@ \@plus\p@}%
597            \item\relax}{\endlist}
598 \newenvironment{quote}
599   {\list{}{\rightmargin\leftmargin}%
600            \item\relax}{\endlist}
601 \newcounter{figure}
602 \renewcommand{\thefigure}{\rensuji{\@arabic\c@figure}}
603 \def\fps@figure{tbp}
604 \def\ftype@figure{1}
605 \def\ext@figure{lof}
606 \def\fnum@figure{\figurename\thefigure}
607 \newenvironment{figure}
608                {\@float{figure}}
609                {\end@float}
610 \newenvironment{figure*}
611                {\@dblfloat{figure}}
612                {\end@dblfloat}
613 \newcounter{table}
614 \renewcommand{\thetable}{\rensuji{\@arabic\c@table}}
615 \def\fps@table{tbp}
616 \def\ftype@table{2}
617 \def\ext@table{lot}
618 \def\fnum@table{\tablename\thetable}
619 \newenvironment{table}
620                {\@float{table}}
621                {\end@float}
622 \newenvironment{table*}
623                {\@dblfloat{table}}
624                {\end@dblfloat}
625 \newlength\abovecaptionskip
626 \newlength\belowcaptionskip
627 \setlength\abovecaptionskip{10\p@}
628 \setlength\belowcaptionskip{0\p@}
629 \long\def\@makecaption#1#2{%
630   \vskip\abovecaptionskip
631   \ifnum\ltjgetparameter{direction}=3 \sbox\@tempboxa{#1\hskip1\zw#2}%
632     \else\sbox\@tempboxa{#1: #2}%
633   \fi
634   \ifdim \wd\@tempboxa >\hsize
635     \ifnum\ltjgetparameter{direction}=3  #1\hskip1\zw#2\relax\par
636       \else #1: #2\relax\par\fi
637   \else
638     \global \@minipagefalse
639     \hb@xt@\hsize{\hfil\box\@tempboxa\hfil}%
640   \fi
641   \vskip\belowcaptionskip}
642 \setlength\arraycolsep{5\p@}
643 \setlength\tabcolsep{6\p@}
644 \setlength\arrayrulewidth{.4\p@}
645 \setlength\doublerulesep{2\p@}
646 \setlength\tabbingsep{\labelsep}
647 \skip\@mpfootins = \skip\footins
648 \setlength\fboxsep{3\p@}
649 \setlength\fboxrule{.4\p@}
650 \renewcommand{\theequation}{\@arabic\c@equation}
651 \if@compatibility\else
652   \DeclareSymbolFont{mincho}{JY3}{mc}{m}{n}
653   \DeclareSymbolFontAlphabet{\mathmc}{mincho}
654   \SetSymbolFont{mincho}{bold}{JY3}{gt}{m}{n}
655   \jfam\symmincho
656   \DeclareMathAlphabet{\mathgt}{JY3}{gt}{m}{n}
657 \fi
658 \if@mathrmmc
659   \AtBeginDocument{%
660   \reDeclareMathAlphabet{\mathrm}{\mathrm}{\mathmc}
661   \reDeclareMathAlphabet{\mathbf}{\mathbf}{\mathgt}
662 }%
663 \fi
664 \DeclareOldFontCommand{\mc}{\normalfont\mcfamily}{\mathmc}
665 \DeclareOldFontCommand{\gt}{\normalfont\gtfamily}{\mathgt}
666 \DeclareOldFontCommand{\rm}{\normalfont\rmfamily}{\mathrm}
667 \DeclareOldFontCommand{\sf}{\normalfont\sffamily}{\mathsf}
668 \DeclareOldFontCommand{\tt}{\normalfont\ttfamily}{\mathtt}
669 \DeclareOldFontCommand{\bf}{\normalfont\bfseries}{\mathbf}
670 \DeclareOldFontCommand{\it}{\normalfont\itshape}{\mathit}
671 \DeclareOldFontCommand{\sl}{\normalfont\slshape}{\@nomath\sl}
672 \DeclareOldFontCommand{\sc}{\normalfont\scshape}{\@nomath\sc}
673 \DeclareRobustCommand*{\cal}{\@fontswitch\relax\mathcal}
674 \DeclareRobustCommand*{\mit}{\@fontswitch\relax\mathnormal}
675 \setcounter{tocdepth}{3}
676 \newcommand{\@pnumwidth}{1.55em}
677 \newcommand{\@tocrmarg}{2.55em}
678 \newcommand{\@dotsep}{4.5}
679 \newdimen\toclineskip
680 \setlength\toclineskip{2\p@}
681 \newdimen\@lnumwidth
682 \def\numberline#1{\hb@xt@\@lnumwidth{#1\hfil}}
683 \def\@dottedtocline#1#2#3#4#5{%
684   \ifnum #1>\c@tocdepth \else
685     \vskip\toclineskip \@plus.2\p@
686     {\leftskip #2\relax \rightskip \@tocrmarg \parfillskip -\rightskip
687      \parindent #2\relax\@afterindenttrue
688      \interlinepenalty\@M
689      \leavevmode
690      \@lnumwidth #3\relax
691      \advance\leftskip \@lnumwidth \null\nobreak\hskip -\leftskip
692      {#4}\nobreak
693      \leaders\hbox{$\m@th \mkern \@dotsep mu.\mkern \@dotsep mu$}%
694      \hfill\nobreak
695      \hb@xt@\@pnumwidth{\hss\normalfont \normalcolor #5}%
696      \par}%
697   \fi}
698 \def\addcontentsline#1#2#3{%
699   \protected@write\@auxout
700     {\let\label\@gobble \let\index\@gobble \let\glossary\@gobble
701 \@temptokena{\rensuji{\thepage}}}%
702     {\string\@writefile{#1}%
703        {\protect\contentsline{#2}{#3}{\the\@temptokena}}}%
704 }
705 \newcommand{\tableofcontents}{%
706   \section*{\contentsname
707     \@mkboth{\contentsname}{\contentsname}%
708   }\@starttoc{toc}%
709 }
710 \newcommand*{\l@part}[2]{%
711   \ifnum \c@tocdepth >-2\relax
712     \addpenalty{\@secpenalty}%
713     \addvspace{2.25em \@plus\p@}%
714     \begingroup
715     \parindent\z@\rightskip\@pnumwidth
716     \parfillskip-\@pnumwidth
717     {\leavevmode\large\bfseries
718      \setlength\@lnumwidth{4\zw}%
719      #1\hfil\nobreak
720      \hb@xt@\@pnumwidth{\hss#2}}\par
721     \nobreak
722     \if@compatibility
723     \global\@nobreaktrue
724     \everypar{\global\@nobreakfalse\everypar{}}%
725     \fi
726      \endgroup
727   \fi}
728 \newcommand*{\l@section}[2]{%
729   \ifnum \c@tocdepth >\z@
730     \addpenalty{\@secpenalty}%
731     \addvspace{1.0em \@plus\p@}%
732     \begingroup
733       \parindent\z@ \rightskip\@pnumwidth \parfillskip-\rightskip
734       \leavevmode\bfseries
735       \setlength\@lnumwidth{1.5em}%
736       \advance\leftskip\@lnumwidth \hskip-\leftskip
737       #1\nobreak\hfil\nobreak\hb@xt@\@pnumwidth{\hss#2}\par
738     \endgroup
739   \fi}
740 \newcommand*{\l@subsection}   {\@dottedtocline{2}{1\zw}{4\zw}}
741 \newcommand*{\l@subsubsection}{\@dottedtocline{3}{2\zw}{6\zw}}
742 \newcommand*{\l@paragraph}    {\@dottedtocline{4}{3\zw}{8\zw}}
743 \newcommand*{\l@subparagraph} {\@dottedtocline{5}{4\zw}{9\zw}}
744 \newcommand{\listoffigures}{%
745     \section*{\listfigurename}%
746   \@mkboth{\listfigurename}{\listfigurename}%
747   \@starttoc{lof}%
748 }
749 \newcommand*{\l@figure}{\@dottedtocline{1}{1\zw}{4\zw}}
750 \newcommand{\listoftables}{%
751     \section*{\listtablename}%
752   \@mkboth{\listtablename}{\listtablename}%
753   \@starttoc{lot}%
754 }
755 \let\l@table\l@figure
756 \newdimen\bibindent
757 \setlength\bibindent{1.5em}
758 \newcommand{\newblock}{\hskip .11em\@plus.33em\@minus.07em}
759 \newenvironment{thebibliography}[1]
760 {\section*{\refname}\@mkboth{\refname}{\refname}%
761    \list{\@biblabel{\@arabic\c@enumiv}}%
762         {\settowidth\labelwidth{\@biblabel{#1}}%
763          \leftmargin\labelwidth
764          \advance\leftmargin\labelsep
765          \@openbib@code
766          \usecounter{enumiv}%
767          \let\p@enumiv\@empty
768          \renewcommand\theenumiv{\@arabic\c@enumiv}}%
769    \sloppy
770    \clubpenalty4000
771    \@clubpenalty\clubpenalty
772    \widowpenalty4000%
773    \sfcode`\.\@m}
774   {\def\@noitemerr
775     {\@latex@warning{Empty `thebibliography' environment}}%
776    \endlist}
777 \let\@openbib@code\@empty
778 \newenvironment{theindex}
779   {\if@twocolumn\@restonecolfalse\else\@restonecoltrue\fi
780    \twocolumn[\section*{\indexname}]%
781    \@mkboth{\indexname}{\indexname}%
782    \thispagestyle{jpl@in}\parindent\z@
783    \parskip\z@ \@plus .3\p@\relax
784    \columnseprule\z@ \columnsep 35\p@
785    \let\item\@idxitem}
786   {\if@restonecol\onecolumn\else\clearpage\fi}
787 \newcommand{\@idxitem}{\par\hangindent 40\p@}
788 \newcommand{\subitem}{\@idxitem \hspace*{20\p@}}
789 \newcommand{\subsubitem}{\@idxitem \hspace*{30\p@}}
790 \newcommand{\indexspace}{\par \vskip 10\p@ \@plus5\p@ \@minus3\p@\relax}
791 \renewcommand{\footnoterule}{%
792   \kern-3\p@
793   \hrule\@width.4\columnwidth
794   \kern2.6\p@}
795 \newcommand\@makefntext[1]{\parindent 1\zw
796   \noindent\hb@xt@ 2\zw{\hss\@makefnmark}#1}
797 \newif\if西暦 \西暦false
798 \def\西暦{\西暦true}
799 \def\和暦{\西暦false}
800 \newcount\heisei \heisei\year \advance\heisei-1988\relax
801 \def\today{{%
802   \ifnum\ltjgetparameter{direction}=3
803     \if西暦
804       \kansuji\year 年
805       \kansuji\month 月
806       \kansuji\day 日
807     \else
808       平成\ifnum\heisei=1 元年\else\kansuji\heisei 年\fi
809       \kansuji\month 月
810       \kansuji\day 日
811     \fi
812   \else
813     \if西暦
814       \number\year~年
815       \number\month~月
816       \number\day~日
817     \else
818       平成\ifnum\heisei=1 元年\else\number\heisei~年\fi
819       \number\month~月
820       \number\day~日
821     \fi
822   \fi}}
823 \newcommand{\prepartname}{第}
824 \newcommand{\postpartname}{部}
825 \newcommand{\contentsname}{目 次}
826 \newcommand{\listfigurename}{図 目 次}
827 \newcommand{\listtablename}{表 目 次}
828 \newcommand{\refname}{参考文献}
829 \newcommand{\indexname}{索 引}
830 \newcommand{\figurename}{図}
831 \newcommand{\tablename}{表}
832 \newcommand{\appendixname}{付 録}
833 \newcommand{\abstractname}{概 要}
834 \pagestyle{plain}
835 \pagenumbering{arabic}
836 \raggedbottom
837 \fnfixbottomtrue % 2017-02-19
838 \IfFileExists{stfloats.sty}{\RequirePackage{stfloats}\fnbelowfloat}{}
839 \if@twocolumn
840   \twocolumn
841   \sloppy
842 \else
843   \onecolumn
844 \fi
845 \normalmarginpar
846 \@mparswitchfalse
847 \AtBeginOfPackageFile*{ftnright}{\let\ltjt@orig@@makefntext=\@makefntext}
848 \AtEndOfPackageFile*{ftnright}{\let\@makefntext=\ltjt@orig@@makefntext}
849 \endinput
850 %%
851 %% End of file `ltjtarticle.cls'.