xtd 0.2.0
Loading...
Searching...
No Matches

◆ inflate() [3/4]

static rectangle_f xtd::drawing::rectangle_f::inflate ( const rectangle_f rect,
const drawing::size_f sz 
)
staticnoexcept

Creates and returns an enlarged copy of the specified xtd::drawing::rectangle_f structure. The copy is enlarged by the specified amount. The original xtd::drawing::rectangle_f structure remains unmodified.

Parameters
rectThe xtd::drawing::rectangle_f with which to start. This rectangle is not modified.
xThe amount to inflate the specified rectangle horizontally.
yThe amount to inflate the specified rectangle vertically.
Returns
The enlarged xtd::drawing::rectangle_f.
Remarks
This method makes a copy of rect, enlarges the copy, and then returns the enlarged copy. The rectangle is enlarged in both directions along an axis. For example, if a 50 by 50 rectangle is enlarged by 50 in the x-axis, the resultant rectangle will be 150 units long (the original 50, the 50 in the minus direction, and the 50 in the plus direction) maintaining the rectangle's geometric center.