public void Reflect(ReflectOrientation orientation) { SceneRectangle circumscribingRectangle = CalculateCircumscribingRectangle(); var pointSceneCenter = new ScenePoint { X = (circumscribingRectangle.Vertex1.X + circumscribingRectangle.Vertex2.X) / 2.0, Y = (circumscribingRectangle.Vertex1.Y + circumscribingRectangle.Vertex2.Y) / 2.0 }; foreach (var figure in _childFigures) { var points = figure.Points; GeneralMethodsFigure.ReflectFigure(orientation, pointSceneCenter, ref points); figure.Points = points; } }
public void Move(ScenePoint vector) { GeneralMethodsFigure.Move(vector, ref _points); _center = _points[0]; }
public void Reflect(ReflectOrientation orientation) { GeneralMethodsFigure.ReflectFigure(orientation, CenterFigure(), ref _points); }
public void Rotate(double angle) { GeneralMethodsFigure.RotateFigure(angle, CenterFigure(), ref _points); }
/* Move all the points of current rectangle. */ public void Move(ScenePoint vector) { GeneralMethodsFigure.Move(vector, ref _points); SetP(_points); }