I'm not that familiar with TikZ and I want to use it for designing by front page. I want a blue bar in the top, where some text is centered in the bar. Like following (how do I center the text without using hspace to push the text in?)

\begin{tikzpicture}[remember picture,overlay]
  \node [xshift=\,yshift=-2cm] at (current page.north west)
  [text width=\textwidth,fill=my_defined_blue,below right]
   \hspace{3.5cm} \textcolor{white}{\Large{\textsc{School Name}}}

However, I also want a logo on bar, which should be a bit larger than the bar. Any suggestions, how this should be done?

The logo structure: Logo structure


Is this what you're looking for? The frame around the logo is drawn "by hand", so if you have a complicated shape, your suggestion of using a transparent PNG with a white border might be more practical.




\begin{tikzpicture}[remember picture,overlay]

\coordinate [below=2.5cm] (midpoint) at (current page.north);

\node [name=colourbar,
text = white,
minimum width=\paperwidth,
minimum height=1cm] at (midpoint) {\huge{\textsc{School Name}}};

% Define the point where the logo will go
\coordinate [right=4cm] (logo) at (colourbar.west);

% Set coordinate system origin
% Draw the outline
\filldraw [white,draw=red] (2.3,0.85) -- (-2,0.85) -- (-2.8,-0.85) -- (2.3,-0.85) --cycle;
% Include the logo
\node {\includegraphics[width=4cm]{logo}};


\section{Normal stuff starts here}


Title page with TikZ

  • Nice! Yes, something like that. I have edited the my post, with the more tricky part of the bar. The logo should is in between the red area. My backup solution to this, is to use a transparent png image in the corner with a white background. Do you have a better suggestion? – aagaard Jan 21 '11 at 11:05
  • This example is giving this error l.26 \node {\includegraphics[width=4cm]{logo}} – Aku Jan 21 '11 at 14:01
  • "logo" refers to a file called "logo.png" that needs to be in the same directory as the tex file. I used the LaTeX logo found on Wikipedia. – Jake Jan 21 '11 at 14:06

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.