Method Deflate
Deflate(double)
Returns a new rectangle contracted equally on all sides.
public Rectangle Deflate(double uniform)
Parameters
uniformdoubleThe amount to remove from each side (left, top, right, bottom).
Returns
Exceptions
- ArgumentException
Thrown when the deflation would invert the rectangle (negative width or height).
Deflate(double, double)
Returns a new rectangle contracted by the specified amounts on each axis.
public Rectangle Deflate(double dx, double dy)
Parameters
dxdoubleThe horizontal amount to remove on each side (left and right).
dydoubleThe vertical amount to remove on each side (top and bottom).
Returns
Exceptions
- ArgumentException
Thrown when the deflation would invert the rectangle (negative width or height).