Document ClassesReport, without chapter heading but with appendix heading

Information and discussion about specific document classes and how to create your own document classes.
Post Reply
taalest
Posts: 2
Joined: Wed Mar 23, 2011 7:53 am

Report, without chapter heading but with appendix heading

Post by taalest »

Hi! (first post on LaTeX Community)

We are the guys guys collaborating on writing a report. I'm responsible for the layout and since the two other guys don't know to much about LateX either, I want to make it simple. We use the report documentclass, but I'd like to modify it a bit. What I what to do is:

1. Remove the chapter heading and replace it with the chapter title:
from:
1 Chapter
Chapter title
to:
1 Chapter title

2. and in appendix: Appendix I - appendix name
from:
Appendix A
appendix title
to:
APPENDIX I - appendix title

Made a .cls file in which i have written:

Code: Select all

\NeedsTeXFormat{LaTeX2e}
\ProvidesClass{mastersreport}

\DeclareOption*{\PassOptionsToClass{\CurrentOption}{report}}

\ProcessOptions

\LoadClass{report}

\renewcommand*\@makechapterhead[1]{%
 \vspace*{50\p@}% 
 {\parindent \z@ \raggedright \normalfont
   \ifnum \c@secnumdepth >\m@ne 
  	\huge\bfseries
    	 \thechapter\space
    \fi
    #1\par\nobreak
    \vskip 40\p@
}}
This solves my first problem, but also takes away the appendix heading.
So, anyone know how to remove the Chapter heading, but not in Appendix and how to rearrange the Appendix layout?

preamble:

Code: Select all

\documentclass[pdftex,10pt,b5paper,twoside]{report}
\usepackage[lmargin=25mm,rmargin=25mm,tmargin=27mm,bmargin=30mm]{geometry}
\usepackage[comma]{natbib}
\usepackage{lmodern}
\usepackage{setspace}
\usepackage{amsmath,amssymb,amsfonts}
\usepackage{graphics}
\usepackage{color}
\usepackage{hyperref}

Recommended reading 2024:

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

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

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

Samonios
Posts: 5
Joined: Fri Feb 18, 2011 10:15 am

Re: Report, without chapter heading but with appendix headin

Post by Samonios »

Two packages to look up:
fancyhdr
changepage
taalest
Posts: 2
Joined: Wed Mar 23, 2011 7:53 am

Report, without chapter heading but with appendix heading

Post by taalest »

don't want to change the header and footer. like to change, if i write \chapter{First chapter}:

regular report documentclass:

Chapter 1
First chapter

to

modified report documentclass:

1 First chapter

In my own .cls i manage to change it, but than I also remove "Appendix" from the title of the appendix. Something I don't want......
Post Reply