private bool CanRotate(double angle) { double cos = Math.Cos(angle); double sin = Math.Sin(angle); return(CanChangePosition(p => FiguresUtils.RotatePoint(p - Center, cos, sin) + Center)); }
public virtual void RotateAroundOf(Point rotationsCenter, double angle) { double cos = Math.Cos(angle); double sin = Math.Sin(angle); for (int i = 0; i < _definingPoints.Count; i++) { _definingPoints[i] = FiguresUtils.RotatePoint(_definingPoints[i] - rotationsCenter, cos, sin) + rotationsCenter; } OnUpdate(); }