A grid. More...


Public Member Functions | |
| Grid (Axis axis) | |
| Constructor. | |
| Color | getForeground () |
| Gets the foreground color. | |
| void | setForeground (Color color) |
| Sets the foreground color. | |
| LineStyle | getStyle () |
| Gets the line style. | |
| void | setStyle (LineStyle style) |
Protected Member Functions | |
| void | draw (GC gc, int width, int height) |
| Draws grid. | |
Private Attributes | |
| Axis | axis |
| the axis | |
| Color | color |
| the grid color | |
| boolean | isVisible |
| the visibility state | |
| LineStyle | lineStyle |
| the line style | |
Static Private Attributes | |
| static final int | LINE_WIDTH = 1 |
| the line width | |
| static final LineStyle | DEFAULT_STYLE = LineStyle.DOT |
| the default style | |
| static final int | DEFAULT_FOREGROUND = SWT.COLOR_GRAY |
| the default color | |
A grid.
Definition at line 22 of file Grid.java.
| org.swtchart.internal.Grid.Grid | ( | Axis | axis | ) |
Constructor.
Definition at line 51 of file Grid.java.
References org.swtchart.internal.Grid.color, org.swtchart.internal.Grid.DEFAULT_FOREGROUND, org.swtchart.internal.Grid.DEFAULT_STYLE, org.swtchart.internal.Grid.isVisible, and org.swtchart.internal.Grid.lineStyle.
| void org.swtchart.internal.Grid.draw | ( | GC | gc, | |
| int | width, | |||
| int | height | |||
| ) | [protected] |
Draws grid.
| gc | the graphics context | |
| width | the width to draw grid | |
| height | the height to draw grid |
Definition at line 113 of file Grid.java.
References org.swtchart.internal.Grid.axis, org.swtchart.internal.Grid.getForeground(), org.swtchart.internal.axis.Axis.getTick(), org.swtchart.internal.axis.Axis.isHorizontalAxis, org.swtchart.internal.axis.Axis.isValidCategoryAxis(), org.swtchart.internal.Grid.isVisible, org.swtchart.internal.Grid.LINE_WIDTH, and org.swtchart.internal.Grid.lineStyle.

| Color org.swtchart.internal.Grid.getForeground | ( | ) |
Gets the foreground color.
Implements org.swtchart.IGrid.
Definition at line 62 of file Grid.java.
References org.swtchart.internal.Grid.color, and org.swtchart.internal.Grid.DEFAULT_FOREGROUND.
Referenced by org.swtchart.internal.Grid.draw().

| LineStyle org.swtchart.internal.Grid.getStyle | ( | ) |
Gets the line style.
Implements org.swtchart.IGrid.
Definition at line 88 of file Grid.java.
References org.swtchart.internal.Grid.lineStyle.
| void org.swtchart.internal.Grid.setForeground | ( | Color | color | ) |
Sets the foreground color.
| color | the foreground color |
Implements org.swtchart.IGrid.
Definition at line 72 of file Grid.java.
References org.swtchart.internal.Grid.DEFAULT_FOREGROUND.
| void org.swtchart.internal.Grid.setStyle | ( | LineStyle | style | ) |
Definition at line 95 of file Grid.java.
References org.swtchart.internal.Grid.DEFAULT_STYLE, and org.swtchart.internal.Grid.lineStyle.
Axis org.swtchart.internal.Grid.axis [private] |
Color org.swtchart.internal.Grid.color [private] |
the grid color
Definition at line 28 of file Grid.java.
Referenced by org.swtchart.internal.Grid.getForeground(), and org.swtchart.internal.Grid.Grid().
final int org.swtchart.internal.Grid.DEFAULT_FOREGROUND = SWT.COLOR_GRAY [static, private] |
the default color
Definition at line 43 of file Grid.java.
Referenced by org.swtchart.internal.Grid.getForeground(), org.swtchart.internal.Grid.Grid(), and org.swtchart.internal.Grid.setForeground().
final LineStyle org.swtchart.internal.Grid.DEFAULT_STYLE = LineStyle.DOT [static, private] |
the default style
Definition at line 40 of file Grid.java.
Referenced by org.swtchart.internal.Grid.Grid(), and org.swtchart.internal.Grid.setStyle().
boolean org.swtchart.internal.Grid.isVisible [private] |
the visibility state
Definition at line 31 of file Grid.java.
Referenced by org.swtchart.internal.Grid.draw(), and org.swtchart.internal.Grid.Grid().
final int org.swtchart.internal.Grid.LINE_WIDTH = 1 [static, private] |
the line width
Definition at line 37 of file Grid.java.
Referenced by org.swtchart.internal.Grid.draw().
the line style
Definition at line 34 of file Grid.java.
Referenced by org.swtchart.internal.Grid.draw(), org.swtchart.internal.Grid.getStyle(), org.swtchart.internal.Grid.Grid(), and org.swtchart.internal.Grid.setStyle().
1.6.1