GeneralAppendix heading on same page as appendix content

LaTeX specific issues not fitting into one of the other forums of this category.
Post Reply
zlya
Posts: 4
Joined: Tue Aug 19, 2008 8:13 pm

Appendix heading on same page as appendix content

Post by zlya »

Hello,

I am writing a thesis in using report class. Currently each chapter starts with a chapter heading on a separate page from the main text of the chapter, which I'm not too bothered about until I get to the Appendix when each appendix starts on its own page as well.

Is there anyway to change either both chapter and appendix or just the appendix so I can have:

***
Appendix A

stuff in appendix A
***

on the same page? My appendices are quite short, and having a separate titlepage for them seems ridiculous.

Right now the appendices are in the form:

\appendix
\appendixpage
\addappheadtotoc
\chapter{Appendixtitle}
\include{file with appendix stuff}

Thanks.

Also, I'm relatively new and not interested in spending the next few days working this out (since thesis is due in a week) so quick and dirty solutions preferred. Thankyou!

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

Stefan Kottwitz
Site Admin
Posts: 10345
Joined: Mon Mar 10, 2008 9:44 pm

Appendix heading on same page as appendix content

Post by Stefan Kottwitz »

Hi Ziya,

welcome to the board!
In this minimal working example it works like desired:

Code: Select all

\documentclass[a4paper,10pt]{report}
\usepackage{appendix}
\begin{document}
\appendix
\appendixpage
\addappheadtotoc
\chapter{Appendixtitle}
Text
\chapter{Another Appendix}
Text
\end{document}
Just don't repeat \appendix, \appendixpage and \addappheadtotoc, use it only once.

Stefan
LaTeX.org admin
zlya
Posts: 4
Joined: Tue Aug 19, 2008 8:13 pm

Re: Appendix heading on same page as appendix content

Post by zlya »

Thank you for the quick and extremely helpful response! My problem seems to be in the use of \include.

When I try:

\documentclass[a4paper,10pt]{report}
\usepackage{appendix}
\begin{document}
\appendix
\appendixpage
\addappheadtotoc
\chapter{Appendixtitle}
\include{text}
\chapter{Another Appendix}
Text
\end{document}

with another file text.tex:

I get the page break. This is not actually a problem, I can just copy over all my appendices into the main file when I'm finished drafting, but good to know.

Thanks again!
zlya
Posts: 4
Joined: Tue Aug 19, 2008 8:13 pm

Re: Appendix heading on same page as appendix content

Post by zlya »

Oh, I can just move the chapter titles into the included material can't I? Sorry, I've been writing for some time, brain failing a bit.
User avatar
Stefan Kottwitz
Site Admin
Posts: 10345
Joined: Mon Mar 10, 2008 9:44 pm

Re: Appendix heading on same page as appendix content

Post by Stefan Kottwitz »

Yes, you could copy the \chapter-lines into the included tex file to fix that. Or use \input instead of \include, \input doesn't cause a page break.

Stefan
LaTeX.org admin
Post Reply