Few things, its not line 443 of GD.pm, its line 443 of Graph.PM. And from the GD::Graph POD...
=item dclrs (short for datacolours)
This controls the colors for the bars, lines, markers, or pie slices.
This should be a reference to an array of colour names as defined in
L<GD::Graph::colour> (S<C<perldoc GD::Graph::colour>> for the names av
+ailable).
$graph->set( dclrs => [ qw(green pink blue cyan) ] );
This makes your color choices fail because later on in Graph you there is a line (at line # 443) that does a:
_rgb($self->{dclrs}[$_[0] % @{$self->{dclrs}} - 1]);
Update:
If you want to specifiy colors outside of the redefined list in GD::Graph::colours, you must use:
add_colour(colourname => [$r, $g, $b]) or add_colour('#7fe310')
Self-explanatory. Exported with the :colours tag.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.