Theses, Books, Title pages ⇒ How do I get the chapter number and name on the same line?
-
- Posts: 679
- Joined: Tue Mar 03, 2015 4:01 pm
How do I get the chapter number and name on the same line?
Just a couple of quick questions. Will you be making templates (or build in options to include them) that would have the title page and ToC in the vein of Tufte’s “The Visual Display of Quantitative Information”?
Also, I prefer numbered section headings, so I’ve enabled them. However, I can’t seem to find how to get (chapter number) and (chapter name) in the same line. I tried searching within tufte-common.def file but was unable to find anything. How would I go about modifying this?
Thank you for making this beautiful template available!
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
How do I get the chapter number and name on the same line?
No, I won’t be adding anything to this template myself. I suggest you contact the developers of the template here. If you would like to add this functionality to the template yourself I can incorporate it into the template if you send me the changes.
Regarding your question of putting the chapter number and title on the same line, first, enable chapter/section numbering with:
\setcounter{secnumdepth}{1}
then go to tufte-common.def
and replace:Code: Select all
\titleformat{\chapter}%[display]% shape{\relax\ifthenelse{\NOT\boolean{@tufte@symmetric}}{\begin{fullwidth}}{}}% format applied to label+text{\itshape\huge\thechapter}% label{0pt}% horizontal separation between label and title body{\huge\rmfamily\itshape}% before the title body[\ifthenelse{\NOT\boolean{@tufte@symmetric}}{\end{fullwidth}}{}]% after the title body
Code: Select all
\titleformat{\chapter}%[block]% shape{\relax\ifthenelse{\NOT\boolean{@tufte@symmetric}}{\begin{fullwidth}}{}}% format applied to label+text{\itshape\huge\thechapter\hspace{10pt}}% label{0pt}% horizontal separation between label and title body{\huge\rmfamily\itshape}% before the title body[\ifthenelse{\NOT\boolean{@tufte@symmetric}}{\end{fullwidth}}{}]% after the title body
Cheers,
Vel
-
- Posts: 679
- Joined: Tue Mar 03, 2015 4:01 pm
Re: How do I get the chapter number and name on the same lin
Thanks for your reply, it was very helpful. Although, once I changed it, I realized the default style had been better. However, thanks to you, now I know how to change it, should the need arise.
As for the ToC, if I find the time to edit the default ToC, I will certainly let you know.
Thank you,
Filip.