I have created a svg graphic with inkscape and use it in my LaTeX document. The graphic has a couple colorful lines with corresponding colorful arrowheads. Unfortunately pdflatex seems to arbitrarily assign the colors to the arrowheads. Exporting the svg to png in inkscape results in the correct arrowheadcolors, but then of course my math looks ugly. Has anyone experienced the same and knows of a way to get the correct arrowhead colors? There are already two different colors, so it's not like all arrowheads are treated the same.
Here is my minimal example
\documentclass{article}
\usepackage{svg}
\usepackage{graphicx}
\begin{document}
\begin{figure}
\includesvg{arrowhead}
\caption{wrong colors of arrowheads in svg version}
\end{figure}
\begin{figure}
\includegraphics{pngarrowhead}
\caption{correct colors in png version}
\end{figure}
\end{document}
Here is the resulting pdf (screenshot thereof)
Here the png exported with inkscape (pngarrowhead.png)
And here is the original svg file. Sorry, but I cannot input it here directly, so I share it via a filehoster.
<svg width="98.852mm" height="46.58mm" version="1.1" viewBox="0 0 98.852 46.58" xmlns="http://www.w3.org/2000/svg">
<defs>
<marker id="Arrow1Mend" overflow="visible" orient="auto">
<path transform="matrix(-.4 0 0 -.4 -4 0)" d="m0 0 5-5-17.5 5 17.5 5z" fill="context-stroke" fill-rule="evenodd" stroke="context-stroke" stroke-width="1pt"/>
</marker>
<marker id="Arrow1Mstart" overflow="visible" orient="auto">
<path transform="matrix(.4 0 0 .4 4 0)" d="m0 0 5-5-17.5 5 17.5 5z" fill="context-stroke" fill-rule="evenodd" stroke="context-stroke" stroke-width="1pt"/>
</marker>
</defs>
<g transform="translate(-35.241 -73.283)">
<path d="m37.042 119.06 47.625-21.167" fill="#0f0" marker-start="url(#Arrow1Mstart)" stop-color="#000000" stroke="#008000" stroke-dasharray="8, 8" style="font-variation-settings:normal"/>
<g>
<path d="m84.667 95.25-47.625-21.167" fill="none" marker-end="url(#Arrow1Mend)" stroke="#f0f"/>
<path d="m84.667 95.25 47.625-21.167" fill="none" marker-end="url(#Arrow1Mend)" stroke="#00f"/>
<path d="m84.667 95.25 47.625 21.167" fill="#0f0" marker-end="url(#Arrow1Mend)" stroke="#0f0"/>
<path d="m37.042 116.42 47.625-21.167" fill="#f00" marker-end="url(#Arrow1Mend)" stop-color="#000000" stroke="#f00" style="-inkscape-stroke:none;font-variation-settings:normal"/>
</g>
<text x="72.760414" y="82.020821" fill="#000000" font-family="sans-serif" font-size="10.583px" letter-spacing="0px" stroke-width=".26458" word-spacing="0px" style="line-height:1.25" xml:space="preserve"><tspan x="72.760414" y="82.020821" stroke-width=".26458">$x^2$</tspan></text>
</g>
</svg>