Home/ Reference/ Color

app.CreateCMYKColor(Cyan, Magenta, Yellow, Black)

Builds a CMYK color, each component 0-100. If the job ends up on press — brochures, packaging, business cards — start from CMYK instead of forcing an RGB conversion

Signature

app.CreateCMYKColor(Cyan, Magenta, Yellow, Black)

Notes

Builds a CMYK color, each component 0-100. If the job ends up on press — brochures, packaging, business cards — start from CMYK instead of forcing an RGB conversion later.

Python example (runnable)

Requires pywin32. The example assumes app / doc / page / layer are already connected. See Connection & Init
Python
c = app.CreateCMYKColor(100, 0, 7, 0)               # press blue
print("CMYK: ", c.CMYKCyan, c.CMYKMagenta, c.CMYKYellow, c.CMYKBlack)
print("Is CMYK: ", c.IsCMYK)                        # True

shape = app.ActiveSelectionRange(1)
shape.Fill.ApplyUniformFill(c)

About this section: Color

Color — RGB, CMYK and hex color values.

Other entries in this section