public override void DrawYourself(DrawingContext context, CoordinateConverter converter, RelevantObjectPreferences preferences, Pen pen) { var cPos = converter.ToDpi(converter.EditorToRelativeCoordinate(Child.Centre)); var radius = converter.ToDpi(converter.ScaleByRatio(new Vector2(Child.Radius))); context.DrawEllipse(null, pen, new Point(cPos.X, cPos.Y), radius.X, radius.Y); }
public override void DrawYourself(DrawingContext context, CoordinateConverter converter, RelevantObjectPreferences preferences, Pen pen) { var cPos = converter.ToDpi(converter.EditorToRelativeCoordinate(Child)); context.DrawEllipse(null, pen, new Point(cPos.X, cPos.Y), preferences.Size, preferences.Size); }
public override void DrawYourself(DrawingContext context, CoordinateConverter converter, RelevantObjectPreferences preferences, Pen pen) { if (!Line2.Intersection(new Box2 { Left = -1000, Top = -1000, Right = 1512, Bottom = 1384 }, Child, out var points)) { return; } var cPos1 = converter.ToDpi(converter.EditorToRelativeCoordinate(points[0])); var cPos2 = converter.ToDpi(converter.EditorToRelativeCoordinate(points[1])); context.DrawLine(pen, new Point(cPos1.X, cPos1.Y), new Point(cPos2.X, cPos2.Y)); }