| 1 |
\documentclass[DIV=8, pagesize=auto]{scrartcl} |
| 2 |
|
| 3 |
\usepackage{lmodern} |
| 4 |
\usepackage[T1]{fontenc} |
| 5 |
\usepackage{textcomp} |
| 6 |
\usepackage{shortvrb} |
| 7 |
|
| 8 |
\addtokomafont{title}{\rmfamily} |
| 9 |
\MakeShortVerb{"} |
| 10 |
\newcommand*{\meta}[1]{\textlangle\textsl{#1}\textrangle} |
| 11 |
|
| 12 |
\title{The \textsf{anonchap} package} |
| 13 |
\author{Peter Wilson, Herries Press; \\ maintained by Will Robertson} |
| 14 |
\date{2009/08/03} |
| 15 |
|
| 16 |
|
| 17 |
\begin{document} |
| 18 |
|
| 19 |
\maketitle |
| 20 |
|
| 21 |
\begin{abstract} |
| 22 |
Provides commands to make "\chapter" typeset like "\section". |
| 23 |
\emph{Do not use with the \textsf{tocbibind} package} (which also supplies these commands). |
| 24 |
\end{abstract} |
| 25 |
|
| 26 |
|
| 27 |
\section{Change history} |
| 28 |
|
| 29 |
\begin{description} |
| 30 |
\item[v1.1a] New maintainer (Will Robertson) |
| 31 |
\end{description} |
| 32 |
|
| 33 |
|
| 34 |
\section{Usage:} |
| 35 |
|
| 36 |
"\simplechapter["\meta{name}"]" and "\simplechapterdelim{"\meta{delim}"}" act together |
| 37 |
so that any subsequent "\chapter" commands, for example |
| 38 |
% |
| 39 |
\begin{verbatim} |
| 40 |
\chapter{First} ... \chapter{Second}... |
| 41 |
\end{verbatim} |
| 42 |
% |
| 43 |
will be typeset in the style of a "\section" (or numbered "\chapter*") as: |
| 44 |
% |
| 45 |
\begin{quote} |
| 46 |
\meta{name} 1\meta{delim} First\\ |
| 47 |
\ldots\\ |
| 48 |
\meta{name} 2\meta{delim} Second |
| 49 |
\end{quote} |
| 50 |
% |
| 51 |
A subsequent "\restorechapter" command will reset the "\chapter" typesetting |
| 52 |
back to its default style. |
| 53 |
|
| 54 |
Note that the argument to "\simplechapter" is optional, and that by default |
| 55 |
"\simplechapterdelim" is defined as |
| 56 |
% |
| 57 |
\begin{verbatim} |
| 58 |
\newcommand{\simplechapterdelim}{} |
| 59 |
\end{verbatim} |
| 60 |
|
| 61 |
\begin{samepage} |
| 62 |
Extending the above example: |
| 63 |
% |
| 64 |
\begin{verbatim} |
| 65 |
\simplechapter |
| 66 |
\chapter{First} |
| 67 |
... |
| 68 |
\renewcommand{\simplechapterdelim}{:} |
| 69 |
\chapter{Second} |
| 70 |
... |
| 71 |
\restorechapter % restore before issuing |
| 72 |
% a modified \simplechapter |
| 73 |
\simplechapter[Chap] |
| 74 |
\chapter{Third} |
| 75 |
... |
| 76 |
\restorechapter |
| 77 |
\chapter{Fourth} |
| 78 |
... |
| 79 |
\end{verbatim} |
| 80 |
% |
| 81 |
Will be typeset as: |
| 82 |
% |
| 83 |
\begin{quote} |
| 84 |
1 First\\ |
| 85 |
\ldots\\ |
| 86 |
2: Second\\ |
| 87 |
\ldots\\ |
| 88 |
Chap 3: Third\\ |
| 89 |
\ldots\\ |
| 90 |
Chapter 4\\ |
| 91 |
Fourth\\ |
| 92 |
\ldots |
| 93 |
\end{quote} |
| 94 |
\end{samepage} |
| 95 |
|
| 96 |
\end{document} |