Skip to content

ccworld1000/CCColor

master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
lib
 
 
 
 
 
 
 
 
 
 
 
 

CCColor

Simple and flexible color color conversion module for Perl 6 , 
easy-to-use simple learning.

HEX Color (use CCColor)

colors

See test

use CCColor;

my @list =
(
"   #FFFEA963 ",
"   #FF FE A9 63 ",
"   #FF # FE #   A9 #     63 ",
"   #",
"   #1",
"   #123",
"   #FFH",
"   #FHF",
"   #1234",
"   #12345",
"   #FFEE5",
"   #FFEE56",
"   #FFEE56A",
"   #FFEE56AH",
"   #FFEE56AA",
"   #FFEE56AA11",
"   #FFEE56AAFF11",
);

for @list -> $color {
  my ($r, $g, $b, $a) = hex2rgba($color);
  say "$r, $g, $b, $a";
}

Call test/test.p6

test

Local installation and unloading

zef install .
zef uninstall CCColor

Network install

zef update
zef install CCColor

About

Simple and flexible color color conversion module for Raku Perl 6 , easy-to-use simple learning.

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Other 100.0%