Mercurial > dive4elements > river
changeset 4650:31327b3b2455
XYChartGenerator: Avoid "range merging" for area series, as these might extend
to fake "infinity" in case of showing an area "above axis". Explain this in code
and remove a TODO.
author | Felix Wolfsteller <felix.wolfsteller@intevation.de> |
---|---|
date | Thu, 06 Dec 2012 13:10:27 +0100 |
parents | 64664e8244ff |
children | 83a42e6a562d |
files | flys-artifacts/src/main/java/de/intevation/flys/exports/XYChartGenerator.java |
diffstat | 1 files changed, 6 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/flys-artifacts/src/main/java/de/intevation/flys/exports/XYChartGenerator.java Wed Dec 05 23:58:26 2012 +0100 +++ b/flys-artifacts/src/main/java/de/intevation/flys/exports/XYChartGenerator.java Thu Dec 06 13:10:27 2012 +0100 @@ -130,9 +130,10 @@ public void addArea(StyledAreaSeriesCollection series) { this.datasets.add(series); List<?> allSeries = series.getSeries(); - for (int n = 0; n < allSeries.size(); n++) { - includeYRange((XYSeries)allSeries.get(n)); - } + /* We do not include the bounds/ranges, if the area includes + * points at "infinity"/BIG_DOUBLE_VALUE, the charts extents are + * expanded to include these very small/big value. + * This is especially used when showing "area above axis". */ } /** True if to be rendered as area. */ @@ -469,9 +470,9 @@ axisDataset.addArea(area); } else { - // TODO only range merging. + /* No range merging, for areas extending to infinity this + * causes problems. */ } - //TODO range merging. }