Juergen Spitzmueller schrieb:

Gerhard Lindel wrote:


I have use headings in my document and it is realized with the following
LATEX-preambel (page-style is fancy):
\lhead{text...}
\rhead{}
\chead{}
\lfoot{text}
It looks quite fine but my professor wants it in a box and with grey or
blue background.



I do not understand what you want exactly.



If you want the whole header with grey background, you can try to do something like this:


\usepackage[dvips]{graphicx,color} \usepackage{fancybox}

\definecolor{mygrey}{gray}{0.9}
\setlength{\fboxsep}{0pt}
\renewcommand{\headrulewidth}{0pt}

\fancyput(\oddsidemargin,-2.5\headheight){\colorbox{mygrey}
{\phantom{\rule{\textwidth}{1.5\headheight}}}}

\lhead{text...}
\rhead{}
\chead{}

If only the header's text should be in a grey box, you could try

\usepackage[dvips]{graphicx,color} \usepackage{fancybox}

\definecolor{mygrey}{gray}{0.9}
\setlength{\fboxsep}{0pt}
\renewcommand{\headrulewidth}{0pt}

\pagestyle{fancy} \fancyhead{}
\fancyhead[L]{\colorbox{mygrey}{\parbox[c][<boxheight>]{<boxwidth>}{text}}}


HTH,
Jürgen.




Dear Jürgen,
I am sorry, but it seems that I am only able to produce a lot of Latex-Errors.
What I want to do is: The headers text should have a grey background and smaller letters as the normal text. With my preambel there is a line under the header: how can I create a header without this line?
All my trials ended with many errors.
The documentclass is article (koms-script) and page style is fancy. Shall I use annother class or pagestyle?
I hope you are not angry with me but I need your help .
Gerhard




Reply via email to