I’m importing SVGs with imagick using this syntax
$graphic = new Imagick($this->img);
The problem is this image is imported with a white background. How can I change the white background to a transparent one, or make imagick keep then transparent background when importing the SVG.
I can’t help you with imagick. However, I know that an SVG with a transparent background gets converted to a PDF with transparent background if I use this ImageMagick ClI command:
and if I use
the PDF indeed has a gray background.