Method Scale
- Namespace
- OpenCAD2D
- Assembly
- OpenCAD2D.Core.dll
Scale<T>(IEnumerable<T>, GeoPoint2, double)
Scales objects about a base point, as SCALE does: a circle of radius 10 about (200, 0) scaled about (0, 0) by 2 is one of radius 20 about (400, 0), and a text 5 high is 10 high. One undo step named SCALE.
public IReadOnlyList<T> Scale<T>(IEnumerable<T> entities, GeoPoint2 basePoint, double factor) where T : DxfEntity
Parameters
entitiesIEnumerable<T>The drawing's objects to scale.
basePointGeoPoint2The point that stays where it is, in the world.
factordoubleThe factor, above nought.
Returns
- IReadOnlyList<T>
The objects given, scaled where they stand, in the order given.
Type Parameters
TThe type of the objects given.
Exceptions
- ArgumentNullException
Thrown when the list is null.
- ArgumentException
Thrown when an object of the list is null, or the base point is not finite.
- ArgumentOutOfRangeException
Thrown when the factor is not a finite number above nought.
- InvalidOperationException
Thrown when an object is refused, as the remarks say.