その他一覧へ戻る

索引テスト

鉄TeX機能紹介/索引サンプル/カスタマイズ/索引テスト.tex鉄TeX機能紹介hybrid

レンダリング結果

2ページ / 同名PDFあり
索引テスト preview
索引テスト preview
PDFを開く
TeXソース
TeXソース
入力コード
\documentclass[b5j]{tetsujsarticle}

\usepackage{tetsuryoku}

\索引区切り{あいうえお}
%\索引区切り{あかさたな}

\makeatletter

\def\菱形見出し#1{%
\par
\noindent \hfil
  \begin{tikzpicture}[x=1.5cm,y=1.5cm,font=\fsize{25pt}\bgtfamily]
  \draw[dotted,line width=2pt,color=black!50!white] (-0.8,-0.8) rectangle (0.8, 0.8);
  \filldraw[fill=black!70!white,draw=black,thick] (1,0) -- (0,1) -- (-1,0) -- (0,-1) -- cycle;
  \node[white] at (0,0) {#1};
\end{tikzpicture}\par\nopagebreak
}

\renewcommand{\indexspace}{\par \vskip 15\p@ \@plus5\p@ \@minus3\p@\relax}
\renewenvironment{theindex}{%
    \if@twocolumn
      \onecolumn\@restonecolfalse
    \else
      \clearpage\@restonecoltrue
    \fi
    \columnseprule.4pt \columnsep 2zw
    \ifx\multicols\@undefined
      \def\presectionname{}\def\postsectionname{}%
      \twocolumn[\section*{\indexname}]%
    \else
      \ifdim\textwidth<\fullwidth
        \setlength{\evensidemargin}{\oddsidemargin}
        \setlength{\textwidth}{\fullwidth}
        \setlength{\linewidth}{\fullwidth}
        \def\presectionname{}\def\postsectionname{}%
        \begin{multicols}{3}[\section*{\indexname}]%
      \else
        \def\presectionname{}\def\postsectionname{}%
        \columnsep=4zw
        \newpage
        \菱形見出し{索引}%
        \label{索引}%
        \begin{multicols*}{2}%
      \fi
    \fi
    \parindent\z@
    \parskip\z@ \@plus .3\p@\relax
    \let\item\@idxitem
    \raggedright
  }{
    \ifx\multicols\@undefined
      \if@restonecol\onecolumn\fi
    \else
      \end{multicols*}
    \fi
    \clearpage
  }

\makeatother

\makeindex

\begin{document}

ほげ\index{ほげ}と捕鯨\index{ほげい@捕鯨}の違い,ハゲ\index{ハゲ}と禿\index{はげ@禿|see{ハゲ}}の違い。

段階化された索引。
捕鯨委員会\index{ほげい@捕鯨!いいんかい@\ダッシュ 委員会}について。
ノルウェーにおける捕鯨\index{ほげい@捕鯨!のるうぇーにおける@ノルウェーにおける\ダッシュ}の現実。



\printindex


\end{document}