1

I have a picture that I would like to place on the frontpage of a student paper that I am working on, and it is being pushed on to the next page by LaTeX. I want it to be placed in a specific place, which will cause it to cross left, bottom and right margin for text. Is there any way of placing the image independently of the margins?

Heres an example that looks like what I'm doing

\documentclass[10pt,a5paper]{article}
\usepackage{tikz}

\begin{document}

\begin{tikzpicture}[remember picture,overlay]
\draw (0pt,0.3\textheight) -- (0pt,-\textheight) -- (\textwidth,-\textheight) -- (\textwidth,0.3\textheight) -- cycle;
\end{tikzpicture}
{
\hspace{110pt}
\fontsize{120}{120}\selectfont Title
    }

\begin{figure}[h!]
\vspace*{-50pt}
\hspace*{-15pt}
\includegraphics[width=387pt]{imagename}
\end{figure}

\end{document}

Edit: I don't know if the image width here works with this simpler example, but it's what I want in the original document.

5
  • 1
    Is the picture the only thing on the page?
    – egreg
    Commented May 3, 2014 at 20:20
  • Floating figure environment?
    – user31729
    Commented May 3, 2014 at 20:26
  • @egreg: No, there is also some text, and a tikz drawing for framing. I am not familiar with Floating figure environment. Will look into it though!
    – Delta t
    Commented May 3, 2014 at 20:39
  • 1
    Can you add a schematic example of what you have?
    – egreg
    Commented May 3, 2014 at 20:39
  • 1
    @Deltat Please, click on edit below your question and add the code there. After adding the text, select it and click on the {} button above the typing box.
    – egreg
    Commented May 3, 2014 at 21:01

2 Answers 2

2

I guess your TikZ "picture" is meant to draw a rectangle around the lower 70% of the text block. If so, be sure to add \noindent before drawing the rectangle.

Since I don't have access to the file imagename.pdf, I've modified the code below to draw a generic black rectangle of width \textwidth.

enter image description here

\documentclass[10pt,a5paper]{article}
\usepackage[demo]{graphics} % just for this example
\usepackage{tikz}
\begin{document}
\noindent % need to add this instruction
\begin{tikzpicture}[remember picture,overlay]
\draw (0pt,0.3\textheight) -- (0pt,-\textheight) -- (\textwidth,-\textheight) -- (\textwidth,0.3\textheight) -- cycle;
\end{tikzpicture}
{
\hspace{110pt}
\fontsize{120}{120}\selectfont Title
}


\begin{figure}[h!]
%\vspace*{-50pt}
%\hspace*{-15pt}
\includegraphics[width=\textwidth]{imagename}
\end{figure}
\end{document}
2
  • My main issue is that the image becomes too long, and therefore jumps into the next page. Is there any way of preventing this?
    – Delta t
    Commented May 3, 2014 at 21:30
  • @Deltat - not knowing how big the image is in real life, I'm afraid I can't give firm advice. You could try \includegraphics[width=\textwidth, height=0.45\textheight, keepaspectratio]{imagename}
    – Mico
    Commented May 3, 2014 at 21:50
1

I found a solution that works. Since tikz can draw a picture outside of the margins for me already, that's what I'm using it for anyways, I used it to draw the picture I wanted as well. I altered the lines in my code to be:

\begin{tikzpicture}[remember picture,overlay]
\node (mypicture) at (194pt,-330pt) {\includegraphics[width=387pt]{picture}};
\draw (0pt,0.3\textheight) -- (0pt,-\textheight) -- (\textwidth,-\textheight) -- (\textwidth,0.3\textheight) -- cycle;
\end{tikzpicture}

The coordinates and width of the picture are just the ones that worked in my original document. Probably won't work in this example version.

You must log in to answer this question.

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