我正在尝试为每个目录设置单独的目录\part
。为此,我使用了以下代码:
\usepackage{titletoc}
在主文档的序言中,我包含了 3 个文件(每个部分一个):
\include{volume1}%
\include{volume2}%
\include{volume3}%
每个文件均具有以下结构:
\cleardoublepage
\setcounter{page}{1}
\startlist{toc}
\printlist{toc}{}{\section*{My 1. toc}}
\input{Text/Teil1}
\input{Text/Teil2}
\input{Text/Teil3}
\input{Text/Teil4}
\input{Text/Teil5}
\addcontentsline{toc}{part}{Bibliographie}
\phantomsection%
\chapter*{Quellen}%
\fancyhead[L]{Quellen}%
\addcontentsline{toc}{section}{Quellen}%
\thispagestyle{empty}%
\renewcommand*{\bibfont}{\footnotesize}
\printbibliography[title={A.\,Christliche und nichtchristliche Autoren},keyword=source,heading=subbibliography]%
\printbibliography[title={B.\,Synodaltexte und Rechtsquellen},keyword=source; law,heading=subbibliography]%
\printbibliography[title={C.\,Liturgica},keyword=source; liturgy,heading=subbibliography]%
\phantomsection%
\fancyhead[L]{Lexika und Hilfsmittel}%
\addcontentsline{toc}{section}{Lexika und Hilfsmittel}%
\thispagestyle{myheadings}%
\printbibliography[title={Lexika und Hilfsmittel},keyword=lexical,heading=bibliography]%
\phantomsection%
\fancyhead[L]{Sekundärliteratur}%
\thispagestyle{myheadings}%
\addcontentsline{toc}{section}{Sekundärliteratur}%
\printbibliography[title={Sekundärliteratur},keyword=secondary,heading=bibliography]%
我得到的输出看起来很正常,除了在每个小目录的末尾或开头我得到了这个:
我究竟做错了什么?
\include
我也尝试将所有内容放在主文档中(我认为这可能与所有内容和事物有关\input
)并删除参考书目,但输出是相同的。
有任何想法吗?
更新:我在这里发布我的主要文档,它实际上不是 MWE,但它可以用于测试目的(我添加了lipsum
包,因此如果您编译它,您将收到该错误)。
\documentclass[10pt,a5paper]{scrbook}%
%
% PAGE SIZE
%
\usepackage[centering,includeheadfoot,text={113mm,173mm}]{geometry}
\usepackage[polutonikogreek,ngerman]{babel}%
\usepackage[utf8]{inputenc}%
\usepackage[T1]{fontenc}%
\usepackage{textcomp}%
\usepackage{longtable}%
\usepackage{tabularx}%
\usepackage{array}%
\usepackage{float}%
\usepackage{textcomp}%
\usepackage{setspace}%
\usepackage{tabto}%
\usepackage{fancyhdr}%
%\usepackage[cam,a4,center,dvips]{crop}% for rotating crop marks%
\usepackage{graphicx}%
\usepackage{nameref}%
\usepackage{rotating}%
\usepackage[textwidth=2cm, textsize=tiny, backgroundcolor=white, linecolor=black]{todonotes}%
\usepackage{acronym}
\usepackage{bookmark}
\usepackage{makeidx}%
\usepackage{xcolor}%
\usepackage{mdwlist}%
\usepackage{titlesec}%
\usepackage{titletoc}
\usepackage{lipsum}
\usepackage[normalem]{ulem}% Strikethrough text
%
% CROP MARKS FOR PRINTING
%
\usepackage[cam,a4,center]{crop}
\topmargin -16mm
%
%
% TABLE OF CONTENT DEPTH
%
\setcounter{tocdepth}{3}
%
% SECTIONS NUBERING
%
\setcounter{secnumdepth}{4}
%
% TEXT SPACING%
%
%\renewcommand{\baselinestretch}{1.5}%
%\renewcommand{\arraystretch}{1.5}%
\renewcommand{\baselinestretch}{1.25}%
\renewcommand{\arraystretch}{1.25}%
%
% SPACE BETWEEN THE FOOTNOTES
%
\setlength{\footnotesep}{0cm}
%
% SPACE BETWEEN THE TEXT BODY AND THE FOOTNOTES
%
%\setlength{\skip\footins}{0.5cm}
%
% SETS HOW OFTEN FOOTNOTE BREAKS
%
\interfootnotelinepenalty=-300% Default value 100
%
% FOOTNOTE-NUMBERS RESET FOR EACH PART OF THE WORK
%
\usepackage{chngcntr}
\counterwithin*{footnote}{part}
%
% SAME FOOTNOTE SIZE ALL ARROUND
%
\makeatletter
\renewcommand\@makefnmark{%
\hbox{\ftntm@font\raisebox{\adjust@fnmheight}{\scriptsize\thefootnotemark}}%
}
\newcommand{\adjust@fnmheight}{%
\dimexpr.85ex+.3\dimexpr\f@size pt-\basic@size pt\relax\relax
}
\AtBeginDocument{\edef\basic@size{\f@size}}
\makeatother
%
% ALLIGN FOOTNOTE IN KOMA-SCRIPT
%
\deffootnote{1em} {1em}{\textsuperscript{\thefootnotemark\ }}
%
%
% GREEK AND LATIN
%
\newcommand{\grk}[1]{{\foreignlanguage{polutonikogreek}{#1}}}%
\newcommand{\lat}[1]{\emph{{#1}}}%
%
% PART NO DOT
%
\renewcommand*{\partformat}{\partname~\thepart}
\renewcommand*{\partpagestyle}{empty}
%
% PART ORNAMENT
%
% \renewcommand\partheadmidvskip{%
% \par\nobreak\vspace*{\baselineskip}%
% \includegraphics[width=.4\textwidth]{Abbildungen/ornament.png}
% \par\nobreak\vspace*{\baselineskip}%
% }
%
%
% FANCY CHAPTER STYLE
%
\usepackage[Lenny]{fncychap}
\DeclareOldFontCommand{\rm}{\normalfont\rmfamily}{\mathrm}
%
% NEW CROSSREF COMMAND FOR CROSSREFERENCING VOLUMES
%
\usepackage[counter,user,hyperref]{zref}
\makeatletter
\AtBeginDocument{%
\@ifpackageloaded{hyperref}{%
}{
\providecommand{\phantomsection}{}
\providecommand{\hyperlink}[2]{#2}
}
\zref@newlist{partpage}
\zref@newprop*{partprop}[-1]{\number\value{part}}
\zref@addprops{partpage}{partprop,page,anchor} % page is defined by default!
%\newcounter{herecntr}
\newcommand{\here}[1]{%
\phantomsection% Needed for correct hyper links
\zref@labelbyprops{#1}{partprop,page,anchor}%
}
\newcommand{\crossref}[1]{%
\ifnum\value{part}=\zref@extract{#1}{partprop}\relax% Check whether the current part counter value is the same as the extracted part property from the label
S. \hyperlink{\zref@extract{#1}{anchor}}{\zpageref{#1}}
\else% No, it is not the same!
Christologie und Kommunion, Bd. \zref[partprop]{#1}, S. \hyperlink{\zref@extract{#1}{anchor}}{\zpageref{#1}}%
\fi
}
}
\makeatother
%
% BIBLATEX:%
%
\usepackage[style=historische-zeitschrift, maxnames=2, hyperref=false, backref=true, backrefstyle=none, backend=bibtex,idemtracker=true]{biblatex}% change to hyperref=true to get clickable links
\usepackage[babel,german=quotes]{csquotes}%
\bibliography{Inhalt}
%
% CHANGING (Wie...) to (wie)%
%
\DeclareFieldFormat*{title}{#1\isdot}%
%
%
% HISTORISCHE ZEITSCHRIFT - NEW MACRO FOR SHORTVOLUME CITE
%
\makeatletter%
\renewbibmacro*{footcite}{%
\global\boolfalse{cbx@loccit}%
\global\boolfalse{cbx@seenote}% NEW!%
\ifciteseen%
{\iffieldundef{shorthand}%
{\ifthenelse{\ifciteibid\AND\NOT\iffirstonpage}%
{\usebibmacro{footcite:ibid}}%
{\usebibmacro{footcite:note}}}%
{\usebibmacro{footcite:shorthand}}}%
{\iffieldundef{shortseries}%
{\usebibmacro{footcite:full}}%
{\printnames{author}%
\setunit{\addcomma\space}%
\printfield{title}\isdot%
{\setunit{\addcomma\space}%
\usebibmacro{in:}%
\printfield{shortseries}%
\setunit*{\addspace}%
\printfield[default]{number}}}%
\usebibmacro{footcite:save}}%
}%
\makeatother%
%
\makeatletter%
\renewbibmacro*{footcite:note}{%
\global\booltrue{cbx@seenote}% NEW!%
\ifnameundef{labelname}%
{\printfield{label}}%
{\printnames{labelname}}%
\ifsingletitle%
{}%
{\setunit*{\addcomma\space}%
\printfield[title]{labeltitle}}%
\setunit*{\addspace}%
\printtext{%
\bibhyperlink{\thefield{entrykey}:%
\@nameuse{cbx@first@\thefield{entrykey}}}{%
\printtext{\bibleftparen}%
\bibstring{seenote}\addnbspace%
\@nameuse{cbx@note@\thefield{entrykey}}%
% \setunit{\addcomma\space}%
\addcomma\addnbspace%
\bibstring{page}\addnbspace% THIS IF YOU WANT S. X
\@nameuse{cbx@page@\thefield{entrykey}}}}}%
\makeatother%
%
\makeatletter%
\renewbibmacro*{footcite:save}{%
\ifundef\@thefnmark%
{\ifundef\@theenmark % endnotes.sty%
{\csgdef{cbx@note@\thefield{entrykey}}{%
\BibliographyWarning{Missing footnote mark}\textbf{??}}}%
{\global\cslet{cbx@note@\thefield{entrykey}}\@theenmark}}%
{\global\cslet{cbx@note@\thefield{entrykey}}\@thefnmark}%
\csxdef{cbx@page@\thefield{entrykey}}{\thepage}%
\csxdef{cbx@first@\thefield{entrykey}}{\the\value{instcount}}}%
\makeatother%
%
% HISTORISCHE ZEITSCHRIFT - FIXING "( HRSG.)" TO " (HRSG.)"%
%
\makeatletter%
\renewbibmacro*{editorstrg}{%
\ifthenelse{\value{editor}>1\OR\ifandothers{editor}}%
{\bibstring[\mkbibparens]{editors}}%
{\bibstring[\mkbibparens]{editor}}}%
\makeatother%
%
% HISTORISCHE ZEITSCHRIFT - PUBLISHER IN BIBLIOGRAPHY NOT OMMITED%
%
\makeatletter%
\renewbibmacro*{publisher+location+year}{%
\printlist{location}:%
\setunit*{\addspace}%
\printlist{publisher}\addcomma%
\setunit*{\addspace}%
\printfield{year}%
\newunit}%
\makeatother%
%
% HISTORISCHE ZEITSCHRIFT - NO PAGES IN INCOLLECTION FOOTNOTES BUT PAGES IN BIBLIOGRAPHY%
%
\renewbibmacro*{chapter+pages}{%
\printfield{chapter}%
\newunit}%
%
% HISTORISCHE ZEITSCHRIFT - NO PAGES IN ARTICLE FOOTNOTES BUT PAGES IN BIBLIOGRAPHY%
%
\newbibmacro*{onlypages}{%
\printfield{chapter}%
\newunit}
\DeclareBibliographyDriver{article}{%
\usebibmacro{bibindex}%
\usebibmacro{author/editor}%
\setunit{\labelnamepunct}\newblock
\usebibmacro{title}%
\newunit
\usebibmacro{byauthor}%
\newunit
\printlist{language}%
\newunit\newblock
\usebibmacro{byeditor+others}%
% \newunit\newblock
\setunit{\addcomma\space}%
\usebibmacro{in:}%
\usebibmacro{journal+issuetitle}%
% \newunit\newblock
\setunit*{\addcomma\space}%
\printfield{note}%
% \newunit\newblock
\setunit*{\newunitpunct}%
\usebibmacro{onlypages}%
\newunit\newblock%
\usebibmacro{doi+eprint+url}%
\newunit\newblock%
\printfield{addendum}%
\newunit\newblock
\usebibmacro{pageref}%
\usebibmacro{finentry}}
%
% HISTORISCHE ZEITSCHRIFT - ADDING ZITIERT AUF INSTEAD OF SIEHE S. IN BIBLIOGRAPHY
%
\DefineBibliographyStrings{ngerman}{
backrefpage = {Zitiert auf S\adddot},
backrefpages = {Zitiert auf S\adddot},
}
%
% EPIGRAPHS%
%
\usepackage{epigraph}%
\setlength{\epigraphwidth}{10cm}%changes the width of epigraph text%
\renewcommand{\epigraphsize}{\small}%changes the size of epigraph text%
\renewcommand{\epigraphrule}{0 pt}% removes the line. if you want it set: put number inside {}%
\renewcommand{\textflush}{flushepinormal}%changes formating to justified%
\let\tmpepigraph=\epigraph
\renewcommand{\epigraph}[2]%
{{\onehalfspacing\tmpepigraph{#1}{#2}}}%
%
% CHANGING QUOTE WIDTH
%
\renewenvironment{quote}{%
\list{}{%
\leftmargin0.35cm % this is the adjusting screw%
\rightmargin\leftmargin%
\onehalfspacing\small%
}%
\item\relax%
}%
{\endlist}%
%
% CHANGING ENUMERATE WIDTH
%
\let\oldenumerate=\enumerate%
\let\endoldenumerate=\endenumerate%
\renewenvironment{enumerate}{%
\leftmargin0.35cm % this is the adjusting screw%
\rightmargin\leftmargin%
\onehalfspacing\small
\begin{oldenumerate}%
\setlength{\parskip}{0.1\parskip}%
\setlength{\itemsep}{0.1\itemsep}%
}%
{%
\end{oldenumerate}%
}%
%
% CHANGING ITEMIZE
%
\let\olditemize=\itemize%
\let\endolditemize=\enditemize%
\renewenvironment{itemize}{%
\vspace*{-1.5\parsep}%
\leftmargin0.35cm% this is the adjusting screw%
\rightmargin\leftmargin%
\onehalfspacing\small
\begin{olditemize}%
\setlength{\parskip}{0.1\parskip}%
\setlength{\itemsep}{0.1\itemsep}%
}%
{%
\end{olditemize}%
}%
%
%
% SMALLENUMERATE FOR LITURGY PART
%
\newenvironment{smallenumerate}{%
\footnotesize%
\enumerate%
\setlength{\parskip}{0.1\parskip}%
\setlength{\itemsep}{0.1\itemsep}%
}{%
\endenumerate%
}%
%
% SMALLITEMIZE FOR LITURGY PART%
%
\newenvironment{smallitemize}{%
\footnotesize%
\itemize%
\setlength{\parskip}{0.1\parskip}%
\setlength{\itemsep}{0.1\itemsep}%
}{%
\enditemize%
}%
%
%
% IDENT FULL PARAGRAPH%
%
\newenvironment{myindentpar}[1]%
{\begin{list}{}%
{\setlength{\leftmargin}{#1}}%
\item[]%
}%
{\end{list}}%
%
% PARAGRAPHS WITHOUT NUMBERS (requires titlesec)
%
\titleclass{\subsubsubsection}{straight}[\subsection]%
%
\newcounter{subsubsubsection}%
\renewcommand\thesubsubsubsection{\thesubsubsection.\arabic{subsubsubsection}}%
\renewcommand\theparagraph{\thesubsubsubsection.\arabic{paragraph}} % optional; useful if paragraphs are to be numbered%
%
\titleformat{\subsubsubsection}%
{\normalfont\normalsize\sffamily\bfseries}{\thesubsubsubsection}{1em}{}%
\titlespacing*{\subsubsubsection}%
{0pt}{3.25ex plus 1ex minus .2ex}{1.5ex plus .2ex}%
%
\makeatletter%
\renewcommand\paragraph{\@startsection{paragraph}{5}{\z@}%
{3.25ex \@plus1ex \@minus.2ex}%
{-1em}%
{\normalfont\normalsize\bfseries}}%
\renewcommand\subparagraph{\@startsection{subparagraph}{6}{\parindent}%
{3.25ex \@plus1ex \@minus .2ex}%
{-1em}%
{\normalfont\normalsize\bfseries}}%
\def\toclevel@subsubsubsection{4}%
\def\toclevel@paragraph{5}%
\def\toclevel@paragraph{6}%
\def\l@subsubsubsection{\@dottedtocline{4}{7em}{4em}}%
\def\l@paragraph{\@dottedtocline{5}{10em}{5em}}%
\def\l@subparagraph{\@dottedtocline{6}{14em}{6em}}%
\makeatother%
%
% BOLD ENUMERATE%
%
\newenvironment{boenumerate}%
{\begin{enumerate}\renewcommand\labelenumi{\textbf\theenumi}}%
{\end{enumerate}}%
%
%
% HYPERREF - LINKS IN TOC%
%
%
\usepackage{hyperref}%this package must be the last one from all loaded packages%
\hypersetup{%
colorlinks,%
citecolor=black,%
filecolor=black,%
linkcolor=black,%
urlcolor=black,%
hypertexnames=false% this is required because pages of each volume start with nr. 1 otherwise it will confuse hyperref
}%
\usepackage[all]{hypcap}% THIS IS FIXING ERROR WITH HYPERRREF SHOWING BELOW THE IMAGE this package must be the last after hyperref%
%
%
%
\begin{document}%
%
\frontmatter
% \newpage\thispagestyle{empty}\mbox{}\newpage
\newpage\thispagestyle{empty}\mbox{}\newpage
%
% HEADER:%
%
% \renewcommand{\chaptermark}[1]{\markright{\thechapter.\ #1}}%
\fancyhead[LE]{\thepage}% Left even (moze i centar sa C)
\fancyhead[RE]{\nouppercase{\rightmark}}% Right even
\fancyhead[LO]{\nouppercase{\rightmark}}% Left odd
\fancyhead[RO]{\thepage}% Right odd
\renewcommand{\headrulewidth}{0.1pt}
\pagestyle{fancy}%
\lfoot{}%
\cfoot{}%
%
% NO TITLE WHERE THERE IS ANOTHER TITLE%
%
\fancypagestyle{myheadings}{\lhead{}}%
%
% CONTENS:%
%
% \pagenumbering{roman}%
%
% STRUCTURE
%
% \include{Text/Einleitung/vorwort}%
\thispagestyle{fancy}%
%
% TABLE OF CONTENT
%
\begingroup
\begin{spacing}{1.5}%
% \let\clearpage\relax
\tableofcontents%{\nouppercase}%
\end{spacing}%
\endgroup
\cleardoublepage%
%
\mainmatter
% \include{Text/Unsorted/struktur}%
\cleardoublepage
\setcounter{page}{1}
\startlist{toc}
\printlist{toc}{}{\section*{My 1. toc}}
\part{1}
\lipsum
\chapter{1}
\lipsum
\section{1}
\lipsum
\subsection{1}
\lipsum
\paragraph{1}
\lipsum
\addcontentsline{toc}{part}{Bibliographie}
\phantomsection%
\chapter*{Quellen}%
\fancyhead[L]{Quellen}%
\addcontentsline{toc}{section}{Quellen}%
\thispagestyle{empty}%
\renewcommand*{\bibfont}{\footnotesize}
\printbibliography[title={A.\,Christliche und nichtchristliche Autoren},keyword=source,heading=subbibliography]%
\printbibliography[title={B.\,Synodaltexte und Rechtsquellen},keyword=source; law,heading=subbibliography]%
\printbibliography[title={C.\,Liturgica},keyword=source; liturgy,heading=subbibliography]%
\phantomsection%
\fancyhead[L]{Lexika und Hilfsmittel}%
\addcontentsline{toc}{section}{Lexika und Hilfsmittel}%
\thispagestyle{myheadings}%
\printbibliography[title={Lexika und Hilfsmittel},keyword=lexical,heading=bibliography]%
\phantomsection%
\fancyhead[L]{Sekundärliteratur}%
\thispagestyle{myheadings}%
\addcontentsline{toc}{section}{Sekundärliteratur}%
\printbibliography[title={Sekundärliteratur},keyword=secondary,heading=bibliography]%
\cleardoublepage
\setcounter{page}{1}
\startlist{toc}
\printlist{toc}{}{\section*{My 1. toc}}
\part{2}
\lipsum
\chapter{2}
\lipsum
\section{2}
\lipsum
\subsection{2}
\lipsum
\paragraph{2}
\lipsum
\addcontentsline{toc}{part}{Bibliographie}
\phantomsection%
\chapter*{Quellen}%
\fancyhead[L]{Quellen}%
\addcontentsline{toc}{section}{Quellen}%
\thispagestyle{empty}%
\renewcommand*{\bibfont}{\footnotesize}
\printbibliography[title={A.\,Christliche und nichtchristliche Autoren},keyword=source,heading=subbibliography]%
\printbibliography[title={B.\,Synodaltexte und Rechtsquellen},keyword=source; law,heading=subbibliography]%
\printbibliography[title={C.\,Liturgica},keyword=source; liturgy,heading=subbibliography]%
\phantomsection%
\fancyhead[L]{Lexika und Hilfsmittel}%
\addcontentsline{toc}{section}{Lexika und Hilfsmittel}%
\thispagestyle{myheadings}%
\printbibliography[title={Lexika und Hilfsmittel},keyword=lexical,heading=bibliography]%
\phantomsection%
\fancyhead[L]{Sekundärliteratur}%
\thispagestyle{myheadings}%
\addcontentsline{toc}{section}{Sekundärliteratur}%
\printbibliography[title={Sekundärliteratur},keyword=secondary,heading=bibliography]%
\cleardoublepage
\setcounter{page}{1}
\startlist{toc}
\printlist{toc}{}{\section*{My 1. toc}}
\part{3}
\lipsum
\chapter{3}
\lipsum
\section{3}
\lipsum
\subsection{3}
\lipsum
\paragraph{3}
\lipsum
\addcontentsline{toc}{part}{Bibliographie}
\phantomsection%
\chapter*{Quellen}%
\fancyhead[L]{Quellen}%
\addcontentsline{toc}{section}{Quellen}%
\thispagestyle{empty}%
\renewcommand*{\bibfont}{\footnotesize}
\printbibliography[title={A.\,Christliche und nichtchristliche Autoren},keyword=source,heading=subbibliography]%
\printbibliography[title={B.\,Synodaltexte und Rechtsquellen},keyword=source; law,heading=subbibliography]%
\printbibliography[title={C.\,Liturgica},keyword=source; liturgy,heading=subbibliography]%
\phantomsection%
\fancyhead[L]{Lexika und Hilfsmittel}%
\addcontentsline{toc}{section}{Lexika und Hilfsmittel}%
\thispagestyle{myheadings}%
\printbibliography[title={Lexika und Hilfsmittel},keyword=lexical,heading=bibliography]%
\phantomsection%
\fancyhead[L]{Sekundärliteratur}%
\thispagestyle{myheadings}%
\addcontentsline{toc}{section}{Sekundärliteratur}%
\printbibliography[title={Sekundärliteratur},keyword=secondary,heading=bibliography]%
%
% APPENDIX%
%
%\appendix%
%\chapter{Anhangspunkt/anhangspunkt}%
%
% BIBLIOGRAPHY:%
%
% PUTTING OLD BIBLIOGRAPHY BACK WITH INCOLLECTION PAGES IN IT
\renewbibmacro*{chapter+pages}{%
\printfield{chapter}%
\setunit*{\addcomma\space}%
\printfield{pages}%
\newunit}%
%
% PUTTING OLD BIBLIOGRAPHY BACK WITH ARTICLE PAGES IN IT
\renewbibmacro*{onlypages}{%
\printfield{chapter}%
\setunit*{\addcomma\space}%
\printfield{pages}%
\newunit}%
%
\end{document}%