4

I'm trying to design a title page by modifying the Legrand Orange Book template.

Here's a MWE of the code I'm working with:

\documentclass[11pt]{article}
\usepackage{tikz}
\begin{document}
\begingroup
\thispagestyle{empty}
\begin{tikzpicture}[remember picture,overlay]
\draw (current page.center) node [fill=blue!30!white,fill opacity=0.6,text opacity=1,inner sep=1cm]{\Huge\centering\bfseries\sffamily\parbox[c][][t]{\paperwidth}{\centering TITLE \\ Second Row of Title\\[15pt] % Book title
{\Large Project work report}\\[20pt] % Subtitle
{\huge Name Surname}}}; % Author name
\end{tikzpicture}
\vfill
\endgroup
\end{document}

The output right now is this: Current title page

What I'm aiming to achieve is something like this (nevermind the grey area above the rectangle): Expected title page

In short, I'd like to superimpose a white dashed line on the top side of the blue rectangle. Not only I don't know how to achieve that kind of dashing in TikZ, but since the rectangle has variable size I can't figure out how to impose a style for the top side.

Just to clarify, I don't care about the text. My question only relates to the design of the background rectangle.

Thanks a lot to anyone that will help.

1 Answer 1

5

Add a name to the backagorund box and use it as reference for the dashed line:

\documentclass[11pt]{article}
\usepackage{tikz}
\begin{document}
\begingroup
\thispagestyle{empty}
\begin{tikzpicture}[remember picture,overlay]
\draw (current page.center) node [fill=blue!30!white,fill opacity=0.6,text opacity=1,inner sep=1cm] (Title) {\Huge\centering\bfseries\sffamily\parbox[c][][t]{\paperwidth}{\centering TITLE \\ Second Row of Title\\[15pt] % Book title
{\Large Project work report}\\[20pt] % Subtitle
{\huge Name Surname}}}; % Author name
\draw[dashed, white, line width=4mm] ([yshift=-2mm]Title.north west)--([yshift=-2mm]Title.north east);
\end{tikzpicture}
\vfill
\endgroup
\end{document}

enter image description here

1
  • Very good :-). I like it.+1
    – Sebastiano
    Commented Oct 3, 2017 at 9:03

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .