Tag Info

Hot answers tagged

21

As the comments note, I am the only user at the moment and would probably be for some time. Like many package writers the real reason for developing it, was to fulfill a need, in this case to enable me to produce beautiful books with less problems. A full pdf probably 3-4 months old can be found at phd. It is a rather lengthy document, as the document at ...


10

Please do the following steps: go to https://github.com/yannisl/phd press on "Download ZIP" on the right (106 MB) extract the .zip file somewhere you want. navigate your terminal (cmd on Windows) into that folder run (three lines, each followed by an Enter-stroke): pdflatex phd.dtx makeindex -s gind.ist -g phd pdflatex phd.dtx open the phd.pdf which is ...


8

Use the import package. Suppose I write a document describing how to make a banana milkshake. Separate the document into the header and the content: /banana/bananaMilkshake.tex (pseudocode) \documentclass{whatever} \begin{document} \input{bananaMilkshake-content.tex} \end{document} /banana/bananaMilkshake-content.tex Whatever content you want. Then, ...


8

With titlesec: \documentclass{book} \usepackage{lipsum} \usepackage{titlesec} \titleformat{\chapter}[display] {\normalfont\huge\bfseries}{\chaptertitlename\ \thechapter}{20pt}{\Huge} [\clearpage\thispagestyle{empty}\null\clearpage] %\titlespacing*{\chapter} {0pt}{50pt}{40pt} \begin{document} ‎\chapter{Chapter One}‎ \lipsum[1-2] ‎\end{document}‎


5

This illustrates the default layout of the epigraphs environment which supports multiple quotations: \documentclass{scrreprt} \usepackage{epigraph,url} \begin{document} \chapter{In The Beginning} \begin{epigraphs} \qitem{Friendship with oneself is all-important, because without it one cannot be friends with anyone else in the world.}{Eleanor ...


5

Please always provide a full minimal working example (MWE). I am using the dictum environment KOMA-Script does not have a dictum environment but a \dictum command! If I do two back to back dictums, it simply ignores the first and proceeds with the second. I can't reproduce this when I use the command the way it is shown in the KOMA-Script ...


5

You shouldn't use titlesec with KOMA-script generally. Assuming that you have needs, here is a way. We can use a \parbox or minipage to enclose the chapter title and fix the height of the \parbox/minipage. I have used explicit option for titlesec and used \parbox[t][2\baselineskip][t]{\textwidth} {\MakeUppercase{#1}} Here the height of the box is ...


5

For book-like classes, \frontmatter disables the chapter numbering (but still adds unstarred \chapter's to the TOC). The numbering is then resumed with \mainmatter. (The reason for this is that chapters in the front matter, such as a foreword or preface, are typically unnumbered but should be listed in the table of contents.) Example: \documentclass{book} ...


4

Define \DeclareRobustCommand{\plural}{s} in your document preamble and use \chapter{Bla Bla Bla Bla XYZ\plural} so the uppercasing macros will not change \plural and a lowercase “s” will appear. Remember to use {} after \plural in case you want to preserve a following space, such as in \chapter{Bla XYZ\plural{} Bla}


4

The chapter head is typeset by \@makechapterhead, which is a macro with one argument, while the TOC entry and the heading are direct responsibiity of \@chapter and independent of \@makechapterhead. If we temporarily redefine it to simply gobble its argument, we're done. \documentclass{report} \makeatletter \newcommand{\unchapter}[1]{% \begingroup ...


3

Page breaking happens in an asynchronous way. TeX typesets entire paragraphs and places them in the “recent contributions list” and computes how much space has been occupied on the page it's on. When typesetting a paragraph overflows the available space, TeX moves the recent contributions to the main vertical list and calls the page builder into action. ...


3

With the default report and book document classes, use etoolbox to patch \l@chapter and remove the use of \bfseries: \documentclass{report} \usepackage{etoolbox}% http://ctan.org/pkg/etoolbox \makeatletter \patchcmd{\l@chapter}{\bfseries}{}{}{}% \patchcmd{<cmd>}{<search>}{<replace>}{<success>}{<failure>} \makeatother ...


3

You can temporarily switch off the impact of a \clearpage - typically inserted when using \chapter: \documentclass{report} \usepackage{lipsum} \begin{document} \chapter{A chapter} \lipsum[1] { \cleardoublepage% Move to first page of new chapter \let\clearpage\relax% Don't allow page break \noindent\lipsum[2] \chapter{Another chapter} } \lipsum[1] ...


3

Starred chapters (and sections) don't get a number, nor a toc entry, nor a header. Problem is, the header is not cleared. You have to do that manually using \markboth{}{}. But from your example i can see that you want a toc entry and i think also a header. You could implement that. A KOMA class provides the same command in a more advanced way. Please read ...


3

I think you are looking for titlespacing. I copied the original from titlesec.sty and just set the former value of 50 pt (rather 50\p@) to zero points. There still is a little skip, but i think it's ok the way it is. You can of course set a negative value instead if you want to. I also changed the width of the marginal column to 22 mm. I am not sure if you ...


3

This is burried deeply in the manual of oscola, see p. 9: \usepackage[backend=biber, style=oscola, indexing=cite, citereset=chapter]{biblatex} Please note: "citereset=chapter". Oh, and by the way, this code is not necessary: \makeatletter % the commands to ensure footnotes start new numbering at each chapter \@addtoreset{footnote}{chapter} ...


2

Just a proposition -- there is no general rule on appendices, so it's sometimes a make an educated guess what is desired/requested. \documentclass{report} \usepackage{tocloft}% \usepackage{blindtext} \addtolength{\cftchapnumwidth}{10pt}% \begin{document} \tableofcontents \chapter{Dummy} \blindtext \setcounter{chapter}{0} \chapter*{Appendices} ...


2

Within your aghdpl.cls class file, you'll see that chapters are set using a font size \LARGE (line 191-192): \titleformat{\chapter}[block] {\bfseries\LARGE}{\filright \LARGE\thechapter. }{0ex}{} However, ToC-related entries are set using only \Large (line 209): \renewcommand{\cfttoctitlefont}{\bfseries\Large} Since \lstlistoflistings is set just like ...


2

Simplest hack is to use a group like { %%<--- start the group \backmatter \bibliographystyle{unsrt} \bibliography{xampl} } %%<--- end the group \appendix Code: \documentclass{book} %\usepackage{appendix} \begin{document} \frontmatter \chapter{Some front matter} \mainmatter \chapter{some main matter} ...


2

If the OP wants to stick to \part .... this answer provides a version with automatic resetting of chapter numbers for each part. In my point of view, the structuring commands should be used differently, see another version below the \part solution. \documentclass[oneside,11pt]{report} % \makeatletter \@addtoreset{chapter}{part} \makeatother ...


1

How about more simple solution which evades the usage complicated tikz codes? Well, it is no TeXer masterclass, however if you want save your time, try this workaround: Draw your fancy page in Microsoft Word for example, and save file as PDF, JPG or PNG. Insert it as picture in your TeX-doc. For a4paper, the code will be... \cleardoublepage ...


1

Edit answering OPs further questions - even though there's an accepted answer. \documentclass[a4paper,10pt]{report} \newcounter{rememberchapter} \newcommand{\firstpart}[1]{% \setcounter{rememberchapter}{\value{chapter}} \part{#1} \setcounter{chapter}{0} \renewcommand{\thechapter}{\Alph{chapter}} } \newcommand{\mypart}[1]{% \part{#1} ...


1

Well, this is troubling. You really need to make a minimum working example, or we can't help you nearly as easily. When you don't provide a minimum working example, you're essentially asking the community to shoulder a burden to help you, rather than doing your best to answer it yourself first. That makes it much less likely that someone will help you, ...


1

You can make \printpartitle to remember the current part title. I added also an interface for resetting the title to nothing. \documentclass{memoir} \usepackage{calc,graphicx} \usepackage{color} \definecolor{nicered}{rgb}{.647,.129,.149} \makeatletter \newlength\dlf@normtxtw \setlength\dlf@normtxtw{\textwidth} \def\myhelvetfont{\def\sfdefault{mdput}} ...


1

Does this do what you want? You might wish to adjust the spacing and font for the chapter title but this shows you how to do that. This puts the chapter number on the same line as the title of the chapter. It also sets the value of \chaptername empty which avoids getting 'Chapter 1 ...' in headers even though the first chapter is just '1 ...' in the text. ...


1

Change 0.5 with your preferred value \documentclass[twoside,openright,14paper]{memoir} \usepackage[usenames,dvipsnames]{color} \usepackage{graphicx} \renewcommand\colorchapnum{\color{PineGreen}} \renewcommand\colorchaptitle{\color{PineGreen}} \chapterstyle{pedersen}% \renewcommand{\afterchaptertitle}{\par\nobreak\vskip0.5\midchapskip} \begin{document} ...


1

Code: \documentclass[twoside,12pt,openany]{book} \usepackage[total={6.5in,10.75in},top=-1in, left=0.9in, includefoot]{geometry} \usepackage{lipsum} \usepackage[usenames,dvipsnames,svgnames,table]{xcolor} \usepackage[T1]{fontenc} \usepackage{titlesec} ...



Only top voted, non community-wiki answers of a minimum length are eligible