# [texhax] Overpic and placing defined blocks of text

Wed Sep 23 16:05:31 CEST 2015

as always in this kind of problems, please provide some code, then we have a better opportunity to help.

That being said, I've found tikz a lot easier to work with in placing stuff on top of an image.

\documentclass[a4paper]{memoir}
\usepackage{graphicx,tikz}
\begin{document}

\begin{tikzpicture}
% (0,0) now lies in the lower left hand corner of the image
\node[inner sep=0pt,anchor =south west] at (0,0)
{\includegraphics[width=8cm]{example-image-a}};
% help grip easier to know where to place stuff, delete when done.
\draw[very thin,opacity=0.25] (-1,-1) grid [step=5mm] (9,7);
\node[red] at (3,4) {Some text};
\end{tikzpicture}

\end{document}

(the image comes along with the mwe package)

I've left the overpic package when I noticed problems when you add legends outside the image, then the size (seen from LaTeX) of the image, does not change. Thus centering looks strange.

This does not happen when using the tikz approach

Institut for Matematik / Department of Mathematics
Aarhus Universitet / Aarhus University

________________________________________
From: texhax [texhax-bounces at tug.org] on behalf of richard terry [rterry at internode.on.net]
Sent: 23 September 2015 00:31
To: texhax at tug.org
Subject: [texhax] Overpic and placing defined blocks of text

Hi List,

Hope this reaches the list, my first post. To put this in context I've
used a little bit of latex, nothing really complex and relative novice
without a good computer brain.

I've just used it to print data out onto forms, sometimes generate
de-novo, at other times as in the case of this question, using overpic
to print onto an existing PDF form.

Mostly the text I have to put on the form is really basic like
name/address etc, in which case I just use \put.

I have several spots on my latest form I need to put a larger amount of
text in a text block at (x,y) with a certain width in cm and hieght in cm.

I've looked at a number of possible commands and can't seem to get any
to work.

I wondered if anyone who uses overpic can give me a concrete example
(not just the syntax)  of how to do this.

Thanks in anticipation.

Richard
_______________________________________________
TeX FAQ: http://www.tex.ac.uk/faq
Mailing list archives: http://tug.org/pipermail/texhax/