# HG changeset patch # User Felix Wolfsteller # Date 1349342826 -7200 # Node ID e064e781d2552971dcdfcad947b10d6bf6756a49 # Parent 017e3d8526e02c1756a80c4a098a6c0b4df955e2# Parent 7cc05da7e35c76cc020f4c41beb58fc212c5d8d7 Merged. diff -r 017e3d8526e0 -r e064e781d255 flys-artifacts/ChangeLog --- a/flys-artifacts/ChangeLog Thu Oct 04 11:25:27 2012 +0200 +++ b/flys-artifacts/ChangeLog Thu Oct 04 11:27:06 2012 +0200 @@ -7,6 +7,18 @@ flys-artifacts/doc/conf/virtual-themes: Remove not needed theme props from main-value-annotations. +2012-10-04 Christian Lins + + * flys-artifacts/src/main/java/de/intevation/flys/exports/LegendProcessor.java, + flys-artifacts/src/main/java/de/intevation/flys/exports/TimeseriesChartGenerator.java: + Cosmetics, comments. + + * flys-artifacts/src/main/resources/messages.properties, + flys-artifacts/src/main/resources/messages_de.properties, + flys-artifacts/src/main/resources/messages_de_DE.properties, + flys-artifacts/src/main/resources/messages_en.properties: + Add message for 'state.chart.km' (#899). + Add message for 'state.chart.km' (#899). 2012-10-02 Felix Wolfsteller * flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/AnnotationRiverState.java: diff -r 017e3d8526e0 -r e064e781d255 flys-artifacts/src/main/java/de/intevation/flys/exports/LegendProcessor.java --- a/flys-artifacts/src/main/java/de/intevation/flys/exports/LegendProcessor.java Thu Oct 04 11:25:27 2012 +0200 +++ b/flys-artifacts/src/main/java/de/intevation/flys/exports/LegendProcessor.java Thu Oct 04 11:27:06 2012 +0200 @@ -1,15 +1,13 @@ package de.intevation.flys.exports; import java.awt.geom.Line2D; - import java.util.ArrayList; import java.util.HashMap; import java.util.Iterator; +import java.util.LinkedHashMap; import java.util.List; -import java.util.LinkedHashMap; import java.util.Map; -import org.jfree.chart.JFreeChart; import org.jfree.chart.LegendItem; import org.jfree.chart.LegendItemCollection; import org.jfree.chart.plot.XYPlot; @@ -68,7 +66,7 @@ * Create new legend entries, dependent on settings. * @param plot The plot for which to modify the legend. * @param threshold How many items are needed for aggregation to - * be triggered? + * be triggered? */ public static void aggregateLegendEntries(XYPlot plot, int threshold) { LegendItemCollection old = plot.getLegendItems(); @@ -82,8 +80,8 @@ } HashMap> entries = new LinkedHashMap>(); - for (Iterator i = old.iterator(); i.hasNext();) { - LegendItem item = (LegendItem) i.next(); + for (Iterator i = old.iterator(); i.hasNext();) { + LegendItem item = i.next(); String hash = legendItemHash(item); List itemList = entries.get(hash); if (itemList == null) { @@ -110,7 +108,7 @@ List itemList = cursor.getValue(); if (itemList.size() >= AGGR_THRESHOLD) { // Now do merging. - LegendItem item = (LegendItem) itemList.get(0); + LegendItem item = itemList.get(0); // Unfortunately we cannot clone and just setDescription, as this // method was added in JFreeChart 1.0.14 (we are at .13). diff -r 017e3d8526e0 -r e064e781d255 flys-artifacts/src/main/java/de/intevation/flys/exports/TimeseriesChartGenerator.java --- a/flys-artifacts/src/main/java/de/intevation/flys/exports/TimeseriesChartGenerator.java Thu Oct 04 11:25:27 2012 +0200 +++ b/flys-artifacts/src/main/java/de/intevation/flys/exports/TimeseriesChartGenerator.java Thu Oct 04 11:27:06 2012 +0200 @@ -228,6 +228,7 @@ adaptZoom(plot); applySeriesAttributes(plot); + addAnnotationsToRenderer(plot); addLogo(plot); aggregateLegendEntries(plot); @@ -770,6 +771,7 @@ (StyledTimeSeries)getSeriesOf(data, j); String key = series.getKey().toString(); if (attributes.containsKey(key)) { + // Interpolated points are drawn unfilled if (attributes.get(key).equals("interpolate")) { XYLineAndShapeRenderer renderer = series.getStyle().getRenderer(); diff -r 017e3d8526e0 -r e064e781d255 flys-artifacts/src/main/resources/messages.properties --- a/flys-artifacts/src/main/resources/messages.properties Thu Oct 04 11:25:27 2012 +0200 +++ b/flys-artifacts/src/main/resources/messages.properties Thu Oct 04 11:27:06 2012 +0200 @@ -97,6 +97,7 @@ state.chart.river = River state.chart.type = Charttype +state.chart.km = Kilometer chart.new.durationcurve = Duration Curve chart.new.computeddischargecurve = Discharge Curve diff -r 017e3d8526e0 -r e064e781d255 flys-artifacts/src/main/resources/messages_de.properties --- a/flys-artifacts/src/main/resources/messages_de.properties Thu Oct 04 11:25:27 2012 +0200 +++ b/flys-artifacts/src/main/resources/messages_de.properties Thu Oct 04 11:27:06 2012 +0200 @@ -97,6 +97,7 @@ state.chart.river = Gew\u00e4sser state.chart.type = Diagrammtyp +state.chart.km = Kilometer chart.new.durationcurve = Dauerlinie chart.new.computeddischargecurve = Abflusskurve diff -r 017e3d8526e0 -r e064e781d255 flys-artifacts/src/main/resources/messages_de_DE.properties --- a/flys-artifacts/src/main/resources/messages_de_DE.properties Thu Oct 04 11:25:27 2012 +0200 +++ b/flys-artifacts/src/main/resources/messages_de_DE.properties Thu Oct 04 11:27:06 2012 +0200 @@ -97,6 +97,7 @@ state.chart.river = Gew\u00e4sser state.chart.type = Diagrammtyp +state.chart.km = Kilometer chart.new.durationcurve = Dauerlinie chart.new.computeddischargecurve = Abflusskurve diff -r 017e3d8526e0 -r e064e781d255 flys-artifacts/src/main/resources/messages_en.properties --- a/flys-artifacts/src/main/resources/messages_en.properties Thu Oct 04 11:25:27 2012 +0200 +++ b/flys-artifacts/src/main/resources/messages_en.properties Thu Oct 04 11:27:06 2012 +0200 @@ -97,6 +97,7 @@ state.chart.river = River state.chart.type = Charttype +state.chart.km = Kilometer chart.new.durationcurve = Duration Curve chart.new.computeddischargecurve = Discharge Curve