OSDN Git Service

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