Platforms to show: All Mac Windows Linux Cross-Platform

Back to NSBezierPathMBS class.

NSBezierPathMBS.appendBezierPath(path as NSBezierPathMBS)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa Drawing MBS MacBase Plugin 12.5 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Appends the contents of the specified path object to the receiver's path.

Path: The path to add to the receiver.

This method adds the commands used to create aPath to the end of the receiver's path. This method does not explicitly try to connect the subpaths in the two objects, although the operations in Path may still cause that effect.

NSBezierPathMBS.appendBezierPathWithArc(center as NSPointMBS, radius as Double, startAngle as Double, endAngle as Double)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa Drawing MBS MacBase Plugin 12.5 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Appends an arc of a circle to the receiver's path.

center: Specifies the center point of the circle used to define the arc.
radius: Specifies the radius of the circle used to define the arc.
startAngle: Specifies the starting angle of the arc, measured in degrees counterclockwise from the x-axis.
endAngle: Specifies the end angle of the arc, measured in degrees counterclockwise from the x-axis.

The created arc lies on the perimeter of the circle, between the angles specified by the startAngle and endAngle parameters. The arc is drawn in a counterclockwise direction. If the receiver's path is empty, this method sets the current point to the beginning of the arc before adding the arc segment. If the receiver's path is not empty, a line is drawn from the current point to the starting point of the arc.

Depending on the length of the arc, this method may add multiple connected curve segments to the path.

See also:

NSBezierPathMBS.appendBezierPathWithArc(center as NSPointMBS, radius as Double, startAngle as Double, endAngle as Double, clockwise as boolean)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa Drawing MBS MacBase Plugin 12.5 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Appends an arc of a circle to the receiver's path.

center: Specifies the center point of the circle used to define the arc.
radius: Specifies the radius of the circle used to define the arc.
startAngle: Specifies the starting angle of the arc, measured in degrees counterclockwise from the x-axis.
endAngle: Specifies the end angle of the arc, measured in degrees counterclockwise from the x-axis.
clockwise: true if you want the arc to be drawn in a clockwise direction; otherwise false to draw the arc in a counterclockwise direction.

The created arc lies on the perimeter of the circle, between the angles specified by the startAngle and endAngle parameters. The arc is drawn in the direction indicated by the clockwise parameter. If the receiver's path is empty, this method sets the current point to the beginning of the arc before adding the arc segment. If the receiver's path is not empty, a line is drawn from the current point to the starting point of the arc.

Depending on the length of the arc, this method may add multiple connected curve segments to the path.

See also:

NSBezierPathMBS.appendBezierPathWithArc(point1 as NSPointMBS, point2 as NSPointMBS, radius as Double)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa Drawing MBS MacBase Plugin 12.5 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Appends an arc to the receiver's path.

point1: The middle point of the angle.
point2: The end point of the angle.
radius: The radius of the circle inscribed in the angle.

The created arc is defined by a circle inscribed inside the angle specified by three points: the current point, the fromPoint parameter, and the toPoint parameter (in that order). The arc itself lies on the perimeter of the circle, whose radius is specified by the radius parameter. The arc is drawn between the two points of the circle that are tangent to the two legs of the angle.

The arc usually does not contain the points in the fromPoint and toPoint parameters. If the starting point of the arc does not coincide with the current point, a line is drawn between the two points. The starting point of the arc lies on the line defined by the current point and the fromPoint parameter.

You must set the path's current point (using the moveToPoint method or through the creation of a preceding line or curve segment) before you invoke this method. If the path is empty, this method raises an NSGenericException exception.

Depending on the length of the arc, this method may add multiple connected curve segments to the path.

See also:

NSBezierPathMBS.appendBezierPathWithGlyph(glyph as Integer, font as NSFontMBS)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa Drawing MBS MacBase Plugin 12.5 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Appends an outline of the specified glyph to the receiver's path.

Glyph: The glyph to add to the path.
font: The font in which the glyph is encoded.

If the glyph is not encoded in the font specified by the font parameter—that is, the font does not have an entry for the specified glyph—then no path is appended to the receiver.

You must set the path's current point (using the moveToPoint method or through the creation of a preceding line or curve segment) before you invoke this method. If the path is empty, this method raises an NSGenericException exception.

Some examples using this method:

NSBezierPathMBS.appendBezierPathWithGlyphs(glyphs() as Integer, font as NSFontMBS)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa Drawing MBS MacBase Plugin 12.5 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Appends the outlines of the specified glyphs to the receiver's path.

glyphs: An array of glpyhs to add to the path.
count: The number of glyphs in the glyphs parameter.
font: The font in which the glyphs are encoded.

If the glyphs are not encoded in the font specified by the font parameter—that is, the font does not have an entry for one of the specified glyphs—then no path is appended to the receiver.

You must set the path's current point (using the moveToPoint method or through the creation of a preceding line or curve segment) before you invoke this method. If the path is empty, this method raises an NSGenericException exception.

NSBezierPathMBS.appendBezierPathWithOvalInRect(rect as NSRectMBS)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa Drawing MBS MacBase Plugin 12.5 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Appends an oval path to the receiver, inscribing the oval in the specified rectangle.

rect: The rectangle in which to inscribe the oval.

Before adding the oval, this method moves the current point, which implicitly closes the current subpath. If the aRect parameter specifies a square, the inscribed path is a circle. The path is constructed by starting in the lower-right quadrant of the rectangle and adding arc segments counterclockwise to complete the oval.

NSBezierPathMBS.appendBezierPathWithPoints(points() as NSPointMBS)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa Drawing MBS MacBase Plugin 12.5 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Appends a series of line segments to the receiver's path.

points: An array of NSPoint data types, each of which contains the end point of the next line segment.
count :The number of points in the points parameter.

This method interprets the points as a set of connected line segments. If the current path contains an open subpath, a line is created from the last point in that subpath to the first point in the points array. If the current path is empty, the first point in the points array is used to set the starting point of the line segments. Subsequent line segments are added using the remaining points in the array.

This method does not close the path that is created. If you wish to create a closed path, you must do so by explicitly invoking the receiver's closePath method.

NSBezierPathMBS.appendBezierPathWithRect(rect as NSRectMBS)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa Drawing MBS MacBase Plugin 12.5 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Appends a rectangular path to the receiver's path.

rect: The rectangle describing the path to create.

Before adding the rectangle, this method moves the current point to the origin of the rectangle, which implicitly closes the current subpath (if any). The path is constructed by starting at the origin of aRect and adding line segments in a counterclockwise direction. The final segment is added using a closePath message.

NSBezierPathMBS.appendBezierPathWithRoundedRect(rect as NSRectMBS, xRadius as Double, yRadius as Double)

Type Topic Plugin Version macOS Windows Linux iOS Targets
method Cocoa Drawing MBS MacBase Plugin 12.5 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Appends a rounded rectangular path to the receiver's path.

rect: The rectangle that defines the basic shape of the path.
xRadius: The radius of each corner oval along the x-axis. Values larger than half the rectangle's width are clamped to half the width.
yRadius: The radius of each corner oval along the y-axis. Values larger than half the rectangle's height are clamped to half the height.

The path is constructed in a counter-clockwise direction, starting at the top-left corner of the rectangle. If either one of the radius parameters contains the value 0.0, the returned path is a plain rectangle without rounded corners.

The items on this page are in the following plugins: MBS MacBase Plugin.


The biggest plugin in space...