recrownedgtk/RecrownedGTK/Types/Rectangle.cs

24 lines
499 B
C#
Raw Normal View History

2020-02-17 02:44:21 +00:00
namespace RecrownedGTK.Types
{
public struct Rectangle
{
public int Width {set; get;}
public int Height {set; get;}
public int X {set; get;}
public int Y {set; get;}
public int Area {
get {
return Width * Height;
}
}
public Rectangle(int x, int y, int width, int height) {
Width = width;
Height = height;
X = x;
Y = y;
}
}
}