1

I'm writing a thesis and I will be provided a standard front page by my school. The front page have cut-out area. On the next page I will show some detailed information about the thesis. I was provided a word template but I would rather not use Word.

Cut out

So I'm looking for some method to create a non-framed fixed size box in a fixed location. The box should be 60mm x 110mm with left top corner located at (140mm,50mm). (The A4 Paper is 297mm x 210mm).

I will have to be able to modify the text by size, bold, centering horizontally and vertically inside the box.

I have taken a look at:

\documentclass{article}
\usepackage{lipsum}

\begin{document}
    \lipsum[1]
    %\parbox[position][height][inner-pos]{width}{text}
    %\mbox{text}
    %\makebox[width][pos]{text}
    %\fbox{text}
    %\framebox[width][pos]{text}

\end{document}

But they don't seem to work the way I want. I'm also thinking if this would be possible with minipages?

  • Is the form really rectangular or with rounded edges? – user31729 Sep 9 '16 at 14:26
  • The front page cut-out is actually oval, but I would only need a rectangular box for my text. – Bjartmar Sep 9 '16 at 14:37
2

The textpos package allows for absolute (or relative) positioning) of content on a page -- here absolute is too be chosen.

The size and position values have to be specified as numbers only, i.e. without units. In order to inform textpos about the real dimensions, the lengths \TPVertModule and \TPHorizModule must be defined, here they are equal to 1mm both.

The tcolorbox is just meant for quick setup of the box!

\documentclass[a4paper]{article}
\usepackage[absolute]{textpos}
\usepackage[skins]{tcolorbox}
\usepackage{lipsum}

\setlength{\TPVertModule}{1mm}
\setlength{\TPHorizModule}{1mm}

\newcommand{\myboxwidth}{110}
\newcommand{\myboxheight}{60}
\newcommand{\myboxposx}{50}
\newcommand{\myboxposy}{140}

\begin{document}
\lipsum[1]

\begin{textblock}{\myboxwidth}(\myboxposx,\myboxposy)
  \noindent%
  \begin{tcolorbox}[left skip=0pt,width={\dimexpr\myboxwidth mm},boxrule=0pt,nobeforeafter,enhanced jigsaw,height={\dimexpr\myboxheight mm},colback=red]
  \end{tcolorbox}
\end{textblock}
\end{document}

\end{document}

enter image description here

  • Nice Christian, would you know a way to center the inserted text vertically? I've tried \vfill before and after text. I've tried \vspace*{\fill}. I've tried \begin{vplace}[0.5]text\end{vplace}. – Bjartmar Sep 9 '16 at 15:54
  • @bjartmar: Do you mean the \lipsum text above the 'cut-out'? – user31729 Sep 9 '16 at 17:02
  • No, I mean the text inside the textbox/colorbox you provided. I found it in the tcolorbox help. [halign=flush center, valign=center] does the trick. :) – Bjartmar Sep 9 '16 at 19:40
  • @bjartmar: Yes, that's the code. tcolorbox is pretty smart ;-) – user31729 Sep 9 '16 at 19:42
  • Yes, never heard of this package. Will come really handy! Thanks again. :) – Bjartmar Sep 9 '16 at 20:52

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.