Forum How do I...?

SVG, CMYK, & font's

jacobfogg
So I have got SVG mostly working (I am using it to create vertical text on my page), I have even come up with an algorithm to establish an estimated height/width for the svg viewport...

So, I am trying to figure out how with SVG to incorporate CMYK colors into the text... I have tried the following:

fill="red icc-color(#CMYK, 0%,100%,100%,0%)"

as well as:
fill="red icc-color(#CMYK, 0,100,100,0)"


Which, from what I can tell is the method you should use... it however comes back black... thankfully, in the pdf that black is K from CMYK, so it seems as if it is sortta working...


Secondly, I am trying to incorporate different fonts in the SVG, I was wondering what the best method of accomplishing that to work with prince will be.

Thanks for the advice!
Jake
mikeday
CMYK colors can be included as "cmyk(0, 1, 0.5, 0)" which should work in CSS and SVG. As you point out, we don't support the standard method for including CMYK colors in SVG, but we should, so I'll add it to the development roadmap.

As for fonts, how about just using font-family?
jacobfogg
Thanks, the CMYK trick worked perfectly!... also, it seems that as long as I specify the font families in the css, I can refer to the font family names in the svg and it works as well!

Yeah PRINCE! =)