OSDN Git Service

ltjsclasses: sync with jsclasses
[luatex-ja/luatexja.git] / src / ltjspf.cls
index 7731e21..51193a7 100644 (file)
@@ -38,7 +38,7 @@
 %%   Right brace   \}     Tilde         \~}
 \NeedsTeXFormat{LaTeX2e}
 \ProvidesClass{ltjspf}
-  [2016/08/03 ltjsclasses ]
+  [2016/08/27 ltjsclasses ]
 \def\jsc@clsname{ltjspf}
 \RequirePackage{luatexja}
 \newif\if@restonecol
@@ -224,6 +224,9 @@ option, since LuaTeX does not support \string\mag\MessageBreak in pdf output}%
 \newif\if@english
 \@englishfalse
 \DeclareOption{english}{\@englishtrue}
+\newif\if@jslogo \@jslogotrue
+\DeclareOption{jslogo}{\@jslogotrue}
+\DeclareOption{nojslogo}{\@jslogofalse}
 \ExecuteOptions{a4paper,twoside,twocolumn,notitlepage,fleqn,final}
 \ProcessOptions
 \if@slide
@@ -458,11 +461,11 @@ option, since LuaTeX does not support \string\mag\MessageBreak in pdf output}%
 \@lowpenalty   51
 \@medpenalty  151
 \@highpenalty 301
-\setlength\topskip{10\jsc@mpt}
+\setlength\topskip{1.38\zh}%% from 10\jsc@mpt (2016-08-17)
 \if@slide
   \setlength\headheight{0\jsc@mpt}
 \else
-  \setlength\headheight{2\topskip}
+  \setlength\headheight{20\jsc@mpt}%% from 2\topskip (2016-08-17); from \topskip (2003-06-26)
 \fi
 \setlength\footskip{9\jsc@mmm}
 \setlength\headsep{9\jsc@mmm}
@@ -504,7 +507,7 @@ option, since LuaTeX does not support \string\mag\MessageBreak in pdf output}%
 \if@slide
   \addtolength\topmargin{-\headheight}
 \else
-  \addtolength\topmargin{-\topskip}
+  \addtolength\topmargin{-0.5\headheight}%% from -\topskip (2016-08-17); from -\headheight (2003-06-26)
 \fi
 \addtolength\topmargin{-\headsep}
 \addtolength\topmargin{-\footskip}
@@ -722,7 +725,9 @@ option, since LuaTeX does not support \string\mag\MessageBreak in pdf output}%
     \@afterheading
   \fi
   \if@slide
-    {\vskip-6\jsc@mpt\maybeblue\hrule height0\jsc@mpt depth1\jsc@mpt\vskip7\jsc@mpt\relax}%
+    {\vskip\if@twocolumn-5\jsc@mpt\else-6\jsc@mpt\fi
+     \maybeblue\hrule height0\jsc@mpt depth1\jsc@mpt
+     \vskip\if@twocolumn 4\jsc@mpt\else 7\jsc@mpt\fi\relax}
   \fi
   \par  % 2000-12-18
   \ignorespaces}
@@ -808,7 +813,7 @@ option, since LuaTeX does not support \string\mag\MessageBreak in pdf output}%
 \fi
 \if@twocolumn
   \newcommand{\subsection}{\@startsection{subsection}{2}{\z@}%
-    {\z@}{\z@}%
+    {\z@}{\if@slide .4\Cvs \else \z@ \fi}%
     {\normalfont\normalsize\headfont}}
 \else
   \newcommand{\subsection}{\@startsection{subsection}{2}{\z@}%
@@ -818,27 +823,33 @@ option, since LuaTeX does not support \string\mag\MessageBreak in pdf output}%
 \fi
 \if@twocolumn
   \newcommand{\subsubsection}{\@startsection{subsubsection}{3}{\z@}%
-    {\z@}{\z@}%
+    {\z@}{\if@slide .4\Cvs \else \z@ \fi}%
     {\normalfont\normalsize\headfont}}
 \else
   \newcommand{\subsubsection}{\@startsection{subsubsection}{3}{\z@}%
     {\Cvs \@plus.5\Cdp \@minus.2\Cdp}%
-    {\z@}%
+    {\if@slide .5\Cvs \@plus.3\Cdp \else \z@ \fi}%
     {\normalfont\normalsize\headfont}}
 \fi
 \if@twocolumn
   \newcommand{\paragraph}{\@startsection{paragraph}{4}{\z@}%
-    {\z@}{-1\zw}% 改行せず 1\zw のアキ
+    {\z@}{\if@slide .4\Cvs \else -1\zw\fi}% 改行せず 1\zw のアキ
     {\normalfont\normalsize\headfont}}
 \else
   \newcommand{\paragraph}{\@startsection{paragraph}{4}{\z@}%
     {0.5\Cvs \@plus.5\Cdp \@minus.2\Cdp}%
-    {-1\zw}% 改行せず 1\zw のアキ
+    {\if@slide .5\Cvs \@plus.3\Cdp \else -1\zw\fi}% 改行せず 1\zw のアキ
+    {\normalfont\normalsize\headfont}}
+\fi
+\if@twocolumn
+  \newcommand{\subparagraph}{\@startsection{subparagraph}{5}{\z@}%
+    {\z@}{\if@slide .4\Cvs \@plus.3\Cdp \else -1\zw\fi}%
+    {\normalfont\normalsize\headfont}}
+\else
+  \newcommand{\subparagraph}{\@startsection{subparagraph}{5}{\z@}%
+    {\z@}{\if@slide .5\Cvs \@plus.3\Cdp \else -1\zw\fi}%
     {\normalfont\normalsize\headfont}}
 \fi
-\newcommand{\subparagraph}{\@startsection{subparagraph}{5}{\z@}%
-   {\z@}{-1\zw}%
-   {\normalfont\normalsize\headfont}}
 \if@slide
   \setlength\leftmargini{1\zw}
 \else
@@ -1208,10 +1219,6 @@ class has defined the old font commands like\MessageBreak
 \def\footnote{\inhibitglue\footnotes@ve}
 \let\footnotemarks@ve=\footnotemark
 \def\footnotemark{\inhibitglue\footnotemarks@ve}
-\renewcommand\@makefnmark{%
-  \unless\ifnum\ltjgetparameter{direction}=3
-    \hbox{}\hbox{\@textsuperscript{\normalfont\@thefnmark}}\hbox{}%
-  \else\hbox{\yoko \@textsuperscript{\normalfont\@thefnmark}}\fi}
 \def\thefootnote{\ifnum\c@footnote>\z@\leavevmode\lower.5ex\hbox{*}\@arabic\c@footnote\fi}
 \renewcommand{\footnoterule}{%
   \kern-3\jsc@mpt
@@ -1311,17 +1318,18 @@ class has defined the old font commands like\MessageBreak
     \unskip \reserved@e {\reserved@f#1}\nobreak \hfil \break \null
     \inhibitglue \ignorespaces
   \fi}
-\IfFileExists{jslogo.sty}{%
+\IfFileExists{jslogo.sty}{}{\@jslogofalse}%
+\if@jslogo
   \RequirePackage{jslogo}
   \def\小{\jslg@small}
   \def\上小{\jslg@uppersmall}
-}{%
-\def\小##1{\hbox{$\m@th$%
+\else
+\def\小#1{\hbox{$\m@th$%
   \csname S@\f@size\endcsname
   \fontsize\sf@size\z@
   \math@fontsfalse\selectfont
-  ##1}}
-\def\上小##1{{\sbox\z@ T\vbox to\ht0{\小{##1}\vss}}}
+  #1}}
+\def\上小#1{{\sbox\z@ T\vbox to\ht0{\小{#1}\vss}}}
 \def\cmrTeX{%
   \ifdim \fontdimen\@ne\font >\z@
     T\kern-.25em\lower.5ex\hbox{E}\kern-.125emX\@
@@ -1446,7 +1454,7 @@ class has defined the old font commands like\MessageBreak
   \ifx\f@family\cmr\kern-.08em\else\kern-.15em\fi\TeX}
 \DeclareRobustCommand{\SliTeX}{%
   S\kern-.06emL\kern-.18em\上小{I}\kern -.03em\TeX}
-}
+\fi
 \newcommand{\prepartname}{\if@english Part~\else 第\fi}
 \newcommand{\postpartname}{\if@english\else 部\fi}
 \newcommand{\presectionname}{}%  第