public override void Draw(Graphics gr) { Pen pen = (Pen)BorderPen.Clone(); if (ShowConnectorAsSelected || Selected) { pen.Color = pen.Color.ToArgb() == Color.Red.ToArgb() ? Color.Blue : Color.Red; } gr.DrawLine(pen, StartPoint, EndPoint); pen.Dispose(); base.Draw(gr); }
public override void Draw(Graphics gr) { Pen pen = (Pen)BorderPen.Clone(); if (ShowLineAsSelected) { pen.Color = pen.Color.ToArgb() == Color.Red.ToArgb() ? Color.Blue : Color.Red; } gr.DrawLine(pen, DisplayRectangle.LeftMiddle(), DisplayRectangle.RightMiddle()); pen.Dispose(); base.Draw(gr); }
public override void Draw(Graphics gr, bool showSelection = true) { Pen pen = (Pen)BorderPen.Clone(); if ((ShowConnectorAsSelected || Selected) && showSelection) { pen.Color = pen.Color.ToArgb() == Color.Red.ToArgb() ? Color.Blue : Color.Red; } gr.DrawLine(pen, ZoomStartPoint, ZoomEndPoint); pen.Dispose(); base.Draw(gr, showSelection); }
public override void Draw(Graphics gr, bool showSelection = true) { Pen pen = (Pen)BorderPen.Clone(); if (ShowConnectorAsSelected && showSelection) { pen.Color = pen.Color.ToArgb() == Color.Red.ToArgb() ? Color.Blue : Color.Red; } gr.DrawLine(pen, ZoomRectangle.LeftMiddle(), ZoomRectangle.RightMiddle()); pen.Dispose(); base.Draw(gr, showSelection); }