Purpose
Creates a rounded rectangle object. You can issue this statement from the MapBasic window in MapInfo Pro.
Syntax
Create RoundRect
[ Into { Window window_id | Variable var_name } ]
( x1, y1 ) ( x2, y2 ) rounding
[ Pen ... ]
[ Brush ... ] [ Priority n ] [ Name framename ]
window_id is a window identifier.
var_name is the name of an existing object variable.
x1, y1 specifies one corner of the rounded rectangle.
x2, y2 specifies the opposite corner of the rectangle.
rounding is a float value, in coordinate units (for example, inches on a Layout or degrees on a Map), specifying the diameter of the circle which fills the rounded rectangle's corner.
Pen is a valid Pen clause to specify a line style.
Brush is a valid Brush clause to specify fill style.
n is an integer value indicating the Z-Order value of objects (frames) on the Layout window.
framename is a string representing the name for this item in a Layout window.
Description
The Create RoundRect statement creates a rounded rectangle object (a rectangle with rounded corners).
The x and y parameters use whatever coordinate system MapBasic is currently using. By default, MapBasic uses a Longitude/Latitude coordinate system, although the Set CoordSys statement can re-configure MapBasic to use a different coordinate system. Note that MapBasic's coordinate system is independent of the coordinate system of any Map window. Objects created on a Layout window, however, are specified in paper units: each x-coordinate represents a distance from the left edge of the page, while each y-coordinate represents the distance from the top edge of the page. For details about paper units, see Set Paper Units statement. By default, MapBasic uses inches as the default paper unit. To use a different paper unit, call the Set Paper Units statement.
The optional Pen clause specifies a line style used to draw the outline of the object; see Pen clause for more details. If no Pen clause is specified, the Create RoundRect statement uses the current line style (the style which appears in the Line Style dialog box). Similarly, the optional Brush clause specifies a fill style; see Brush clause for more details.
When creating a clone statement or saving a workspace, MapInfo Pro normalizes the priority of frames to a unique set of values beginning with one (1). Use the Priority clause to assign the Z-Order of the newly created object frame on the Layout window.
The Name clause assigns a name to a frame in the Layout window. If a name is assigned, it is written to the workspace (WOR) file and the workspace version updates to 1500.
See Also:
Brush clause, Create Rect statement, Insert statement, Pen clause, Update statement