Mercurial > dive4elements > river
comparison artifacts/src/main/java/org/dive4elements/river/exports/DurationCurveGenerator.java @ 8248:2b0ff11cef3f
Fix duration curve i18n.
author | Tom Gottfried <tom@intevation.de> |
---|---|
date | Tue, 09 Sep 2014 18:41:11 +0200 |
parents | e4606eae8ea5 |
children | 27d42c9ee367 |
comparison
equal
deleted
inserted
replaced
8247:b8f343230eab | 8248:2b0ff11cef3f |
---|---|
56 "chart.duration.curve.subtitle"; | 56 "chart.duration.curve.subtitle"; |
57 | 57 |
58 public static final String I18N_XAXIS_LABEL = | 58 public static final String I18N_XAXIS_LABEL = |
59 "chart.duration.curve.xaxis.label"; | 59 "chart.duration.curve.xaxis.label"; |
60 | 60 |
61 public static final String I18N_YAXIS_LABEL = | 61 public static final String I18N_YAXIS_LABEL_W = |
62 "chart.duration.curve.yaxis.label"; | 62 "chart.duration.curve.yaxis.label.w"; |
63 | |
64 public static final String I18N_YAXIS_LABEL_Q = | |
65 "chart.duration.curve.yaxis.label.q"; | |
63 | 66 |
64 public static final String I18N_CHART_TITLE_DEFAULT = | 67 public static final String I18N_CHART_TITLE_DEFAULT = |
65 "Dauerlinie"; | 68 "Dauerlinie"; |
66 | 69 |
67 public static final String I18N_XAXIS_LABEL_DEFAULT = | 70 public static final String I18N_XAXIS_LABEL_DEFAULT = |
68 "Unterschreitungsdauer [Tage]"; | 71 "Unterschreitungsdauer [Tage]"; |
69 | |
70 public static final String I18N_YAXIS_LABEL_DEFAULT = | |
71 "W [NN + m]"; | |
72 | 72 |
73 | 73 |
74 public DurationCurveGenerator() { | 74 public DurationCurveGenerator() { |
75 super(); | 75 super(); |
76 } | 76 } |
121 | 121 |
122 @Override | 122 @Override |
123 protected String getDefaultYAxisLabel(int index) { | 123 protected String getDefaultYAxisLabel(int index) { |
124 String label = "default"; | 124 String label = "default"; |
125 if (index == YAXIS.W.idx) { | 125 if (index == YAXIS.W.idx) { |
126 label = msg(I18N_YAXIS_LABEL, I18N_YAXIS_LABEL_DEFAULT); | 126 label = msg(I18N_YAXIS_LABEL_W, new Object[] { getRiverUnit() }); |
127 } | 127 } |
128 else if (index == YAXIS.Q.idx) { | 128 else if (index == YAXIS.Q.idx) { |
129 // TODO i18n for this label | 129 label = msg(I18N_YAXIS_LABEL_Q); |
130 label = "Q [m\u00b3/s]"; | |
131 //label = msg(get2YAxisLabelKey(), get2YAxisDefaultLabel()); | |
132 } | 130 } |
133 | 131 |
134 return label; | 132 return label; |
135 } | 133 } |
136 | 134 |