I have a document with a graphics and I want to replaced this graphics with another as part of a revision. To make this clear I want to show the old version of a figure next (or below) to the new version, but struck out.

I tried using the changes package (\deleted around the \includegraphics command) which gives an error and also with the sout package, which gives a weird result.

How can strike out a graphics reliable in LaTeX?

   \includegraphics{old} \\ %strike this figure out, with a diagonal, horizontal or cross lines

2 Answers 2


You can modify the selected answer to this question to get what you've asked:

  overlay={\draw[red,line width=5pt] (interior.south west)--(interior.north east);
    \draw[red,line width=5pt] (interior.north west)--(interior.south east);}}

\caption{Use the correct diagram!}

The output in Gummi looks like this: enter image description here

  • Thank you. 1) this deserves to be somehow used by one of the strike out packages. 2) changes could fall back to this when other types of strike out don't work (see comment in tex.stackexchange.com/a/135334/1871)
    – alfC
    Dec 8, 2018 at 3:41
  • 3
    When I copy and paste this code, adjust the image file names, and run it, the cross appears behind the image -- what am I doing wrong?
    – NCH32
    Feb 4, 2019 at 10:21
  • This worked, though (you may have to adjust the location of the corners to the size of your image, or vice versa): \documentclass{article} \usepackage{graphicx,tikz} \begin{document} \begin{tikzpicture} \node(mypic){\includegraphics[width=2in]{image}}; \node[above left of = mypic](corner1){}; \node[above right of = mypic](corner2){}; \node[below left of = mypic](corner3){}; \node[below right of = mypic](corner4){}; \draw[red, thick](corner1)--(corner4); \draw[red, thick](corner2)--(corner3); \end{tikzpicture} \end{document}
    – NCH32
    Feb 4, 2019 at 10:55
  • Yes, the cross appears behind the image. I don't know how to get in on top of the image, but the approach does avoid the hassle of adjusting the location of the corners.
    – DJP
    Feb 4, 2019 at 14:41
  • 1
    Thanks to @NCH32 , I got to find a way to locate the cross in front of the image as well as automatically fit the cross to the size of your image! tex.stackexchange.com/q/487546/185010 Dec 27, 2021 at 7:05

Here is my solution, adapted from an answer over here


        \node[anchor=south west,inner sep=0] (image) at (0,0) {
        \begin{scope}[x={(image.south east)},y={(image.north west)}]
            \draw[red,line width=1 mm] (0, 1)--(1, 0);
            \draw[red,line width=1 mm] (0, 0)--(1, 1);

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.