# Tag Info

3


4

As I stated in my comment, the section number \thesection must be communicated through a mark (for \thechapter this isn't necessary as chapters always start at a new page). But normal LaTeX doesn't have an extra mark for this section number, so I use the extramarks package with the \extramarks command and \firstrightxmark and \firstleftxmark. \documentclass{...

1

looking at texdoc paper the journal class (which is just paper class with option journal) is intended for the whole journal, including individual papers. for a single paper I think you are intended to use paper rather than journal.

2

Two suggestions: Consult the documentation or a tutorial for the fancyhdr package. See e.g. the Overleaf tutorial. You use the commands of the package in a peculiar way that messes up the header. Use the babel package with the option italian. This will set the title of the bibliography automatically (as well as other things for the Italian language). Here ...

0

Just put additional \sectionmark before \section \sectionmark{This is a loooooooong looooooooo\ldots} \section[This is a loooooooong looooooooooong looooooooooooong title in TOC]{This is a loooooooong looooooooooong looooooooooooong title} \sectionmark{This is a loooooooong looooooooo\ldots}

0

The memoir class (a superset of book and report) provides for ToC, header, and regular sectional commands through two optional arguments. For example: \documentclass{memoir} \begin{document} \tableofcontents \chapter[title-in-toc][title-in-header]{main-title} \section[title-in-toc-and-header]{main-title} \subsection{main-title-in-toc-and-header} \...

0

Unfortunately, the solution presented by @ejmastnak doesn't always work correctly. I have a couple of examples where it fails. The problem is that TeX's page breaking algorithm can process more text than fits on the page, and then it can later decide to put that text on the next page. Therefore setting 'variables' to communicate information to the headers ...

0

You can use \chaptermark{...} to set the header. \sectionmark is trickier since it appears on the same page. It is designed to show the first section, and since \section calls \sectionmark, the default name is the first section. So I created \mysection which does not call \sectionmark. \documentclass{book} \usepackage{lipsum} \makeatletter \newcommand{\...

0

Edit: Thanks to @Pieter van Oostrum for pointing out that this solution fails for non-trivial section/subsection arrangement. See his answer for a more robust solution. I know that this is an old question, but seeing that it is still unanswered, I thought I would provide my solution for whomever might stumble upon this from a Google search with the same ...

1

Here is a simple way to do it using fancyhdr package. Although esdd provided you with a great answer, I have a different way of defining \headrule. I believe it is simpler and will not cause any issues down the road. \documentclass[twoside]{book} % Header and Footer \usepackage{fancyhdr} \pagestyle{fancy} \fancyhf{} % Header Settings \fancyhead[LE,...

1

For the first question, try \documentclass[12pt]{article} \usepackage[a4paper]{geometry} \usepackage{fancybox} \begin{document} \shadowbox{Essai} \end{document} For the second, you should only ask one thing per question asked.

0

You are using \usepackage[headsepline,automark]{scrlayer-scrpage} With the twosided article classs option automark does the same as \automark[subsection]{section} So each \section command (without star) sets a left mark and clears the right mark and each \subsection (without star) sets a right mark. So, with \clearpairofpagestyles \ihead{\rightmark} \ofoot*...

0

If there should be a page number on pages with style plain too, you have to use \ofoot[\pagemark]{\pagemark} or its short version \ofoot*{\pagemark} If the blank page inserted by \cleardoublepage should use page style plain, you can load package scrextend and use \cleardoubleplainpage. Example: \documentclass[11pt,a4paper,twoside]{article} \usepackage{...

1

I'm usually using this function I wrote: \newcommand{\silentchapter}[1]{ \chapter*{#1} \markboth{#1}{#1} %\addcontentsline{toc}{chapter}{#1} } I creates a chapter without a number and sets the header. The commented line adds this chapter to the contents index.

1

\clearpairofpagestyles cleans both styles scrheadings and plain.scrheadings¹. If the page number should be in outer footer in both styles use \ofoot[\pagemark]{\pagemark} or its short version \ofoot*{\pagemark} Example: \documentclass[11pt,a4paper,twoside]{article} \usepackage[headsepline,automark]{scrlayer-scrpage} \clearpairofpagestyles \ohead{\leftmark} ...

2

article ordinarily uses the contents of \title{...} and \author{...} to serve as the running heads, and applies these when \maketitle is issued. Since I don't see any of these in your example, the running heads are blank. You can set the running heads you want by issuing the command \markboth{<left heading text>}{<right heading text>| somewhere ...

0

You can simply put the following: \begin{frame}[plain] \titlepage \end{frame} Reference goes to: https://latex.org/forum/viewtopic.php?t=10356# With this you do not need so much tweaking as described above.

0

0

Although beamer discourages the use of fancyhdr, it is actually possible to use it if you take some precautions: You have to set the value of \headheight and/or \footskip to a value that is large enough (see the warning in your log file for the required values. If no warning then you can skip this. Add this line after setting fancyhdr and possible \...

0

I found a solution which works until now only for the bibliography chapter (the use of tcolorbox does not seems to work for Index, Glossary and TOC as I think modifications are needed in the preambule to allow it, but I don't know how to fix the problem...). This is the code to obtain the following result: \documentclass[nobib,twoside,symmetric,justified,...

0

1


2

It is not recommended to use package tocloft with a KOMA-Script class. You could change indent and numwidth in ToC using \RedeclareSectionCommand or \DeclareTOCStyleEntry. Example: \documentclass[a4paper]{scrartcl} \usepackage[headsepline=0.75pt]{scrlayer-scrpage} \setkomafont{pagehead}{\normalfont\sffamily}% <- changed \clearpairofpagestyles \automark[...

0

Option for tocloft: \usepackage[titles]{tocloft} \renewcommand{\cftsecpagefont}{\normalfont} Still would like to use KOMA instead.

0

I just solved it thanks to gernot's comment! I'm not specifically overwriting any behaviour but I found which mistake I personally made. I have each recipe as a individual .tex files. I just noticed that in the template those .tex files have a \thispagestyle{plain}. Removing it solves the problem and I can set my own fancy footer.

0

Unnumbered sections don't set marks. But you can set them yourself, like \markright{Abbreviations} \documentclass{article} \usepackage{fancyhdr} \fancyhead[R]{\rightmark} \pagestyle{fancy} % Unnumbered section \newcommand{\UNsection}[1]{\section*{#1} \markright{#1}} \begin{document} \UNsection{Abreviations} \addcontentsline{toc}{section}{Abreviations}...

1

It is not recommended to edit the class file. Change the settings in the document preamble: \pagestyle{thesis}% defined by the class using package scrlayer-scrpage \clearpairofpagestyles \lehead{\ttitle} \rehead{\rightmark} \lohead{\leftmark} \rohead{\univname} \ofoot*{\pagemark}% or should there be no page number at all? Example: \documentclass[english,...

1

Here is an example of how to create a page style (myheadings). I used scrbook instead of your thesis, but it should still work. I added the words Chapter and Section and used \arabic{section} instead of \thesection. It should be noted that \chaptermark is called by \chapter and is passed the chapter title, while \sectionmark is called by \section and is ...

Top 50 recent answers are included