Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#1109 Waterfall: 0 values get color of last bar.

1.0.x
closed-fixed
David Gilbert
None
5
2013-11-21
2013-04-22
m.hilpert
No

We noticed this by setting custom colors: if a (middle) bar has value 0, the smal line (for value 0) will be shown in the color that is set for the last bar.

Discussion

  • Amish Dimitri
    Amish Dimitri
    2013-10-25

    Hi M.Hilpert,

    We analyzed the issue and found that we could replicate with the following steps:

    A) Create a DefaultCategoryDataset object containing the following values:

    DefaultCategoryDataset dataset = new DefaultCategoryDataset();
    dataset.addValue(10, "BUG", "A");
    dataset.addValue(20, "BUG", "B");
    dataset.addValue(0, "BUG", "C");
    dataset.addValue(10, "BUG", "D");
    

    B) Create the WaterfallBarChart object using the ChartFactory class and passing
    in the dataset created in step 1.

    C) Use ChartUtilities to save the chart as a JPEG file. Notice that the colour of the 3rd column (C) matches the colour of the last bar.

    We are working on fixing this issue and will submit it to the developer mailing list for review soon.

    Thank you for positing this issue.

     
  • David Gilbert
    David Gilbert
    2013-11-21

    I've committed the fix for this, to be included in the upcoming JFreeChart 1.0.17 release.

     
  • David Gilbert
    David Gilbert
    2013-11-21

    • status: open --> closed-fixed
    • assigned_to: David Gilbert