Free cookie consent management tool by TermsFeed Policy Generator

source: trunk/sources/HeuristicLab.Visualization/HorizontalLineShape.cs @ 1352

Last change on this file since 1352 was 1242, checked in by dwagner, 16 years ago

Changed Behaviour of Single value lines; They are now shown without bounds.
OptionsDialog now modifies the model and not the view; (#501 and #502)

File size: 1.1 KB
Line 
1using System.Drawing;
2
3namespace HeuristicLab.Visualization {
4  public class HorizontalLineShape : LineShape {
5    /// <summary>
6    /// Initializes the LineShape.
7    /// </summary>
8    /// <param name="x1">x coordinate of left lineEndPoind</param>
9    /// <param name="y1">y coordinate of left lineEndPoind</param>
10    /// <param name="x2">x coordinate of right lineEndPoind</param>
11    /// <param name="y2">y coordinate of right lineEndPoind</param>
12    /// <param name="color">color for the LineShape</param>
13    /// <param name="thickness">tickness of the line in pixels</param>
14    /// <param name="drawingStyle">drawing style of the line (solid, dashed, dotted,...)</param>
15    public HorizontalLineShape(double x1, double y1, double x2, double y2, Color color, int thickness,
16                               DrawingStyle drawingStyle) : base(x1, y1, x2, y2, color, thickness, drawingStyle) {}
17
18    public override void Draw(Graphics graphics) {
19      X1 = Parent.ClippingArea.X1;
20      X2 = Parent.ClippingArea.X2;
21      Y2 = Y1;
22      base.Draw(graphics);
23    }
24  }
25}
Note: See TracBrowser for help on using the repository browser.