TransWikia.com

Page markings in Revtex 4

TeX - LaTeX Asked by DrM on April 30, 2021

How do I add page markings to specific pages, in Revtex 4?

And, how do I wrap long page markings?

Specifically, I need to add a sentence, “This page may contain proprietary information ….” on each of a range of pages.

Here is a partial example with all of the packages that I am using in the document.

The text inside of the markboth, needs to be wrapped.

documentclass[pra,11pt,nofootinbib]{revtex4}
usepackage{amsmath}    % need for subequations
usepackage{amssymb}    % need for subequations
usepackage{graphicx}   % need for figures
usepackage{subfigure}  % use for side-by-side figures
usepackage{enumitem}

usepackage{placeins}
usepackage{makecell}
usepackage{framed}
usepackage{changebar}

pagestyle{myheadings}

begin{document}

section{Introduction}
Some text, blah blas

label{firstsecret}

markboth{}{May contain trade secrets or commercial or financial information that is privileged or confidential and exempt from public disclosure.}

Here goes some big secret, more blah blah


label{laststsecret}

end{document}

One Answer

One solution appears to be to use the fancyhdr package, as follows.

For the preamble we can use this to establish a plain-like pagestyle, with pagenumbers in the upper right.

usepackage{fancyhdr}
pagestyle{fancy}
fancyhf{}
renewcommand{headrulewidth}{0pt}
rhead{thepage}

Then to add text to the center position of the header on the current page, with line wrap,

chead{Long sentence with line wrap here followed by the rest of the sentence.}

And we can reset everything and go back to numbers only, with

fancyhf{}
renewcommand{headrulewidth}{0pt}
rhead{thepage}

Caveat, some care needs to be applied with respect to where the lines are inserted and take effect.

Answered by DrM on April 30, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP