4

You can set the header in a \colorbox in the centre only, and then spread the contents to the left/right/centre as needed. \documentclass{article} \usepackage{fancyhdr,xcolor} \usepackage{lastpage,lipsum} \pagestyle{fancy} \fancyhf{} \fancyhead[C]{% \setlength{\fboxsep}{0pt}% Remove \fbox gap \colorbox{blue!15!white}{% \makebox[\textwidth]{% ...


4

\documentclass{article} \usepackage{fancyhdr,color} \usepackage{lastpage} \pagestyle{fancy} \fancyhf{} \setlength\headheight{17pt} \lhead{\textcolor{red}{\rule[-4pt]{\textwidth}{15pt}}% \hspace{-\textwidth}% \textcolor{white}{\textsl{Title}}} \rhead{\textcolor{white}{\textsl{Page \thepage{} of \pageref{LastPage}}}} \begin{document} zz \end{document}


2

If you keep the geometry set by the class, you must leave a vertical space on the first page, to make place for the expanded heading, and activate the \pagestyle{main} to start from the second page onwards. \documentclass{article} \usepackage{fancyhdr} \usepackage{lipsum} \usepackage{tikz} \usepackage{showframe} % added %header first page \fancypagestyle{...


2

This will give an error message unless you use lualatex, and will still print a spurious tcbcolupper. I'm not a tcolorbox expert (nor want to be) so I will leave this to others. This solution puts the header into a savebox in order to the compute header height accurately. It also increments the page counter before \iflastpage inside \FillAnswerRules. \...


2

With package scrletter you have to redefine \letterpagemark: \renewcommand*\letterpagemark{% \usekomafont{pagenumber}{\pagename~\thepage~of~\letterlastpage}% } Example: \documentclass{scrartcl} \usepackage{scrletter} \renewcommand*\letterpagemark{% \usekomafont{pagenumber}{\pagename~\thepage~of~\letterlastpage}% } \usepackage{xpatch} \xpatchcmd{\...


2

If I use a development version of longtable from the longtable4.14 branch of the latex3 github your example has better page breaks The issue is essentially a duplicate of this one (amongst others) longtabu and floats: wrong table breaks on pages with floats I hope to get longtable updated at some point but there are some compatibility issues to address lt 4....


2

You can simple (without additional packages) redefine \pagemark to your needs: \renewcommand*\pagemark{% \usekomafont{pagenumber}{\pagename~\thepage~of~\letterlastpage}% } Example: \documentclass{scrlttr2} \usepackage{blindtext}% only for dummy text \renewcommand*\pagemark{% \usekomafont{pagenumber}{\pagename~\thepage~of~\letterlastpage}% } \begin{...


1

The easiest way is calling the scrlayer-scrpage package. You can put text in 3 points of header or footer: the outer part of the page, with \ohead or \ofoot, the central part, with \chead or \cfoot and the inner part of the page, with \ihead or \ifoot. Look at the MWE and try to comment and uncomment lines and put text inside the brackets: \documentclass{...


1

The scrlttr2 class offers specific commands for modifying headers and footers, through the scrlayer-scrpage package. The mwe below is a starting point. Note that there is no need to use the lastpage package, as the class provides the internal \lastletterpage counter. \documentclass{scrlttr2} \usepackage{scrlayer-scrpage} \cefoot{Page \thepage\ of \...


1

You have to redefine \letterpagemark in the preamble to get the desired result. \documentclass{scrartcl} \usepackage{scrletter} \usepackage{blindtext}% only for dummy text \renewcommand*\letterpagemark{% \usekomafont{pagenumber}{\thepage}} \begin{document} \begin{letter}{Max} \opening{Hello,} \Blindtext \closing{Bye} \end{letter} \end{document} Another ...


1

The book class uses the plain page style for the first page of the chapter. Here is the definition in book.cls: \newcommand\chapter{\if@openright\cleardoublepage\else\clearpage\fi ----------->> \thispagestyle{plain}% <<----------- \global\@topnum\z@ \@afterindentfalse \secdef\@...


1

As you load titlesec, I would use \titleps via the [pagestyles] option, which has a \sectiontitle command. Here is a code for a two-sided layout: \documentclass[a4paper, twoside, 12pt, fleqn]{article} \usepackage{lastpage} \usepackage[pagestyles]{titlesec} % \titleformat{\section}[display]{\centering\Large\bfseries}{}{0pt}{\underline} \usepackage{lipsum} \...


1

Something similar can be achieved in at least two ways. -1- Since the document is single page, there is no need for a headers or footers. \documentclass[a4paper]{article} \usepackage[left=0.5in,right=0.5in,top=0.5cm,bottom=1cm]{geometry} \usepackage[demo]{graphicx} \usepackage{adjustbox} \usepackage{tikz} \usepackage{lipsum} \begin{document} % In a ...


1

The layout of the first letter page is special. The page style of the first letter page is empty. It uses special elements for the address, location, header, footer etc. You have to use variable firstfoot to add content in the footer of the first page. If you redefine \pagemark to get »Page ... of ...«, then you can use \centering\pagemark for firstfoot: \...


1

The footer on the first page of a letter is empty by default. You will need to define your own first-page footer using the firstfoot variable and set its position from the top of the page with the firstfootvpos variable. Switch the footer on with the firstfoot=true option. The subsequent footers (done with \cfoot from the scrlayer-scrpage package in your ...


1

I only made some tidy up to your MWE and included dummy text and figures in the proper places. As recommended by IEEEtrans I added flushend to balance the columns of the last page and used [ht] instead of [h]. It compiled OK without warnings. If you are still experiencing difficulties with your document it is not coming from this setup. % !TeX TS-...


1

Using the .map file from here from 11 years ago: https://github.com/somadeva/RomDev and compiling to .tec binary using teckit_compile: (1) To obtain Devanagari characters via the RomDev mapping, type using the Latin characters that are in the RomDev mapping. R is not mapped. R+vowel is mapped, and r+consonant is mapped and so on, but not R+consonant. (2) ...


1

Just for fun. I seriously doubt the journal will let you do this. %%%%%%%%%%%%%%%%%%%%%%% file template.tex %%%%%%%%%%%%%%%%%%%%%%%%% % % This is a general template file for the LaTeX package SVJour3 % for Springer journals. Springer Heidelberg 2010/09/16 % % Copy it to a new file with a new name and use it as the basis % for your article. Delete % ...


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