Graphi...r::CMYK(3pm)
π Graphics::Color::CMYK π
okay bestie, welcome to the Graphi...r::CMYK page β it's part of the User Contributed Perl Documentation, and it's literally your girl for all things cyan-magenta-yellow-key. let's get into it β¨
π NAME π
Graphics::Color::CMYK β the CMYK color model, but make it Perl π
β VERSION β
version 0.31 β yes she's been around a minute, and she still slays π«Ά
π SYNOPSIS π
here's the vibe, copy-paste ready, no cap:
use Graphics::Color::CMYK;
my $color = Graphics::Color::CMYK->new({
cyan => 120,
magenta => .5,
yellow => .25,
key => .5
});
see? you just hand her your numbers and she's like "got it bestie, that's a color now" π β¨
π¦ DESCRIPTION π¦
so Graphics::Color::CMYK represents a Color in the CMYK color model. and in case anyone's ever wondered what the letters actually stand for β Cyan stands for Cyan Magenta Yellow Key (or black). yes, Key. iconic naming honestly. the K is the main character and nobody talks about it ππ
πΈ ATTRIBUTES πΈ
these are the lil knobs you get to twist, and every single one has a short alias because we love efficiency in this house β¨
cyan,cβ Set/Get the cyan component of this Color πmagenta,mβ Set/Get the magenta component of this Color πyellow,yβ Set/Get the yellow component of this Color πkey,kβ Set/Get the key (black) component of this Color π€nameβ Get the name of this color. only valid if the color was created by name. so like, if you made her by name she'll tell you her name, if you made her with numbers she's gonna stay mysterious π
π§ METHODS π§
the moves she knows. the tricks. the little routines. obsessed π
as_stringβ Get a string version of this Color in the form of:
CYAN,MAGENTA,YELLOW,KEY
commas and everything, exactly like that, she's very particular about her format π
as_percent_stringβ Return a percent formatted value for this color. percent signs, we love a girl who shows her work πβ¨as_arrayβ Get the CMYK values as an array. just the numbers, lined up, ready for whatever πequal_toβ Compares this color to the provided one. Returns1if true, else0; fr fr, that's the whole contract π«Άnot_equal_toβ The opposite ofequal_to. she's the hater twin, and honestly? valid π
π AUTHOR π
Cory G Watson <gphat@cpan.org> β thank you for your service, king π«‘π
βοΈ COPYRIGHT AND LICENSE βοΈ
This software is copyright (c) 2014 by Cold Hard Code, LLC.
This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. so like, go wild, but respectfully β¨
heads up bestie: this whole page isperl v5.34.0energy, dated2022-06-14, and it lives underGraphi...r::CMYK(3pm)in the manual. that's the footer, but make it cute πΈ
and that's the whole page. stay colorful, stay blessed, hydrate, and may your key never be undefined πππ
π¦ where this page comes from
- debian bookworm: libgraphics-color-perl 0.31-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- debian trixie: libgraphics-color-perl 0.31-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu noble: libgraphics-color-perl 0.31-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libgraphics-color-perl 0.31-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libgraphics-color-perl 0.31-2 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms