3

I need to create a PDF with a vectorial graphic for a personalized packaging project. I can create the PDF with the embedded SVG but our graphic need 2 spot color for the lines so the CMYK print isnt messed up.

This screen is the PDF he created as an example image1 and this is the PDF i created. image2

I tried manual editing of SVG+PHP+TCPDF, commandline Inkspace or commandline ImageMagick but i didnt find a way to insert a spot color.

Can someone help me?

2
  • Note that many renderers do not support SVG CMYK or Spot Color representations. Also, you will not see a "Spot" color in PDF in a viewer because the viewer has no knowledge of them. You should see a fallback RGB color that you also specify. RenderX XEP supports CMYK and Spot color in SVG. See stackoverflow.com/questions/27968635/… Apr 28, 2017 at 13:45
  • 1
    Thanks you, it works! I was on the right track but there was a strange problem. I mention it in case someone need it. If you do stroke="rgb(0,255,0) icc-color(#CMYK, 26%, 50%, 99%, 24%)" its a spot color, if you do stroke="#00FF00 icc-color(#CMYK, 26%, 50%, 99%, 24%)" its not!
    – gmazzotti
    May 8, 2017 at 14:35

1 Answer 1

2

Thanks to @kevin-brown for the answer! I post a full example for reference

<rect x="503.1" y="396.9" fill-rule="evenodd" fill="none" stroke="rgb(0,255,0) icc-color(#CMYK, 26%, 50%, 99%, 24%)" stroke-width="0.5916" stroke-miterlimit="3.8637" width="113.4" height="396.9"/>

1
  • Technically that is CMYK. If you have a SPOT color like Pantone, you would use something like rgb-icc(255,255,0, #SpotColor,'Pantone 355-Green C',0.30, #CMYK,.7,0,0.5,.6) in HTML and %'s in SVG. See cloudformatter.com/CSS2Pdf.Demos.Colors May 9, 2017 at 17:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.