Greetings,

I'm using the following settings for fancyhdr in a two-page book-derived documentclass:

\pagestyle{fancy}
\fancyhf{}
\fancyfoot[LO]{\footnotesize \thepage~{\color{red}\vline}}
\fancyfoot[RE]{\footnotesize {\color{red}\vline}~\thepage}
\fancyfootoffset{0.5cm}
\fancypagestyle{plain} {
\fancyhf{} % get rid of headers on plain pages
\renewcommand{\footrulewidth}{0pt} % and the line
}
\renewcommand{\footrulewidth}{0pt}


But, somehow, the page number on even pages gets slightly below those on odd...

Help? :)

-

I'm not quite sure the reason for your problem, but it goes away if I change to \textcolor{red}{\vline} instead of {\color{red}\vline}.

-

This is a known problem: \color doesn't switch to horizontal mode (it doesn't "start a line"). So if you are in vertical mode (as you are e.g. at the start of a \parbox) the following text which starts horizontal mode is forced on a new line. You get this effect e.g. in \parbox or in p-cells of a tabular. The solution is either to use \textcolor as already suggested or to quite vmode before the color command.

\documentclass{article}
\usepackage{xcolor}
\begin{document}
xxx
\parbox[t]{1cm}{abc}
\parbox[t]{1cm}{\color{red}abc}
\parbox[t]{1cm}{\leavevmode\color{blue}abc}
\end{document}

-