LaTeX forum ⇒ Theses, Books, Title pagesMastersDoctoralThesis avoid pagebreak between CHAPTERS Topic is solved

Classicthesis, Bachelor and Master thesis, PhD, Doctoral degree
mgo4107
Posts: 11
Joined: Sun Oct 04, 2020 7:02 pm

MastersDoctoralThesis avoid pagebreak between CHAPTERS

Postby mgo4107 » Sun Nov 15, 2020 4:02 pm

Hi @all,

I am using
%Masters/Doctoral Thesis
% LaTeX Template
% Version 2.5 (27/8/17)

which I downloaded here. Actually a very nice and helpful template !!!

I have one question related to chapter change. I have a pagebreak between the chapters which I would like to avoid.

Pagebreak is OK for TOC, Nomenclature, List of Figures etc. but between e.g. Chapter 1 / Chapter 2 / Chapter 3 etc. I do not need a pagebreak.

Is there any way to control that whether in the main.tex or MastersDoctoralThesis.cls?

Thanks a lot for your feedback.
Cheers Michael

Bartman
Posts: 140
Joined: Fri Jan 03, 2020 2:39 pm

Postby Bartman » Sun Nov 15, 2020 5:13 pm

It is against the nature of a chapter, but you can do the following:

Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. \documentclass{book}
  2.  
  3. \begin{document}
  4. \chapter{Heading on the page}
  5. Text
  6.  
  7. \begingroup
  8. % no newpage
  9. \let\cleardoublepage\relax
  10. %\renewcommand{\cleardoublepage}{}
  11. \chapter{Heading one the same page}
  12. Text
  13. \endgroup
  14.  
  15. \chapter{Heading after at least one page break}
  16. Text
  17. \end{document}


As you can see, the effect of the solution must be limited by a group so that it does not apply to all of the following chapters.

The source of the first approach.

mgo4107
Posts: 11
Joined: Sun Oct 04, 2020 7:02 pm

Postby mgo4107 » Sun Nov 15, 2020 5:25 pm

Thanks for the quick response. Much appreciated.

Unfortunately it is mixing up my complete document:

Before: Chapter 1 -> 1.5 pages, Chapter 2 starting as a new page

With the settings proposed:

Chapter 1: First page empty, starting completely mixed up on Page 2 with big gaps between lines, no footer restrictions. Chapter 2: starting somewhere ...

mgo4107
Posts: 11
Joined: Sun Oct 04, 2020 7:02 pm

Postby mgo4107 » Sun Nov 15, 2020 5:28 pm

It WORKS ...

the problem was, this part needs to be before the \begingroup ;-)

% Define some commands to keep the formatting separated from the content
\newcommand{\keyword}[1]{\textbf{#1}}
\newcommand{\tabhead}[1]{\textbf{#1}}
\newcommand{\code}[1]{\texttt{#1}}
\newcommand{\file}[1]{\texttt{\bfseries#1}}
\newcommand{\option}[1]{\texttt{\itshape#1}}

mgo4107
Posts: 11
Joined: Sun Oct 04, 2020 7:02 pm

Postby mgo4107 » Sun Nov 15, 2020 6:19 pm

Now I have another issue :-)
using the proposed code is helping perfectly for putting chapters together.

But ...

%headsepline, % Uncomment to get a line under the header

is not working anymore.

and how can I disable e.g. Chapter 5. Examples.

I just want on every "normal" page with exception of TOC, Nomenclature etc.) a line as header separator and just on the right side the page number.

BTW: You can the roman page number for TOC etc. be changed from e.g. ii to II (UPPERCASE)?
Many thanks for your help.
Cheers Michael

Bartman
Posts: 140
Joined: Fri Jan 03, 2020 2:39 pm

Postby Bartman » Sun Nov 15, 2020 7:53 pm

It would be better for the overview, if you start a new topic for a new question.


Return to “Theses, Books, Title pages”

Who is online

Users browsing this forum: No registered users and 5 guests