\documentclass[a4paper,twoside,final,titlepage,onecolumn,openrigh t,DIV=12,BCOR=5mm,mpinclude,headinclude]{scrbook}
\usepackage{typearea}
%\setlength\marginparwidth{80pt}
% Zeilenabstand Text 1,5 und Fußnoten 1:
%
http://www.macuser.de/forum/f19/late...endern-189206/
\usepackage{setspace}
\onehalfspacing
\usepackage{fancyhdr}
%\pagestyle{headings}
\pagestyle{fancy}% muss vor \renewcommand{\sectionmark} stehen
\fancyhf{}
\fancyfoot[EL]{\thepage}% gerade Seiten, links
\fancyhead[OR]{\leftmark}% gerade Seiten, rechts
\fancyhead[EL]{\rightmark}% ungerade Seiten, links
\fancyfoot[OR]{\thepage}% ungerade Seiten, rechts
\fancyhfoffset[OR]{95pt}
\fancyhfoffset[EL]{95pt}
\renewcommand{\headrulewidth}{0.4pt} % Rand nach Header bzw. Strich unter dem Header
% Chapter im Header
\renewcommand{\chaptermark}[1]{
\markboth{\thechapter{} #1}{}
}
% Sektion im Header
\renewcommand{\sectionmark}[1]{
\markright{\thesection{} #1}{}
}
% bindet Tabellen- und Abbildungsverzeichnis in das Inhaltsverzeichnis ein.
\usepackage[nottoc]{tocbibind}
% Kleinschrift "Tabellen- und Abbildungsverzeichnis" anstatt in GROSSSCHRIFT
\renewcommand{\tocetcmark}[1]{\markboth{#1}{}}
\renewcommand{\tocetcmark}[1]{\markright{#1}{}}
\usepackage{parskip} % Absätze aktivieren
\setlength{\parindent}{0,5cm} % Einzug
\setlength{\parskip}{14pt} % Abstand
%********** Markus Kohm:
http://www.komascript.de/node/1232**********
\usepackage[svgnames]{xcolor}
\usepackage{eso-pic}
%********** Markus Kohm:
http://www.komascript.de/node/1232**********
\usepackage{marginnote}
\addtolength{\marginparsep}{10pt}
\addtolength{\marginparwidth}{\marginparwidth}
\renewcommand*{\marginfont}{\strut\hskip-1em % Das ist erst einmal ein
% gemeiner Trick zur korrekten Ausrichtung
% kleiner Fontgrößen mit abweichendem
% Zeilenabstand.
\linespread{1}\small\color{DarkBlue}% Das ist der Rest.
}
\newif\ifvisualmargin\visualmargintrue
\AddToShipoutPicture{%
\ifvisualmargin
\ifodd\value{page}
\AtTextLowerLeft{%
\put(\LenToUnit{\dimexpr\textwidth+\marginparsep-10pt\relax},0){%
\color{Blue}\thicklines\line(0,1){\LenToUnit{\text height}}%
}%
\put(\LenToUnit{\dimexpr\textwidth+\marginparsep-1pt\relax},0){%
\color{White}%
\rule{\dimexpr\marginparwidth+2pt\relax}{\textheig ht}%
}%
}%
\else
\AtTextLowerLeft{%
\put(\LenToUnit{\dimexpr-\marginparsep+10pt\relax},0){% Geänderte Positionierung
\color{Blue}\thicklines\line(0,1){\LenToUnit{\text height}}%
}%
\put(\LenToUnit{\dimexpr-\marginparwidth-\marginparsep-1pt\relax},0){% Geänderte Positionierung
\color{White}%
\rule{\dimexpr\marginparwidth+2pt\relax}{\textheig ht}%
}%
}%
\fi
\fi
}
% - keine blaue Linie auf ``part'' -
http://www.mrunix.de/forums/showthre...747#post309747
\usepackage{etoolbox}
\makeatletter
\preto\part{\clearpage\visualmarginfalse}
\appto\@endpart{\visualmargintrue}
\makeatother
% "part" Seite ohne Seitenzahl
\renewcommand*{\partpagestyle}{empty}
% "part" erscheint im Inhaltsverzeichnis, NICHT aber mit Seitenzahl
\makeatletter
\let\partbackup\l@part
\renewcommand*\l@part[2]{\partbackup{#1}{}}
\makeatother
\usepackage{ucs}
\usepackage[utf8x]{inputenc}
\usepackage[osf]{mathpazo}
\usepackage{pst-all}
\usepackage{rotating}
\usepackage{subfigure}
\usepackage[english,german,ngerman]{babel}
\usepackage{ragged2e,calc}
\usepackage{graphicx}
% Fußnote - Abstand zwischen Nummer der FN und dem Text
\deffootnote{1.5em}{1em}{
\makebox[1.5em][l]{\thefootnotemark}}
% schließt Schusterjungen/Hurenkinder aus
\clubpenalty = 10000
\widowpenalty = 10000
%Formatiert die Bildunterschriften
\usepackage{caption}
\renewcommand{\captionfont}{\small\itshape}
\usepackage{makeidx}
\makeindex
\newcommand{\Index}[1]{#1\index{#1}} %Vereinfachung Indexerstellung
\usepackage[round]{natbib}
\usepackage{url}
% --> Vorspann im Inhaltsverzeichnis wie eine Sektion anzeigen, aber mit Ausrichtung chapter --
http://www.mrunix.de/forums/showthread.php?t=67624
\usepackage{tocstyle}
\usetocstyle{KOMAlike}
\settocstylefeature[-1]{entryhook}{\large\sffamily\bfseries}% Bug-Korrektur
\makeatletter
\newcommand*{\toplevelentriesspecial}{%
\vspace{1em plus 1pt}%
\settocstylefeature[0]{entryvskip}{0pt}%
\settocstylefeature[0]{entryhook}{}%
\settocstylefeature[0]{leaders}{%
\leaders\hbox{$\m@th \mkern \@dotsep mu\hbox{\tocstyle@feature@dothook .}%
\mkern \@dotsep mu$}\hfill
}%
}
\newcommand*{\toplevelentriesnormal}{%
\settocstylefeature[0]{entryvskip}{1em plus 1pt}%
\settocstylefeature[0]{entryhook}{\sffamily\bfseries}%
\settocstylefeature[0]{leaders}{\hfill}%
}
\g@addto@macro{\frontmatter}{\addtocontents{toc}{\ protect\toplevelentriesspecial}}
\g@addto@macro{\mainmatter}{\addtocontents{toc}{\p rotect\toplevelentriesnormal}}
\g@addto@macro{\backmatter}{\addtocontents{toc}{\p rotect\toplevelentriesspecial}}
\makeatother
\begin{document}
\frontmatter
%\addchap{testchap}
\input{geleitwort}
\input{vorwort}
\input{abstract}
\tableofcontents
\listoffigures %\addcontentsline{listoffigures}{chapter}{Abbildun gsverzeichnis}
\input{abkuerzungsverzeichnis}
\cleardoublepage
\mainmatter
\include{k1}
\include{kap1}
\include{k2}
\include{kap2}
\include{kap3}
\include{k4}
\include{kap4}
\include{k5}
\include{kap5}
\include{kap6}
\backmatter
\input{anhang}%\addtocontents{toc}
\bibliographystyle{natdin}
\bibliography{OSSBuch}
\newpage
\renewcommand{\indexname}{Stichwortverzeichnis}
\printindex
\end{document}
Lesezeichen