This method draws a rectangle.
Parameters
rect
The Rectangle structure designating where the rectangle is drawn.
Return Value
Returns True if successful, otherwise returns False.
Explanation
The DrawRectangle method draws a rectangle. To draw a rectangle, set appropriate values in the PenWidth, ForeColor, BackColor, and Fill properties. Set the values for the coordinate location and size of the rectangle in the DrawRectangle method's rect parameter. When the DrawRectangle method is executed, the rectangle will be drawn. If a portion of the rectangle lies outside the ImageKit control, the rectangle will be resized to fit completely within the ImageKit control.
To delete the rectangle drawn with the DrawRectangle method, right click the object and display the context menu, the select "Undo" or execute the Undo method.
The DrawRectangle method can be used without setting the EditKind property to KindOfEdit.Rectangle.
It is also possible to draw a rectangle by setting the EditKind property to KindOfEdit.Rectangle then, on the base image displayed in the ImageKit control, use the mouse. For more details, please refer to the Edit Overview.
See also
ImageKit.Edit Members | Newtone.ImageKit.Win.ImageKit