0

I would like to have the title (or rather "section") "Appendix" (German: Anhang) right at the top of the page as it is, but with the pdf, I tried to include as an appendix, following right away without having a forced pagebreak.

Is this possible? Currently it looks like this: Output

Thank you very much in advance!

\documentclass[12pt,a4paper,headings=standardclasses,numbers=noenddot]{scrartcl}
\usepackage{showframe}
\usepackage[left=2.50cm, right=2.50cm, top=2.50cm, bottom=2.00cm, footskip=1cm]{geometry}
\usepackage[onehalfspacing]{setspace}
\usepackage[main=ngerman, english]{babel}
\usepackage[babel, german=quotes]{csquotes}
\usepackage[ngerman]{isodate}
\usepackage[ngerman]{datetime}

\renewcommand\sectionformat{\mbox{\thesection.\enskip$|$\enskip}}% <- changed
\usepackage[ngerman]{datetime}

\RedeclareSectionCommand[
  beforeskip=2\baselineskip,% changed to a positive value, if afterindent=false is set (needs version 3.26b)
  afterindent=false,% < - added, needs version 3.26b
  afterskip=.5\baselineskip,
  tocentrynumberformat=\def\autodot{.} % replace \autodot by a fixed dot for section entries
   ]{section}

\RedeclareSectionCommand[
  beforeskip=-1\baselineskip,
  afterskip=.5\baselineskip]{subsection}

\RedeclareSectionCommand[
  beforeskip=-1\baselineskip,
  afterskip=.5\baselineskip]{subsubsection}

\RedeclareSectionCommand[
  beforeskip=-1\baselineskip,
  afterskip=.5\baselineskip]{paragraph}

\RedeclareSectionCommand[
  beforeskip=-1\baselineskip,
  afterskip=.5\baselineskip]{subparagraph}
  \usepackage{authblk}
%----------------------------------------------------------------------------
%   APPENDICES
%----------------------------------------------------------------------------
\newcommand*\appendixmore{% see the KOMA-Script documentation
  \clearpage
  \addsec{\appendixname}%
  \renewcommand{\thesubsection}{\Alph{subsection}}%
}
%----------------------------------------------------------------------------
%   FIGURES
%----------------------------------------------------------------------------
\usepackage{graphicx}
\graphicspath{ {./figures/} }
\usepackage{lscape}
%\usepackage{booktabs}
\usepackage[final]{pdfpages}
\usepackage{chngcntr}
\renewcommand{\listfigurename}{Abbildungsverzeichnis}
\renewcommand{\figurename}{Abb.}
\counterwithout{figure}{section}
\renewcommand{\listtablename}{Tabellenverzeichnis}
\renewcommand{\tablename}{Tab.}
\counterwithout{table}{section}
\begin{document}
\appendix
%\input{figures}
%\pagebreak
%\input{tables}
%\pagebreak
\includepdf[pages=1,scale=0.75,pagecommand=\thispagestyle{plain}\subsection{Auszug aus dem Tosa Nikki} \footnotesize{\textsc{Ki} (1957): \textit{Tosa Nikki} [Das Tagebuch von Tosa].}]{Iwanami1957TosaNikki.pdf}
\includepdf[pages=2,scale=0.75,pagecommand=\thispagestyle{plain}]{Iwanami1957TosaNikki.pdf}
\end{document}
2

1 Answer 1

1

You have to remove \addsec{\appendixname} from the definition of \appendixmore.

\newcommand*\appendixmore{%
  \clearpage
  %\addsec{\appendixname}% <- remove this
  \renewcommand{\thesubsection}{\Alph{subsection}}%
}

Then you can add this command to option pagecommand of the first included page.

\includepdf[pages=1,scale=0.75,
  pagecommand=\thispagestyle{plain}%
    \addsec{\appendixname}% <- add this
    \subsection{Auszug aus dem Tosa Nikki}
    {\footnotesize\textsc{Ki} (1957): \textit{Tosa Nikki} [Das Tagebuch von Tosa].\endgraf}% \footnotesize is a switch
  ]{example-image-a4.pdf}

Note that \footnotesize is a switch and does not take an argument.

Example using example-image-a4.pdf provided by package mwe.sty:

\documentclass[12pt,a4paper,headings=standardclasses,numbers=noenddot]{scrartcl}
\usepackage{showframe}
\usepackage[left=2.50cm, right=2.50cm, top=2.50cm, bottom=2.00cm, footskip=1cm]{geometry}
\usepackage[onehalfspacing]{setspace}
\usepackage[main=ngerman, english]{babel}
\usepackage[babel, german=quotes]{csquotes}
\usepackage[ngerman]{isodate}
\usepackage[ngerman]{datetime}

\renewcommand\sectionformat{\mbox{\thesection.\enskip$|$\enskip}}
\usepackage[ngerman]{datetime}

\RedeclareSectionCommand[
  beforeskip=2\baselineskip,
  afterindent=false,
  afterskip=.5\baselineskip,
  tocentrynumberformat=\def\autodot{.}
   ]{section}

\RedeclareSectionCommand[
  beforeskip=-1\baselineskip,
  afterskip=.5\baselineskip]{subsection}

\RedeclareSectionCommand[
  beforeskip=-1\baselineskip,
  afterskip=.5\baselineskip]{subsubsection}

\RedeclareSectionCommand[
  beforeskip=-1\baselineskip,
  afterskip=.5\baselineskip]{paragraph}

\RedeclareSectionCommand[
  beforeskip=-1\baselineskip,
  afterskip=.5\baselineskip]{subparagraph}
  \usepackage{authblk}
%----------------------------------------------------------------------------
%   APPENDICES
%----------------------------------------------------------------------------
\newcommand*\appendixmore{%
  \clearpage
  %\addsec{\appendixname}% <- remove this
  \renewcommand{\thesubsection}{\Alph{subsection}}%
}
%----------------------------------------------------------------------------
%   FIGURES
%----------------------------------------------------------------------------

\usepackage[final]{pdfpages}% loads also graphicx
%\usepackage{graphicx}%loaded by pdfpages
\graphicspath{ {./figures/} }
\usepackage{pdflscape}% maybe better than lscape
%\usepackage{booktabs}

%\usepackage{chngcntr}% only needed with older TeX Distributions
\renewcaptionname{ngerman}{\listfigurename}{Abbildungsverzeichnis}
\renewcaptionname{ngerman}{\figurename}{Abb.}
\counterwithout{figure}{section}
\renewcaptionname{ngerman}{\listtablename}{Tabellenverzeichnis}
\renewcaptionname{ngerman}{\tablename}{Tab.}
\counterwithout{table}{section}

\begin{document}
\appendix
\includepdf[pages=1,scale=0.75,
  pagecommand=\thispagestyle{plain}%
    \addsec{\appendixname}% <- add this
    \subsection{Auszug aus dem Tosa Nikki}
    {\footnotesize\textsc{Ki} (1957): \textit{Tosa Nikki} [Das Tagebuch von Tosa].\endgraf}% \footnotesize is a switch
  ]{example-image-a4.pdf}
\includepdf[pages=1,scale=0.75,pagecommand=\thispagestyle{plain}]{example-image-a4.pdf}
\end{document}

enter image description here

Additional remarks:

  1. If you want to change \listfigurename etc. use \providecaptionname as in the example above.
  2. Package chngcntr is not needed, if you do not use an older TeX Distribution.
  3. pdfpages loads graphicx.
1
  • Thank you very much! :) It worked!
    – user168390
    Jun 30, 2019 at 20:29

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .