How to export Highcharts with CMYK colors?

By : kmas
Source: Stackoverflow.com
Question!

I would like to know if there is a way to export charts from Highcharts with CMYK colors ? I have read nothing in Highcharts API about CMYK.

I have no problem to export them in PDF and also in SVG with php exporting-server but only with RGB colors.

  • Do I have to configure something in CSS/Javascript before exporting ?
  • Do I have to change something in the page of the exporting server ?

Any suggestions is welcome. Thanks.

By : kmas


Answers

I would suggest you just edit the colors in Adobe Illustrator. Even if you could convert to CMYK, there's no telling how that would actually look. You would want to adjust them anyways to get as close to the desired color as possible.



We are using the Highcharts export module (with PhantomJS) to generate charts with cmyk colors. Instead of rgb colors, you just put cmyk values in the options-json, like this:

"borderColor": "rgb-icc(0%,125%,197%,#CMYK,83.82%,43.76%,0%,0%)"

If you export as svg, you have a chart in cmyk, which you can use in a cmyk pdf! The browser can't handle this (and shows all colors as black), but that doesn't matter, you have svg with cmyk, and now all you need is a way to convert this to a pdf.

By : iddo


This video can help you solving your question :)
By: admin