Re: Ask for help : Package titlesec affects the settings of tocloft

Pétiard François <[email protected]>
Newsgroups gmane.comp.tex.miktex
Message-ID <[email protected]>
Le 14/04/2014 10:52, Jilong Yin a écrit :
> Hello, everyone.
>
>   I am facing a problem when formatting my report edited by Latex.
>
> I wanto to do the following two formatting
>
> 1.  to supress the line break after chapter title, for example
>     Chapter 1 Exercise A
>    to replace the default one
>    Chapter 1
>      Exercise  A
>
> 2. to append "Appendix x........#"' to TOC, replacing default "x........#"
>
>
> I use package titlesec to do format 1 and use package tocloft to do format
> 2.
> But I found the two package affect each other.
> I can not get the two format at the same time.
>
> Anyone can help me some, thanks in advance.

Hello

Package tocloft tests if titlesec is loaded.
A solution:
put after \begin{document} (and before \tableofcontents):

\makeatletter
\@cfttitlesecfalse
\makeatother

François


------------------------------------------------------------------------------
Learn Graph Databases - Download FREE O'Reilly Book
"Graph Databases" is the definitive new guide to graph databases and their
applications. Written by three acclaimed leaders in the field,
this first edition is now available. Download your free book today!
http://p.sf.net/sfu/NeoTech
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.