Chart:...er::Pie(3pm)

πŸ“¦
version 2.90 Β· 3 versions
, in ubuntu noble, ubuntu resolute, ubuntu stonking

πŸ’– Chart::Clicker::Renderer::Pie β€” the perl(1) page, but make it cute πŸ₯§

okay bestie, welcome to the User Contributed Perl Documentation for Chart::Clicker::Renderer::Pie(3pm). yes that's the whole manual name, it's giving very "my full legal name" energy but we move. this is the pie renderer for Chart::Clicker and it is lowkey iconic.


✨ NAME ✨

Chart::Clicker::Renderer::Pie β€” Pie renderer πŸ₯§

🌸 VERSION 🌸

version 2.90 β€” she's grown, she's thriving

πŸ¦‹ SYNOPSIS πŸ¦‹

  my $pier = Chart::Clicker::Renderer::Pie->new;
  # Optionally set the stroke width
  $pier->brush->width(2);

so you spin up a new Chart::Clicker::Renderer::Pie, and if you want, you can also set the stroke width on the brush with $pier->brush->width(2). that's the whole vibe check.

πŸ’œ DESCRIPTION πŸ’œ

Chart::Clicker::Renderer::Pie draws a dataset as slices of a pie. that's the main character move.

here's the tea though: the keys of like-named Series get totaled up, and the keys themselves? ignored. periodt. so like, take a dataset like this:

  my $series = Chart::Clicker::Data::Series->new(
      keys    => [ 1, 2, 3 ],
      values  => [ 1, 2, 3],
  );

  my $series2 = Chart::Clicker::Data::Series->new(
      keys    => [ 1, 2, 3],
      values  => [ 1, 1, 1 ],
  );

the keys are just tossed πŸ’€ and a pie chart gets drawn where $series' slice is at 66% (because 1 + 2 + 3 = 6) and $series2's slice is at 33% (because 1 + 1 + 1 = 3). math ate and left no crumbs, fr fr.


πŸŽ€ ATTRIBUTES πŸŽ€

🩷 border_color

Set/Get the color used for the border. it's the little outline that holds the whole look together, iykyk.

πŸ–ŒοΈ brush

Set/Get a brush to be used for the pie's border. this is the brush that's doing the border's whole lewk.

🌈 gradient_color

if you supply this, it specifies a color to mix with each slice's color, and the result gets used as a radial gradient. the best results usually come from mixing with a white or a black and then manipulating the alpha, like so:

  $ren->gradient_color(
    Graphics::Color::RGB->new(red => 1, green => 1, blue => 1, alpha => .3)
  );

the above will cause each generated color to fade toward a lighter version of itself ✨. adjust the alpha to increase or decrease the effect β€” more alpha, more drama.

πŸ–ŒοΈ brush (yes, again πŸ’€)

Set/Get whether or not the gradient is to be reversed. not me seeing brush listed twice in this doc β€” she's mysterious, she contains multitudes, and we're keeping both entries exactly as written.

πŸ“ starting_angle

Set/Get a starting angle for the gradient. where the fade begins, bestie. she gets to choose.


πŸ‘‘ AUTHOR πŸ‘‘

Cory G Watson <gphat@cpan.org>

This software is copyright (c) 2016 by Cory G Watson.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.


and that's the whole page, no notes 🫢

k bye bestie, this doc was shipped as part of perl v5.36.0 on 2022-10-14, and the manual it came from is Chart:...er::Pie(3pm). go make some beautiful pies, slay πŸ’…πŸ₯§

πŸ“¦ where this page comes from