MakeRect
Rect MakeRect (int top, int left, int height, int width);
Purpose
Returns a Rect structure with the values you specify. The Rect structure defines the location and size of a rectangle.
This function is useful when you call canvas control functions that require Rect structures as input parameters. You can embed a call to MakeRect in calls to these functions, eliminating the need to declare a Rect variable.
Parameters
Input | ||
Name | Type | Description |
top | int | Location of the top edge of the rectangle. |
left | int | Location of the left edge of the rectangle. |
height | int | Height of the rectangle. |
width | int | Width of the rectangle. |
Return Value
Name | Type | Description |
newRectangle | Rect | Rect structure containing the coordinate values you specify. |
Additional Information
Library: User Interface Library
Include file: userint.h
LabWindows/CVI compatibility: LabWindows/CVI 4.0 and later
Example
Refer to userint\clipbord.cws for an example of using the MakeRect function.