-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Supporting Spot Colors #756
Comments
Just testing, this is awesome! |
I have no problems admitting my ignorance. Or lack of skill. I have no idea how to use this feature based on the diffs in your commit. We have an app that generates SVG files. It includes some custom SPOT tags that we created. Do you have a JavaScript example showing how to actually use the SPOT support? |
Hi @mlgoff59 "pdfkit": "github:sajjad-shirazy/pdfkit.js",
"svg-to-pdfkit": "github:sajjad-shirazy/SVG-to-PDFKit#0.1.8", in your code: const doc = new PDFDocument();
// adding spot colors
doc.addSpotColor('RDG_GLOSS', 50, 25, 25, 0);
doc.addSpotColor('RDG_WHITE', 25, 25, 25, 25); and in your svg: <rect fill="RDG_GLOSS" width="300" height="100"/>
<path fill="RDG_GLOSS" d="M150 0 L75 200 L225 200 Z" />
<text fill="RDG_WHITE" x="0" y="15">TEST</text> |
Thank you for the quick response. I assume that instead of RDG colors I could use CYMK: doc.addSpotColor('CYMK', 100, 96, 0, 10); Is that correct? Okay, my ignorance is showing. I just learned that CYMK is not SPOT colors. the question would be better stated, "Am I required to use Roland DG color palettes?" You know I think I just figured it out. Sorry to bother you. |
devongovett can this be added to main repo? Thanks :) |
Note that if you are using Pattern Dictionaries, SPOT will not work. the pattern dictionaries are imcompatible with the SPOT color spaces. See Postscript Langauge Ref 3 section 5 for more details. |
@sajjad-shirazy still it's not clear to me on how we're supposed to use your fork., to have addSpotColor functionality available. @devongovett any chance that you'll add spot color support to the official repo? |
@naretini, unfortunately, pdfkit doesn't maintain anymore, if you want to use my fork, add these lines to the dependencies within your
and then:
|
@sajjad-shirazy thanks. OT: Since pdfkit doesn't maintain anymore. Do you know any alternative (still maintained) nodejs (npm) package that supports vector graphics and spot colors? |
This should be a high-priority issue. It is such an important feature for anyone that does anything with printing and cutting technology*. (*) It is important for multiple reasons. Two main ones are: (1) to print PANTONE colors (beyond RGB and CMYK), and (2) to define curves that should not be printed but have some other function (like cut-curves). |
I'm trying to use this fork to specify some SVG cut-curves that should not be printed. These need to be labelled with Lab Spot colour (not RGB or CMYK). @ziaenezhad is that possible with this fork? If so, could you kindly show me how I would use it for this? |
Hi pdfkit,
i implemented support of spot colors in my fork:
ziaenezhad@6cbbeef
The text was updated successfully, but these errors were encountered: