{graphics} is about inclusion of external graphic files in your document. For questions about vector graphics created programmatically inside a (La)TeX document, use {diagrams} instead, or preferably the tag for specific packages like {tikz-pgf}, {pstricks}, or {metapost}.

learn more… | top users | synonyms (4)

11
votes
2answers
3k views

Macro for \textwidth, \textheight and keepaspectratio

I'm using many pictures within my beamer presentation. Somehow I'm tired of writing: \begin{figure} \includegraphics[width=0.8\textwidth,height=0.8\textheight,keepaspectratio]{source} ...
11
votes
2answers
1k views

Side brace around image with underbrace

I have an image and I want to put a side brace on the left and an underbrace on the bottom. The underbrace works fine, but the left becomes twice the image height for some reason. I'm sure the image ...
11
votes
1answer
228 views

Copyright issue, replace bitmaps by empty frame

I have a thesis to submit tomorrow as .pdf. The University requires written permission from the copyright holder for every figure taken from book/journal--a thing I don't have, and I didn't know was ...
11
votes
1answer
4k views

Why does the image not appear?

I'm using IEEEtran to format an article, and I wanted to include an image. I included the graphicx and hyperref packages, and used the following code, like normal, to include an image. ...
11
votes
3answers
547 views

How to trim / clip / crop graphics without trial and error?

Often I include graphics with the trim option. Everytime I have to start a trial and error search for the right values. Is it possible to do it more straight forward?
11
votes
3answers
2k views

Print frames rather than boxes with demo/draft version of graphics/graphicx

I recently switched to demo such that I could compile my .tex file without needing the actual image files. Now, instead of the image there is a black box. Is there anyway to get a black border such ...
11
votes
8answers
3k views

What do people use for modifying figures?

I usually create figures for my articles in Matlab: various plots of numerical and analytical solutions. One thing that I don't like about it is that the font is different in the figure and in the ...
11
votes
1answer
2k views

How to produce Latex QR-Code (or in general 2d codes) as Vector graphic?

The pst-barcode package is great to produce bar-codes in all flavors. And it does 1d bar-codes like a charm. Also it is capable of generating 2d bar-codes with a command like this for a qrcode: ...
11
votes
1answer
299 views

Use images for drawing an arrow

Is it possible to draw arrows (preferential with TikZ) with two images: One for the line and one for the tip? I would like to realize something like this:
11
votes
1answer
353 views

Can you embed an image so it doesn't need to be stored as a separate file?

I'd like to know whether it is possible to embed an image file into LaTeX code, such that the picture will appear in a resulting PDF file without it having to be stored in a separate .eps file during ...
11
votes
2answers
2k views

How to align picture top left in a table?

is there a way to create a table with 2 columns, in the left column should be some text, in the right column should be a picture. The problem is - to align both to the left, top corner. The image ...
11
votes
1answer
10k views

Image from \includegraphics showing in wrong image size

When I use the following to embed an image: \begin{figure}[htb] \centering \includegraphics{my_image} \caption{blaaa} \label{fig:blaaa} \end{figure} whereas my_image is a JPG file, the ...
11
votes
1answer
158 views

XeTeXpicfile in vertical mode

Given a minimal like \line{% \vtop{\hsize=.6\hsize Lorem ipsum dolor sit amet, consectetur adipiscing elit. Suspendisse tempor lectus sit amet laoreet convallis. Quisque at est lacinia, porttitor ...
11
votes
1answer
253 views

How do I use same figure multiple times?

Is there a way to use same figure multiple times -- without reinserting it? That is I don't want to pay it's weigth several times in the output pdf file. I remember I saw someone telling adjustbox ...
11
votes
1answer
165 views

Compile a LaTeX file ignoring missing EPS graphics

I am proofreading a paper for someone else. I have the .tex file but no EPS graphics files. I would like to make a PDF file to read the changes in text that I made, but I keep getting errors because ...
11
votes
2answers
332 views

Creating a URL downloading command to be used with e.g. \includegraphics

We were just talking about an idea that may be a little further out there. Would it be possible to patch URL support into graphicx.sty or is there a package that would support this on a wider scale (I ...
11
votes
1answer
607 views

Driver specification for hyperref and graphicx

When using hyperref and compiling via pdflatex or dvips, I do not need to specify the driver with \usepackage{hyperref}. However when compiling via dvipdfm this fails and I have to specify the driver ...
11
votes
5answers
7k views

Graphicspath for MikTeX

Is there a way to specify a \graphicspath that includes all sub-directories? I know I could put all my graphics in a texmf tree, but I'd like to have them in another directory tree. As far as I can ...
11
votes
1answer
371 views

Telling Tikz/Tex to produce raster instead of vector in resulting PDF

I am using MikTeX and Tikz package to generate images (playing cards on A4 paper). The result is nice, but slow (too many vector objects, printing is hell slow). Is there a way to directly tell TeX ...
11
votes
1answer
754 views

Images off the page in multicols environment

Before my question, some background information. I’ve created an algorithm (not latex) which will generate a catalog for a collection of books dynamically. A user supplies information to query an SQL ...
11
votes
1answer
90 views

Inline purified PostScript (MPS)

I just learned how to inline PDF code using the \pdfliteral command and that purified Encapsulated PostScript generated by METAPOST or purifyeps can be converted to PDF code by pdfLaTeX. However, I ...
11
votes
1answer
356 views

Drawing primitive shapes with TikZ

I want to draw this picture as a noob, the way I usually do (for all other images) is to painstakingly draw line by line and manually adjusting their coordinates to get the shapes I want. I have ...
11
votes
1answer
3k views

Trim image by number of pixels

Is it possible to trim an image by a certain number of pixels rather than a length? I have a set of images that I'm including, and in one figure, a trim of 135 on the bottom works nicely, but a ...
11
votes
1answer
593 views

Resulting document size when Including a graphics file multiple times - pgf vs. graphicx

In his answer to the question Tikz: using external images as building blocks. Stefan Kottwitz says: The pgf way may be preferred if the document size matters and graphics are multiply used or if ...
11
votes
1answer
241 views

Random number without repetition in an \includegraphics

I have 58 images in PDF format. At the moment, each of them is in a separate PDF, such as 1.pdf, 2.pdf etc. I would like to include those 58 images in a random order without repetition. I found the ...
11
votes
1answer
133 views

How to get information about remaining free space?

following scenario: I want to automatically generate a newsletter with some small articles, which is working fine. (I am generating LaTeX-code with data from a small database). But now I want to ...
11
votes
1answer
495 views

Exclude images for printing pdf

I have a document that has images that are very, very dark. As such, they should not be printed when the user goes to print. Somebody I'm working with loves to print, and they use a lot of toner ...
11
votes
2answers
1k views

Ploting a function using mplib in lualatex

This question asked about ways to generate a nice function graph in LaTeX. There are several great answers, however, most of the either rely on an external program to generate the plot, or, if they ...
11
votes
1answer
2k views

Two column layout with text and knitr chunk

When making presentations (with latex beamer class), I often go for a frame layout with text and equations on the left and a corresponding figure on the right. My standard solution has been to wrap ...
10
votes
4answers
1k views

Drawing the mapping of elements for sets in LaTeX

I am looking for a way to do something like
10
votes
4answers
1k views

What is the easiest way to plot a function and its tangent lines at the turning points?

I want to plot graphs like this and embed them as Tikz or Pstricks code in my handouts. I know that there are software such as Ipe, LaTeXDraw etc. But none of them can satisfy me. Because Ipe doesn't ...
10
votes
2answers
21k views

How to include a PDF image into a PDFLaTeX document

I am generating a PDF file using pdflatex and need to include another PDF file. The reason is that I have a graphMl file which I exported from yEd graph editor to a PDF file, named sample.pdf. The TeX ...
10
votes
3answers
2k views

University's logo

How to put the logo before the date and after my name in the title? I write it as \begin{document} \title{} \author{} \titlepic{ \includegraphics[width=0.5\textwidth]{logo} \date{} but ...
10
votes
5answers
5k views

Are there any packages for creating charts?

I'm looking for a package in which you can create nice bar and/or line charts in LaTeX. Currently I'm plotting the charts in Calc (OpenOffice), export it to a PDF document, crop it and then including ...
10
votes
5answers
474 views

How to fill the limits of the two curves?

I want to fill the limits of the two curves (as shown). This is my code \documentclass[10pt]{article} \usepackage{pgf,tikz} \usetikzlibrary{arrows} \pagestyle{empty} \begin{document} ...
10
votes
2answers
672 views

Using an image as a table

I have an image containing tabular data and would not like to convert this to a real table. What I do want is for this image to have a proper caption and be included in the listoftables. Is it ...
10
votes
5answers
5k views

Convert gif image to png on the fly

I am using pdflatex on linux and attempting to convert gif to png. I can run scripts to find out the image attributes and even and convert the files supplied from a folder but I can not write back to ...
10
votes
3answers
2k views

Nature style files and figures

I downloaded a Nature style file from here but I don't see any images when I build my figures. Do you know if this is intentional or if I've done something wrong? If you've drafted a LaTeX paper for ...
10
votes
2answers
2k views

How to put round cornered frame around an image

I want a nice colored frame around an image which has rounded corners. Here is my attempt, using mdframed, but, as you can see, the inner edge of the frame is a right-angle, and not rounded. I would ...
10
votes
4answers
487 views

Check for a valid file before using \includegraphics

I know how to check if a given argument represents an existing file (see this question). But is there also a possibility to check if this file can be included by \includegraphics? What I want to ...
10
votes
2answers
482 views

Format a tutorial with screenshots in LaTeX

I want to format a step-by-step tutorial in LaTeX in a way that each step shows one screenshot and a small piece of text for that step. I could think of a formatting where in each step the screenshot ...
10
votes
3answers
5k views

How to refer a figure as a table?

I have a question regarding LaTeX .. I have a table from an excel file which I print screened and posted as a figure in LaTeX. However, I want to make it a table. Problem is, the particular table has ...
10
votes
2answers
1k views

How to include eps files in Plain TeX? [duplicate]

The title stands for itself. If it is not possible, how does LaTeX import an EPS file using \includegraphics?
10
votes
1answer
3k views

Insert a TikZ picture from an external file

I tried to search a bit, but i guess my poor English prevented me from finding the answer. I made a few tikz pictures that i want to use in my report. I made the tikz pictures in separate tex files ...
10
votes
2answers
433 views

Textures or pictures as background for a table.

I wonder how I can set a texture or a picture in the background of a table. I have tried to google it but I haven't found any satisfactory answer :-( I try to explain better: I know that it is ...
10
votes
2answers
693 views

How to use a macro inside \includegraphics options?

I have to do several figures like this: \begin{figure}[h!] \centering \includegraphics[trim = 9.55cm 1.8cm 10.25cm 4.05cm, ...
10
votes
3answers
8k views

How to avoid showing the filename when using graphicx?

I am writing a LaTeX document with the apacite and graphicx package. The issue is when I include an image either using figure with an enclosed \includegraphics or \includegraphics by itself it shows ...
10
votes
3answers
564 views

Rounded box with image and text

I'm trying to create a rounded box with both text and image. The desired result is as this: Where the image is rounded at the left edges. I have managed everything except the the image part using ...
10
votes
2answers
2k views

Inserting an image in plain TeX

I used the OzTeX implementation of TeX, also I used to typeset my docs in plain TeX, not LaTeX for me, so I had no problem to insert an image using the OzTeX, now I'm back to TeX docs, am using the ...
10
votes
2answers
18k views

LaTeX Error: Unknown graphics extension: .ps

When I try to compile this file http://danjer.doudouke.org/_media/tech/dokutexit/playground.zip this error occurs: ! LaTeX Error: Unknown graphics extension: .ps. I'm using TeXworks Version 0.4.3 ...