I have an SVG file, which I have made/edited with Inkscape. I want to include this image in my thesis. The svg file is here: http://brussense.be/temp/theSVG.svg
(because Inkscape uses a non-standard feature it does not render correctly in most browsers)
I exported it with Inkscape to get this PDF (v1.5): http://brussense.be/temp/PDFed.pdf
(this file looks fine in Acrobat Pro X)
Here's an MWE for the inclusion of the PDF in a LaTeX document:
\documentclass[a4paper]{report}
\usepackage[xetex,hiresbb]{graphicx}
\begin{document}
\begin{figure}[!h]
\centering
\includegraphics[width=\textwidth]{PDFed.pdf}
\caption{Some caption}
\end{figure}
\end{document}
My problem is that when I compile this with XeLaTeX (with the xdvipdfmx driver) the colors of the image have visibly changed in the resulting pdf: http://brussense.be/temp/XeTeXed.pdf
I also tried exporting to a v1.4 PDF from Inkscape but the result is the same.
I know a very similar question was asked here: \includegraphics PDF, color problem
But there are two differences:
-
as far as I know my svg file does not contain transparent objects, nor alpha blending (all colors have the alpha channel at 255), nor any blurring or other filters
-
the question was specific to pdftex and the suggested solution causes a compilation error in XeLaTeX
Does anyone know how I can fix this? I see various possible ways to tackle the problem, but so far I haven't been succesful:
- some setting change in Inkscape
- some (non-visible) change in the svg file
- some postprocessing on the PDF file (I already played with ICC profiles and such but I totaly new to this)
- some changes in my LaTeX code
- some parameter for XeLaTeX or xdvipdfmx
- something else?
Best Answer
Looking into the PDF I see a PageGroup (Object 19), so \includegraphics PDF, color problem might indeed apply. Try exporting as PDF 1.3 - there should be no PageGroup then.