OSDN Git Service

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