Graphi...r::CMYK(3pm)

πŸ“¦
version 0.31 Β· 2 versions
  • 0.31 Β· debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking (latest)
  • 0.31 Β· ubuntu jammy
, in debian bookworm, debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking

πŸ’– 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. Returns 1 if true, else 0; fr fr, that's the whole contract 🫢
  • not_equal_to β€” The opposite of equal_to. she's the hater twin, and honestly? valid πŸ’€

πŸ‘‘ AUTHOR πŸ‘‘

Cory G Watson <gphat@cpan.org> β€” thank you for your service, king πŸ«‘πŸ’–


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 is perl v5.34.0 energy, dated 2022-06-14, and it lives under Graphi...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