OSDN Git Service

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