## Artikel-Schlagworte: „LaTeX“

Cropping marks are important for print versions of documents. In LaTeX, this can be done with various options of document classes. However, sometimes the packages one uses do not fit together – especially in cases when only some parts of a package are interesting/ needed and other parts of other packages.

The following preamble describes the conjoint use of ‚memoir‘ document class and the packages ‚geometry‘ and ‚crop‘:

\DisemulatePackage{crop} %to allow package 'crop'
\setstocksize{297mm}{210mm} %a4 paper as base -> redundant
\settrimmedsize{210mm}{148mm}{*} %use only a5paper area
% -> redundant
\usepackage[driver=none]{geometry} %to allow usage of 'crop'
\geometry{paper=a4paper,layout=a5paper,centering,
textwidth=100mm, textheight=147mm} %text area


In the text, just use the following LaTeX command:

\crop[cam]


to get plain cropping marks. Other options are available and can be get from the respective manuals.

crop marks with LaTeX

I like efficient but also nice looking page styles. One important thing for me is to see chapter as well as section-/ sub-section titles together with page numbers on the same vertical level. This looks like the following:

latex page style

You will see that the page numbers are outside the text area. This can be accomplished while working with ‚memoir class‘ with the following code in the preamble that produces a page style:

%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% User specified LaTeX commands.
\makepagestyle{abook}
\makerunningwidth{abook}{1.2\textwidth}
% PW
\makeatletter
\def\brule{\rule[1.5em]{\textwidth}{0.4pt}}
% LG
%%%%%%%%%%%%%%%%%%%%%%%%%%%%\makeatletter % because of \@chapapp
\makepsmarks {abook}{
\createmark {chapter} {both} {shownumber}{\@chapapp\ }{. \ }
\createmark {section} {right}{shownumber}{} {. \ }
\createmark {subsection} {right}{shownumber}{} {. \ }
\createmark {subsubsection}{right}{shownumber}{} {. \ }
\createplainmark {toc} {both} {\contentsname}
\createplainmark {lof} {both} {\listfigurename}
\createplainmark {lot} {both} {\listtablename}
\createplainmark {bib} {both} {\bibname}
\createplainmark {index} {both} {\indexname}
\createplainmark {glossary} {both} {\glossaryname}
}
\makeatother
\setsecnumdepth{subsubsection}
\pagestyle{abook}

The output can be seen here as .pdf and the .tex file is here. Thanks to Lars Madsen and Peter Wilson for their help to realize that. If you work with komascript, it is easy as well. The following code is necessary for the preamble:

\documentclass[oneside,english,ngerman]{scrbook}
\usepackage[T1]{fontenc}
\usepackage[latin9]{inputenc}
\setcounter{secnumdepth}{3}
\setcounter{tocdepth}{3}
\usepackage{scrpage2}
}