diff gnv-artifacts/src/main/java/de/intevation/gnv/chart/VerticalProfileChart.java @ 315:63f8b3fb7d9a

Localization of chart axis with locale which fits best to server and browser settings. gnv-artifacts/trunk@373 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Thu, 26 Nov 2009 08:47:44 +0000
parents 45625b5cd6d4
children 22a6493e8460
line wrap: on
line diff
--- a/gnv-artifacts/src/main/java/de/intevation/gnv/chart/VerticalProfileChart.java	Thu Nov 26 08:45:04 2009 +0000
+++ b/gnv-artifacts/src/main/java/de/intevation/gnv/chart/VerticalProfileChart.java	Thu Nov 26 08:47:44 2009 +0000
@@ -7,11 +7,13 @@
 import org.apache.log4j.Logger;
 
 import org.jfree.chart.ChartTheme;
+import org.jfree.chart.axis.Axis;
+import org.jfree.chart.axis.NumberAxis;
+import org.jfree.chart.plot.XYPlot;
+import org.jfree.chart.plot.PlotOrientation;
 import org.jfree.data.xy.XYSeries;
 import org.jfree.data.general.Series;
 import org.jfree.data.xy.XYSeriesCollection;
-import org.jfree.chart.plot.XYPlot;
-import org.jfree.chart.plot.PlotOrientation;
 
 import de.intevation.gnv.geobackend.base.Result;
 
@@ -124,6 +126,12 @@
     }
 
 
+    protected void localizeDomainAxis(Axis axis, Locale locale) {
+        // call localizeRangeAxis from superclass which formats NumberAxis
+        super.localizeRangeAxis(axis, locale);
+    }
+
+
     protected String createSeriesName(
         String breakPoint1,
         String breakPoint2,
@@ -136,4 +144,4 @@
             "m";
     }
 }
-// vim:set ts=4 sw=4 si et sta sts=4 fenc=latin1 :
+// vim:set ts=4 sw=4 si et sta sts=4 fenc=utf-8 :

http://dive4elements.wald.intevation.org