Skip to content


Subversion checkout URL

You can clone with
Download ZIP


CMYK pdf inverts color when opened in Illustrator #359

robzolkos opened this Issue · 8 comments

4 participants


I have produced a CMYK PDF using prawn. The background image I used is a cmyk jpg and then apply prawns text commands to it. When I open the PDF in any application it looks correct. However opening it in Adobe Illustrator, the background has inverted colors.

I am not sure what is causing this or how to resolve. But I need to be able to open the PDF generated by prawn and edit it in Illustrator. Hopefully someone has heard of this happening and knows a fix.

Ive put an example PDF in this repo

yob commented

Hi Rob,

Thanks for the report. When I open the sample pdf on my system (in evince and Acrobat X) it has a yellow heading, white type and a black background. Is that correct?

Unfortunately I don't have illustrator handy at the moment, but I'd like to clarify the issue first.


What you are seeing in evince and Acrobat X is correct. I have attached a screenshot of what is looks like when opened in Illustrator.

Screen Shot 2012-12-11 at 4 34 44 PM

@practicingruby practicingruby removed the stale label

Did we ever sort out what this issue was?


@robzolkos: If you can restore your bug example repo, we can take a closer look. Just to confirm, you've reproduced the problem on Prawn 1.0.0 (just released last night)?


I'm seeing the exact same issue, but with completely different tools, so I don't think the issue is specifically related to prawn.

I'm converting a RGB jpg to CMYK using imagemagick, then inserting the image in a PDF using the Node.js pdfkit library.

Just like on your end, the PDF looks ok in all PDF readers (evice, okular, acrobat, etc.), but the image colors are inverted when opened in Illustrator.

Have you found any work-around?


Seems that, at least on my end, I've managed to find a work-around for the issue, by using the -interlace flag, when converting the image to CMYK with ImageMagick, making a progressive jpeg.


An example showing the issue is here:

hello.pdf is the generated pdf. Opening in Illustrator the colors are inverted.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.