Last change
on this file since 2449 was
1964,
checked in by mstoeger, 15 years ago
|
moved the canvas and the basic types of shapes to their own namespace. #498
|
File size:
950 bytes
|
Line | |
---|
1 | using System.Drawing;
|
---|
2 | using HeuristicLab.Visualization.Drawing;
|
---|
3 |
|
---|
4 | namespace HeuristicLab.Visualization {
|
---|
5 | public class XAxisGrid : WorldShape {
|
---|
6 | private Color color = Color.LightBlue;
|
---|
7 |
|
---|
8 | public override void Draw(Graphics graphics) {
|
---|
9 | ClearShapes();
|
---|
10 |
|
---|
11 | foreach (double x in AxisTicks.GetTicks(XAxis.PixelsPerInterval,
|
---|
12 | Parent.Viewport.Width,
|
---|
13 | ClippingArea.Width,
|
---|
14 | ClippingArea.X1)) {
|
---|
15 | LineShape line = new LineShape(x, ClippingArea.Y1,
|
---|
16 | x, ClippingArea.Y2,
|
---|
17 | color, 1,
|
---|
18 | DrawingStyle.Dashed);
|
---|
19 | AddShape(line);
|
---|
20 | }
|
---|
21 |
|
---|
22 | base.Draw(graphics);
|
---|
23 | }
|
---|
24 |
|
---|
25 | public Color Color {
|
---|
26 | get { return color; }
|
---|
27 | set { color = value; }
|
---|
28 | }
|
---|
29 | }
|
---|
30 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.