Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I have created some graphics in gnuplot using set terminal epslatex color and I rather liked them in my paper. However, once I tried to put them into Latex Beamer slides the way I put them into my paper,they where to big.

I reference the genrerated *.tex file like this:


This file contains the labels and axises, which are in latex and make it look so nice. The file in turn references the actual graph (a pdf file, generated from the corresponding eps file, which gnuplot made) using an \includegraphics

Now I want to resize it to, say 90% of the free space on a slide. Setting \includegraphics[keepaspectratio=true,height=0.7\paperheight] alone won't do, since then the picture is smaller, but the labels are still the same.

How do I make both smaller: the stuff in the *.tex file and the included image? Bonuspoints, when I do not have to go back to gnuplot and regenerate the graphics from scratch.

share|improve this question
Have you tried \resizebox? You put all your stuff in a box and set its size to fit your slide –  Lionel MANSUY Jan 21 '13 at 14:39
I didn't know that one and it does exactly what I want it to. If you would post that as an answer I can 'accept' it. Or I could post it myself. –  albifant Jan 21 '13 at 14:52
add comment

1 Answer 1

up vote 1 down vote accepted

You could try the command \resizebox{width}{height}{box}. For exemple:

\resizebox{!}{.7\paperheight}{code of the box to resize}

will resize your box to 70% of the paper height, with respect to aspect ratio.

Note that if you provide both width and height, the aspect ratio will not be kept.

share|improve this answer
To make it complete: \resizebox{!}{\textwidth}{\input{./path/to/*.tex}} is what I used. –  albifant Jan 21 '13 at 15:21
add comment

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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