
Então estou tentandoremoveras palavras Chapter n
e substitua-as por chapter title
. MAS quero que apareça no índice... (Portanto, não posso usar \chapter*{...}
).
Existe uma maneira de conseguir isso?
Obrigado!
Responder1
Usartitlesec
\documentclass{book}
\usepackage{titlesec}
\titleformat{\chapter}[display]
{\normalfont\huge\bfseries}{}{0pt}{\Huge}
\titlespacing*{\chapter} {0pt}{20pt}{40pt}
\begin{document}
\tableofcontents
\chapter{Some chapter}
\end{document}
Responder2
Isso funcionou para mim:
\chapter*{Introduction}\stepcounter{chapter}\addcontentsline{toc}{chapter}{Introduction}
Coloque esse código no início do seu capítulo.
Responder3
Se você usar a classe book
or report
document e não quiser empregar um pacote LaTeX como titlesec
, poderá prosseguir redefinindo (simplificando, na verdade) a macro de baixo nível \@makechapterhead
. Aqui está um exemplo prático que usa a book
classe document; As linhas que começam com %%
são comentadas do código original de \@makechapterhead
.
\documentclass{book}
\makeatletter
\def\@makechapterhead#1{%
%%\vspace*{50\p@}%
{\parindent \z@ \raggedright \normalfont
%%\ifnum \c@secnumdepth >\m@ne
%%\if@mainmatter
%% \huge\bfseries \@chapapp\space \thechapter
%% \par\nobreak
%% \vskip 20\p@
%%\fi
%%\fi
\interlinepenalty\@M
\Huge \bfseries #1\par\nobreak
\vskip 40\p@
}}
\makeatother
\begin{document}
\tableofcontents
\mainmatter
\chapter{First}
\chapter{Second}
\end{document}
Responder4
Adicione no preâmbulo tal linha
\setcounter{secnumdepth}{-1}