Is there a way to write on pictures using LaTeX, and I don't mean like including graphics and all, I mean like writing on pictures directly. Any suggestions?
Asked
Active
Viewed 128 times
0
-
2You can use TikZ as described in the answers to this question: https://tex.stackexchange.com/q/9559/45161 – René B. Christensen Nov 07 '20 at 10:36
1 Answers
1
The major problem is find the correct coordinates inside the image. For this purpose you could use TikzEdt. For example if the image is (myLogo.png):
You can import it inside a tikzpicture in TikzEdt as show in the code in this image:
Now you can know the coordinates of points inside the image. They are in the right bottom corner. For example using the previous image, you can easily do this:
The previous figure was generate using TikzEdt for find the correct coordinates and draw the other elements (red arrow and rectangle) and then the resulting tikzpicture is being put inside a standalone document. The code is the following:
\documentclass[tikz,border=3mm]{standalone}
\begin{document}
\begin{tikzpicture}[
lSt/.style={red,line width=7pt},
wrSt/.style={font=\fontencoding{T1}\fontfamily{ptm}\fontsize{45}{45}\bfseries}]
\node{\includegraphics{TikzEdtWindowCapture}};
\draw[lSt] (14,-8.5) rectangle (15.7,-9.7)coordinate (v1);
\draw[lSt] (v1) -- +(-45:1cm) node[below,wrSt]{coordinate of the figure};
\draw[<-,>=stealth,lSt] (9.3,2.4) .. controls (14.5,2.1) and (19.5,2.5) .. (19.4,6.1)node[above,wrSt]{my logo};
\end{tikzpicture}
\end{document}
vi pa
- 3,394


