是否可以(如何)从matplotlib向pdf添加专色? [英] Is it possible (how) to add a spot color to pdf from matplotlib?
问题描述
我正在创建一个必须使用(多个)专色的图表。此颜色可能是RGB或CMYK都无法访问的颜色。是否可以在matplotlib中为某行指定专色并将其导出为pdf?直接导出是首选方法,但不是必需的方法。
注意: A
最近我在寻找类似的东西,我不知道您是否能够找到它,但是ReportLab的方法是PCMYKColorSep。
因此您可以集成
上面的示例实际上并没有与matplotlib集成在一起,但是它确实添加了斑点。
p>
c = Canvas('test.pdf',(420,200))
language_spot = PCMYKColorSep(0.0,100.0,91.0,0.0, spotName ='LanguageSpot',密度= 100)
c.setFillColor(language_spot)
c.rect(300,75,100,100,fill = True,stroke = False)
c。 save()
I am creating a chart which has to use (multiple) spot colors. This color could be one that is neither accessible from RGB nor CMYK. Is there a possibility to specify a spot color for a line in matplotlib and export this to pdf? Direct export is preferred but not necessary.
Note: A
I was looking for something like this recently, I don't know if you managed to find it, but ReportLab has a method that is PCMYKColorSep.
So you could integrate the graph from matplotlib within a reportlab canvas, and add as many color separations as you see fitting.
The example above doesn't actually integrate with matplotlib, but it does add the spot
c = Canvas('test.pdf', (420, 200))
language_spot = PCMYKColorSep(0.0, 100.0, 91.0, 0.0, spotName='LanguageSpot', density=100)
c.setFillColor(language_spot)
c.rect(300, 75, 100, 100, fill=True, stroke=False)
c.save()
这篇关于是否可以(如何)从matplotlib向pdf添加专色?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!