The following is the MWE (Following code is taken from here, with slight modifications):
\documentclass[tikz]{standalone}
\tikzset{
use bounding box relative coordinates/.style={
shift={(current bounding box.south west)},
x={(current bounding box.south east)},
y={(current bounding box.north west)}
},
label/.style={draw=golden-rod},
}
\begin{tikzpicture}
\node[use as bounding box] {\includegraphics{example-image-a}};
\begin{scope}[use bounding box relative coordinates]
\node[label][golden-rod] (Label) at (0.3,0.3) {GR};
\draw[golden-rod] (Label.west) edge[-stealth] (0.1,0.35)
(Label.west) edge[-stealth] (0.1,0.25);
\end{scope}
\end{tikzpicture}
\end{document}
The problem I am facing is that I am not able to use the color Goldenrod available from the xcolor package. When I run the above code, I get the following errors:
- Package pgf Error: Unknown arrow tip kind 'golden'
- Package pgf Error: Unknown arrow tip kind 'rod'
- Package xcolor Error: Undefined color 'golden-rod'
When I change "golden-rod" to "Goldenrod" I get the following errors:
- Package pgf Error: I do not know the key '/tikz/Goldenrod' and I am going to ignore it. Perhaps you misspelled it.
- Package xcolor Error: Undefined color 'Goldenrod'.
In general, I am not able to use the colors whose name has two parts. Is there a way around this?
xcolordefines a color calledGoldenrodas opposed togolden-rod. – leandriis May 02 '20 at 16:21