Okay, with the following code, I was able to make an exploding pie chart.

There are things here that I'm not happy with. Ideally, the ...::Pie::_write_ser should mostly just run the ::Chart::_write_ser but somehow insert the call to _write_explosion; I didn't know how to do that. It may be that the "right" answer is for ::Chart::_write_ser to include the call to _write_explosion itself, rather than having the ::Pie do it... Maybe then having ::Chart::_write_explosion be empty but ::Chart::Pie::_write_explosion be defined as in my code. But for the v1.00 and v1.09 of Excel::Writer:::XLSX, the code I shared worked.

Again, really, it should be incorporated into the distribution with a feature request -- if you do create such a feature request, you have my permission to point the author to this post, and the author may include the code I presented here with whatever fixes or adaptations are necessary to make it work with the distro as a whole.


In reply to Re^2: XLSX::Chart::Pie -> Exploding by pryrt
in thread XLSX::Chart::Pie -> Exploding by sectokia

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • 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:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.