Acme-AutoColor
view release on metacpan or search on metacpan
lib/Acme/AutoColor.pm view on Meta::CPAN
use 5.006;
use strict;
use warnings;
use Graphics::ColorNames 0.32;
our $VERSION = '0.04';
our $Colors;
sub import {
my $class = shift;
# TODO: parse version numbers
$Colors = Graphics::ColorNames->new(@_);
}
package main;
use Carp qw( croak );
use Graphics::ColorNames qw( hex2tuple );
our $AUTOLOAD;
sub AUTOLOAD {
my $class = shift;
$AUTOLOAD =~ /.*::(\w+)/;
my $cname = $1;
if($cname eq "OCTARINE") {
# Discworlds eigth color. Can't display it yet,
# but as far as we know, R, G and B are zero,
# and O is 255
if(wantarray) {
( run in 0.342 second using v1.01-cache-2.11-cpan-a5abf4f5562 )