Functions

Rect(x, y, w, h) Constructor
within(r, x, y) Check if a point is within a rectangle

Functions

Rect(x, y, w, h)

Constructor

Parameters:

x x-coordinate
y y-coordinate
w Width
h Height
within(r, x, y)

Check if a point is within a rectangle

Parameters:

r The rectangle
x x-coodinate
y y-coodinate

Return:

  • True/False result