Page Layout"1. Introduction" rather than "Chapter 1. Introduction"

Information and discussion about page layout specific issues (e.g. header and footer lines, page formats, page numbers).
Post Reply
tronetq
Posts: 4
Joined: Mon Sep 01, 2014 3:57 am

"1. Introduction" rather than "Chapter 1. Introduction"

Post by tronetq »

Hi,

I am currently writing my bachelor's/Honours thesis and have just discovered LaTeX. I would like to write it up using the (excellent) Masters/Doctoral Thesis Template available here. I am modifying to suit my own needs but have gotten stuck.

As my work is not as long as a PhD thesis, it does not have chapters per se and I am looking to format the chapter titles - when they are first introduced as well as the headers. Currently it reads:
'Chapter 1
Introduction'

and I would like it to read:

'1. Introduction'

I cannot find a way to do this and search results in this and other forums have dealt within similar things without fixing the issue. My limited knowledge tells me it is entangled in line 98 of the .cls file - the one that redefines \chaptermark. The following is the full .cls document as I am unsure which is the appropriate bit.

Code: Select all

Code, edit and compile here:
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
% Thesis LaTeX Template - THESIS CLASS FILE
%
% This template has been downloaded from:
% http://www.latextemplates.com
%
% This class file defines the structure and design of the template.
%
% There is one part of this file that needs to be filled out - the variables
% dictating the document particulars such as the author name, university
% name, etc. You will find these in the commented "DOCUMENT VARIABLES"
% section below.
%
% The other two easily-editable sections are the margin sizes and abstract.
% These have both been commented for easy editing. Advanced LaTeX
% users will have no trouble editing the rest of the document to their liking.
%
% Original header:
%% This is file `Thesis.cls', based on 'ECSthesis.cls', by Steve R. Gunn
%% generated with the docstrip utility.
%%
%% Created by Steve R. Gunn, modified by Sunil Patel: www.sunilpatel.co.uk
%% Further modified by www.latextemplates.com
%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\NeedsTeXFormat{LaTeX2e}[1996/12/01]
\ProvidesClass{Thesis}
[2007/22/02 v1.0
LaTeX document class]
\def\baseclass{book}
\DeclareOption*{\PassOptionsToClass{\CurrentOption}{\baseclass}}
\def\@checkoptions#1#2{
\edef\@curroptions{\@ptionlist{\@currname.\@currext}}
\@tempswafalse
\@tfor\@this:=#2\do{
\@expandtwoargs\in@{,\@this,}{,\@curroptions,}
\ifin@ \@tempswatrue \@break@tfor \fi}
\let\@this\@empty
\if@tempswa \else \PassOptionsToClass{#1}{\baseclass}\fi
}
 
 
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
I hope the following is suitable for an MWE, otherwise the above link to the WriteLaTeX site has all the content I've mentioned.

Code: Select all

Code, edit and compile here:
\documentclass[12pt, oneside]{Thesis}
\begin{document}
\chapter{1. Introduction}
Some Text
\end{document}
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
I would appreciate any help. Thank you.

Recommended reading 2024:

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

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

tronetq
Posts: 4
Joined: Mon Sep 01, 2014 3:57 am

"1. Introduction" rather than "Chapter 1. Introduction"

Post by tronetq »

Stumbled onto KOMA-scriptand titlesec packages which seem to fix the problem though I can't say I understand what they're doing. If the moderators would prefer this thread to be deleted, free feel to do so.
User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

"1. Introduction" rather than "Chapter 1. Introduction"

Post by Johannes_B »

Don't use titlesec with KOMA, KOMA has all the possibilities on board to change the look. What you are looking for is the switch chapterprefix as well as the numbers option. Have a look at the documentation for additional details.

Code: Select all

Code, edit and compile here:
\documentclass[numbers=enddot]{scrreprt}
\begin{document}
\chapter{Introduction}
Some Text
\end{document}
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
tronetq
Posts: 4
Joined: Mon Sep 01, 2014 3:57 am

Re: "1. Introduction" rather than "Chapter 1. Introduction"

Post by tronetq »

Thank you for your reply. Rhat is true. But I wish to use the document class that comes with the template so would I be correct in thinking that titlesec is the best option? Correct me if I'm wrong but what I gathered from the KOMA-Script documentation, this layout requires one of the KOMA-classes to be used.
User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

"1. Introduction" rather than "Chapter 1. Introduction"

Post by Johannes_B »

Before you go on, please read what our friend and colleage Clemens thinks of templates: LaTeX templates.

There are problems with the stuff coming from over there soo many times. I guess nobody ever reviewed the stuff there.

Classicthesis can also be found there, which i was having fun with the last few days as there is so many weird stuff in it. Commands that are defined, but never used, Things implemented wrongly ... I could go on, but there's no use in it.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
tronetq
Posts: 4
Joined: Mon Sep 01, 2014 3:57 am

Re: "1. Introduction" rather than "Chapter 1. Introduction"

Post by tronetq »

Hmm, he raises some very good points. I definitely should step back and consider my options. Maybe making my own 'template' would be a much better idea. Thank you for showing me this!
User avatar
Johannes_B
Site Moderator
Posts: 4182
Joined: Thu Nov 01, 2012 4:08 pm

"1. Introduction" rather than "Chapter 1. Introduction"

Post by Johannes_B »

Template is a very strange word i think.
LaTeX is a modular thing, there is some basic stuff defined in the kernel and many add-on packages giving you additional functionality. Think of your document as an expedition.
Going on an expeditions means to gather some experts to help you explore the area, take sample etc. There will be some guys you need for every expeditions, some will be only needed in the amazonas jungle. But those jungle guys usually are worthless in the desert.

Now a LaTeX template gives you a ready to go expedition team full of experts. The template may be some years old and so are the guys. One expert is there only to provide a hand-crafted pickaxe, but you don't need one. If you would really need a pickaxe, make sure to find the guy providing an automatic pickaxe function.


Having said that, the experienced LaTeX user usually starts with about 3 or 4 packages that are involved everywhere, for example babel, and adds the rest as the need arises. And experienced user doesn't use templates.

But without templates we helpers would soon be out of work.
The smart way: Calm down and take a deep breath, read posts and provided links attentively, try to understand and ask if necessary.
Post Reply