Mercurial > dive4elements > river
comparison artifacts/src/main/java/org/dive4elements/river/jfree/StyledDomainMarker.java @ 6908:819481cc9195
Artifacts: ThemeDocument. The bloody part: Removal of the XPaths. Now the theme XML document is scanned once(!) at construction time for field values and the resulting key/value pairs are store in a map.
author | Sascha L. Teichmann <teichmann@intevation.de> |
---|---|
date | Fri, 23 Aug 2013 11:07:11 +0200 |
parents | 1b35b2ddfc28 |
children |
comparison
equal
deleted
inserted
replaced
6907:dbad1f442f3e | 6908:819481cc9195 |
---|---|
26 private final Color backgroundColor, backgroundColor2; | 26 private final Color backgroundColor, backgroundColor2; |
27 | 27 |
28 public StyledDomainMarker(double start, double end, ThemeDocument theme) { | 28 public StyledDomainMarker(double start, double end, ThemeDocument theme) { |
29 super(start, end); | 29 super(start, end); |
30 | 30 |
31 backgroundColor = ThemeDocument.parseColor( | 31 backgroundColor = theme.parseAreaBackgroundColor(); |
32 theme.getAreaBackgroundColorString()); | |
33 backgroundColor2 = new Color( | 32 backgroundColor2 = new Color( |
34 255 - backgroundColor.getRed(), | 33 255 - backgroundColor.getRed(), |
35 255 - backgroundColor.getGreen(), | 34 255 - backgroundColor.getGreen(), |
36 255 - backgroundColor.getBlue()); | 35 255 - backgroundColor.getBlue()); |
37 useSecondColor(false); | 36 useSecondColor(false); |
38 | 37 |
39 int alpha = 100 - ThemeDocument.parseInteger( | 38 int alpha = 100 - theme.parseAreaTransparency(50); |
40 theme.getAreaTransparencyString(), 50); | |
41 setAlpha(alpha / 100.0f); | 39 setAlpha(alpha / 100.0f); |
42 } | 40 } |
43 | 41 |
44 /** | 42 /** |
45 * To properly differentiate several styled domain markers side by side, | 43 * To properly differentiate several styled domain markers side by side, |