implement Rectnagle.Translate(double, double)

This commit is contained in:
Michael Becker 2022-04-13 00:42:25 -04:00
parent e026d576ad
commit ff282ad8ef
No known key found for this signature in database
GPG Key ID: DA394832305DA332

View File

@ -68,6 +68,11 @@ namespace MBS.Framework.Drawing
public double Right { get { return X + Width; } set { Width = value - X; } }
public double Bottom { get { return Y + Height; } set { Height = value - Y; } }
public Rectangle Translate(double x, int y)
{
return new Rectangle(X + x, Y + y, Width, Height);
}
public Rectangle Deflate(Padding padding)
{
Rectangle rect = this;