changeset 6530:2afe2fe12576

FixWQCurveGenerator: Make second axis initial extends match first one.
author Felix Wolfsteller <felix.wolfsteller@intevation.de>
date Tue, 02 Jul 2013 15:03:04 +0200
parents da0249ddcba7
children 52d160b16a4c
files artifacts/src/main/java/org/dive4elements/river/exports/fixings/FixWQCurveGenerator.java
diffstat 1 files changed, 8 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/artifacts/src/main/java/org/dive4elements/river/exports/fixings/FixWQCurveGenerator.java	Tue Jul 02 09:57:55 2013 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/exports/fixings/FixWQCurveGenerator.java	Tue Jul 02 15:03:04 2013 +0200
@@ -404,6 +404,14 @@
                 addAxisSeries(series, YAXIS.W.idx, visible);
             }
             else {
+                StyledXYSeries series2 = JFreeUtil.sampleFunction2D(
+                        func.getFunction(),
+                        doc,
+                        aaf.getFacetDescription(),
+                        500,   // number of samples
+                        0.0 ,  // start
+                        maxQ); // end
+                addAxisSeries(series2, YAXIS.W.idx, false);
                 // Use second axis at cm if at gauge.
                 for (int i = 0; i < series.getItemCount(); i++) {
                     series.updateByIndex(i, new Double(factor*(series.getY(i).doubleValue()-gaugeDatum)));

http://dive4elements.wald.intevation.org