3

I have main.tex file and an appendix.tex file. I use include command to insert the appendix file. No problems with latex, but vim-latex folds the \include{appendix} statement into the previous section. How can I avoid this?

Here is the MWE: main.tex

\documentclass[11pt]{scrartcl}
\usepackage[a4paper, total={6.1 in, 9.5in}]{geometry}
\usepackage[T1]{fontenc}
\usepackage[english]{babel}

\usepackage[title]{appendix}

\begin{document}
\title{ State of the Art }
\author{\bf My Name}
\date{\today}
\maketitle

\section{Introduction}
Some introduction

\section{Main Section}
Main content

\subsection{subsection}
Subsection content

\newpage
\include{appendix}
\end{document}

and the appendix.tex

\appendixpage
\begin{appendices}
    \section{Appendix Header}

\end{appendices}

\bibliography{bibfile}
1

1 Answer 1

1

Fake sections as described in 8.2 Customizing what to fold of the documentation can be used like %%fakesection Appendix such that

\documentclass[11pt]{article}
\usepackage[title]{appendix}

\begin{document}
\title{ State of the Art }
\author{\bfseries My Name}
\date{\today}
\maketitle

\section{Introduction}
Some introduction

\section{Main Section}
Main content

\subsection{subsection}
Subsection content

%%fakesection Appendix
\newpage
\include{appendix}
\end{document}

folds up as

 +      3 lines: Preamble: \documentclass[11pt]{article}---------------------
 \begin{document}
 \title{ State of the Art }
 \author{\bfseries My Name}
 \date{\today}
 \maketitle
 +      3 lines: \section{Introduction}--------------------------------------
 +      6 lines: \section{Main Section}--------------------------------------
 +      3 lines: %section Appendix-------------------------------------------
 \end{document}
1
  • voila !!! works excellently
    – kksagar
    Jan 18, 2019 at 9:55

You must log in to answer this question.

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