DisplaySegment.cs 1.2 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. 
  2. using System;
  3. using System.Drawing;
  4. namespace OTSIncAReportGraph
  5. {
  6. /// <summary>
  7. /// 基本线类
  8. /// </summary>
  9. public class DisplaySegment : ICloneable
  10. {
  11. private RectangleF m_rect;
  12. private Color m_color;
  13. /// <summary>
  14. /// 克隆基本线
  15. /// </summary>
  16. /// <returns></returns>
  17. public object Clone()
  18. {
  19. var newSeg= new DisplaySegment();
  20. newSeg.m_rect = this.m_rect;
  21. newSeg.Color = this.Color;
  22. return newSeg;
  23. }
  24. public DisplaySegment()
  25. {
  26. }
  27. /// <summary>
  28. /// 画面的大小
  29. /// </summary>
  30. public RectangleF GetShowRect()
  31. { return m_rect; }
  32. /// <summary>
  33. /// 画面的大小
  34. /// </summary>
  35. public void SetShowRect(RectangleF value)
  36. { m_rect = value; }
  37. /// <summary>
  38. /// 线的颜色
  39. /// </summary>
  40. public Color Color
  41. {
  42. get { return m_color; }
  43. set { m_color = value; }
  44. }
  45. }
  46. }