Mercurial > dive4elements > river
comparison flys-artifacts/src/main/java/de/intevation/flys/jfree/EnhancedLineAndShapeRenderer.java @ 2659:4d8959a4b49d
Actually use font specified in theme document for linelabel.
flys-artifacts/trunk@4333 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Felix Wolfsteller <felix.wolfsteller@intevation.de> |
---|---|
date | Wed, 02 May 2012 19:54:58 +0000 |
parents | f1dcd5f94ffa |
children | 1a044c51abe4 |
comparison
equal
deleted
inserted
replaced
2658:08b7e8edda41 | 2659:4d8959a4b49d |
---|---|
250 XYSeries xYSeries = ((XYSeriesCollection) dataset).getSeries(series); | 250 XYSeries xYSeries = ((XYSeriesCollection) dataset).getSeries(series); |
251 String waterlevelLabel = (xYSeries instanceof HasLabel) | 251 String waterlevelLabel = (xYSeries instanceof HasLabel) |
252 ? ((HasLabel)xYSeries).getLabel() | 252 ? ((HasLabel)xYSeries).getLabel() |
253 : xYSeries.getKey().toString(); | 253 : xYSeries.getKey().toString(); |
254 // TODO Force water of some German rivers to flow direction mountains. | 254 // TODO Force water of some German rivers to flow direction mountains. |
255 Font oldFont = g2.getFont(); | |
256 g2.setFont(this.getLineLabelFont(series)); | |
257 // TODO set color | |
255 g2.drawString(waterlevelLabel, (float)xx, (float)yy-3f); | 258 g2.drawString(waterlevelLabel, (float)xx, (float)yy-3f); |
259 g2.setFont(oldFont); | |
256 } | 260 } |
257 | 261 |
258 int domainAxisIndex = plot.getDomainAxisIndex(domainAxis); | 262 int domainAxisIndex = plot.getDomainAxisIndex(domainAxis); |
259 int rangeAxisIndex = plot.getRangeAxisIndex(rangeAxis); | 263 int rangeAxisIndex = plot.getRangeAxisIndex(rangeAxis); |
260 updateCrosshairValues(crosshairState, x1, y1, domainAxisIndex, | 264 updateCrosshairValues(crosshairState, x1, y1, domainAxisIndex, |