Closed GoogleCodeExporter closed 9 years ago
This is a limitation of the PDF implementation on Mac OS. It doesn't support
transparency in gradients. That's why bars filled with a transparent color
work, but not the ones with a gradient fill (the "tubular" bars).
See these links for more info:
http://www.cocoabuilder.com/archive/cocoa/289044-problem-using-nsgradient-with-d
atawithpdfinsiderect.html
http://cocoawithlove.com/2011/01/advanced-drawing-using-appkit.html for more
information.
Until Apple builds support for a later version of PDF into the OS, your options
are to avoid gradients and stick to the solid colors or to output to PNG.
Original comment by eskr...@mac.com
on 21 Jun 2011 at 11:43
Hi Guys. A quick question about this reported limitation. Does the problem
simply result in bar charts with incorrect color fills OR will this combination
produce exceptions during the generation of PDF data?
I ask because we are struggling with an intermittent bug that appears to be
related to some code in the CPTGradient class. You can see in the attached
image that we get a EXEC_BAD_ACCESS error.
This error occurs during a process where we are writing multiple (approx 28 to
38) charts into a PDF file. We first generate the PDF data for each chart
individually, cache that data to disk as a PDF file, then draw it back into the
master PDF file in the final step. It is during this final step that the error
sometimes occurs. We have not had much success nailing it down to a specific
plot. It seems very random at this time.
Some of our core plot charts do have bar charts using gradient fills, so we'll
try playing with those settings to see if we can correct the problem, but any
feedback you can provide would be helpful.
Thanks!
Original comment by chronics...@gmail.com
on 23 May 2012 at 5:08
Attachments:
This issue only occurs when gradients use non-opaque colors. Do all of the
intermediate graphs look ok if you open the PDF files separately? If your app
is crashing after all of the individual graphs have been generated, I don't
think the problem is related to Core Plot.
Original comment by eskr...@mac.com
on 23 May 2012 at 11:02
Original issue reported on code.google.com by
eriksbac...@gmail.com
on 21 Jun 2011 at 4:20