public ScreenLine(TPoint source, TPoint destination, EScreenLineElementType lineElementTypeType = EScreenLineElementType.Circle) { this.InitializeComponent(); _source = source; _destination = destination; _lineElementType = lineElementTypeType; //Bind to screenSettingsUpdate event SettingsManager.ScreenMappingSet.OnScreenSettingsUpdate += new Code.PositionMapping.ScreenMappingSettings.ScreenSettingsUpdateHandler(ScreenMappingSet_OnScreenSettingsUpdate); CalculateLine(); }
public ScreenLine(TPoint source, Vector LineVector, EScreenLineElementType lineElementTypeType = EScreenLineElementType.Circle) { this.InitializeComponent(); _source = source; _lineElementType = lineElementTypeType; _destination = new TPoint( Convert.ToInt32(_source.ScreenX + LineVector.X), Convert.ToInt32(_source.ScreenY + LineVector.Y), TPoint.PointCreationType.screen ); //Bind to screenSettingsUpdate event SettingsManager.ScreenMappingSet.OnScreenSettingsUpdate += new Code.PositionMapping.ScreenMappingSettings.ScreenSettingsUpdateHandler(ScreenMappingSet_OnScreenSettingsUpdate); CalculateLine(); }