Contains()

Rectangle::Contains(int, int) const method

Determines if the specified point is located within the rectangle represented by the current object.

bool System::Drawing::Rectangle::Contains(int x, int y) const

Arguments

ParameterTypeDescription
xintThe X coordinate of the point to check
yintThe Y coordinate of the point to check

Return Value

True if the specified point is located within the rectangle represented by the current object, otherwise - false

Rectangle::Contains(const Point&) const method

Determines if the specified point is located within the rectangle represented by the current object.

bool System::Drawing::Rectangle::Contains(const Point &point) const

Arguments

ParameterTypeDescription
pointconst Point&A point to check

Return Value

True if the specified point is located within the rectangle represented by the current object, otherwise - false

Rectangle::Contains(const Rectangle&) const method

Determines if the specified rectangle is located within the rectangle represented by the current object.

bool System::Drawing::Rectangle::Contains(const Rectangle &rect) const

Arguments

ParameterTypeDescription
rectconst Rectangle&A rectangle to check

Return Value

True if the specified rectangle is located within the rectangle represented by the current object, otherwise - false

See Also