Mercurial > dive4elements > gnv-client
comparison gnv-artifacts/src/main/java/de/intevation/gnv/chart/ChartStyle.java @ 127:f6f0e4ce4a35
merged gnv-artifacts/0.1
author | Thomas Arendsen Hein <thomas@intevation.de> |
---|---|
date | Fri, 28 Sep 2012 12:13:41 +0200 |
parents | 8b75d01fa5b5 |
children | 7fb9441dd8af |
comparison
equal
deleted
inserted
replaced
49:94a07d1d9316 | 127:f6f0e4ce4a35 |
---|---|
1 /* Copyright (C) 2007 con terra GmbH (http://www.conterra.de) | |
2 * All rights reserved | |
3 * | |
4 * $Id: ChartStyle.java,v 1.2 2007/12/21 12:31:15 blume Exp $ | |
5 * | |
6 * created by: drewnak | |
7 * created at : 10.12.2007 | |
8 * created at : 13:07:44 | |
9 * | |
10 * modified by: $Author: blume $ | |
11 * modified at: $Date: 2007/12/21 12:31:15 $ | |
12 */ | |
13 package de.intevation.gnv.chart; | |
14 | |
15 import java.awt.Color; | |
16 import java.awt.Dimension; | |
17 | |
18 /** | |
19 * @author drewnak | |
20 */ | |
21 public class ChartStyle { | |
22 | |
23 private Color mCanvasColor; | |
24 private Color mPlotBackgroundColor; | |
25 private Color mDomainGridlineColor; | |
26 private Color mRangeGridlineColor; | |
27 private boolean mDomainCrosshairVisible; | |
28 private boolean mRangeCrosshairVisible; | |
29 private Insets mAxisOffset; | |
30 private boolean mOverrideDefaultChartWidth = false; | |
31 private Dimension mChartSize; | |
32 | |
33 private boolean mUseUpperDataLevel = false; | |
34 private boolean mUseLowerDataLevel = false; | |
35 private int mUpperLevel; | |
36 private int mLowerLevel; | |
37 | |
38 /** | |
39 * @param pCanvasColor | |
40 * @param pPlotBackgroundColor | |
41 * @param pDomainGridlineColor | |
42 * @param pRangeGridlineColor | |
43 * @param pDomainCrosshairVisible | |
44 * @param pRangeCrosshairVisible | |
45 * @param pAxisOffset | |
46 */ | |
47 public ChartStyle(Color pCanvasColor, Color pPlotBackgroundColor, Color pDomainGridlineColor, | |
48 Color pRangeGridlineColor, boolean pDomainCrosshairVisible, boolean pRangeCrosshairVisible, | |
49 Insets pAxisOffset, Dimension pChartSize) { | |
50 super(); | |
51 mCanvasColor = pCanvasColor; | |
52 mPlotBackgroundColor = pPlotBackgroundColor; | |
53 mDomainGridlineColor = pDomainGridlineColor; | |
54 mRangeGridlineColor = pRangeGridlineColor; | |
55 mDomainCrosshairVisible = pDomainCrosshairVisible; | |
56 mRangeCrosshairVisible = pRangeCrosshairVisible; | |
57 mAxisOffset = pAxisOffset; | |
58 mChartSize = pChartSize; | |
59 } | |
60 | |
61 public Color getCanvasColor() { | |
62 return mCanvasColor; | |
63 } | |
64 | |
65 public void setCanvasColor(Color pCanvasColor) { | |
66 mCanvasColor = pCanvasColor; | |
67 } | |
68 | |
69 public Color getDomainGridlineColor() { | |
70 return mDomainGridlineColor; | |
71 } | |
72 | |
73 public void setDomainGridlineColor(Color pDomainGridlineColor) { | |
74 mDomainGridlineColor = pDomainGridlineColor; | |
75 } | |
76 | |
77 public Color getRangeGridlineColor() { | |
78 return mRangeGridlineColor; | |
79 } | |
80 | |
81 public void setRangeGridlineColor(Color pRangeGridlineColor) { | |
82 mRangeGridlineColor = pRangeGridlineColor; | |
83 } | |
84 | |
85 public boolean isDomainCrosshairVisible() { | |
86 return mDomainCrosshairVisible; | |
87 } | |
88 | |
89 public void setDomainCrosshairVisible(boolean pDomainCrosshairVisible) { | |
90 mDomainCrosshairVisible = pDomainCrosshairVisible; | |
91 } | |
92 | |
93 public boolean isRangeCrosshairVisible() { | |
94 return mRangeCrosshairVisible; | |
95 } | |
96 | |
97 public void setRangeCrosshairVisible(boolean pRangeCrosshairVisible) { | |
98 mRangeCrosshairVisible = pRangeCrosshairVisible; | |
99 } | |
100 | |
101 public Insets getAxisOffset() { | |
102 return mAxisOffset; | |
103 } | |
104 | |
105 public void setAxisOffset(Insets pAxisOffset) { | |
106 mAxisOffset = pAxisOffset; | |
107 } | |
108 | |
109 public Color getPlotBackgroundColor() { | |
110 return mPlotBackgroundColor; | |
111 } | |
112 | |
113 public void setPlotBackgroundColor(Color pPlotBackgroundColor) { | |
114 mPlotBackgroundColor = pPlotBackgroundColor; | |
115 } | |
116 | |
117 public Dimension getChartSize() { | |
118 return mChartSize; | |
119 } | |
120 | |
121 public void setChartSize(Dimension pChartSize) { | |
122 mChartSize = pChartSize; | |
123 } | |
124 | |
125 public boolean isOverrideDefaultChartWidth() { | |
126 return mOverrideDefaultChartWidth; | |
127 } | |
128 | |
129 public void setOverrideDefaultChartWidth(boolean pOverrideDefaultChartWidth) { | |
130 mOverrideDefaultChartWidth = pOverrideDefaultChartWidth; | |
131 } | |
132 | |
133 | |
134 public void setNewChartWidth(int pNewChartWidth) { | |
135 mChartSize.setSize(pNewChartWidth, mChartSize.getHeight()); | |
136 } | |
137 | |
138 public boolean isUseUpperDataLevel() { | |
139 return mUseUpperDataLevel; | |
140 } | |
141 | |
142 public void setUseUpperDataLevel(boolean pUseUpperDataLevel) { | |
143 mUseUpperDataLevel = pUseUpperDataLevel; | |
144 } | |
145 | |
146 public boolean isUseLowerDataLevel() { | |
147 return mUseLowerDataLevel; | |
148 } | |
149 | |
150 public void setUseLowerDataLevel(boolean pUseLowerDataLevel) { | |
151 mUseLowerDataLevel = pUseLowerDataLevel; | |
152 } | |
153 | |
154 public int getUpperLevel() { | |
155 return mUpperLevel; | |
156 } | |
157 | |
158 public void setUpperLevel(int pUpperLevel) { | |
159 mUpperLevel = pUpperLevel; | |
160 } | |
161 | |
162 public int getLowerLevel() { | |
163 return mLowerLevel; | |
164 } | |
165 | |
166 public void setLowerLevel(int pLowerLevel) { | |
167 mLowerLevel = pLowerLevel; | |
168 } | |
169 } |