Path class

A bézier path containing a set of path commands similar to a SVG path. Paths can be drawn on a context using draw. @exports opentype.Path @class @constructor

Constructors

Path()

Properties

commands List<Map<String, dynamic>>
getter/setter pair
fill String
getter/setter pair
hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
stroke ↔ dynamic
getter/setter pair
strokeWidth int
getter/setter pair
unitsPerEm ↔ dynamic
getter/setter pair

Methods

bezierCurveTo(dynamic x1, dynamic y1, dynamic x2, dynamic y2, dynamic x, dynamic y) → dynamic
close() → dynamic
Close the path @function close @memberof opentype.Path.prototype
closePath() → dynamic
curveTo(dynamic x1, dynamic y1, dynamic x2, dynamic y2, dynamic x, dynamic y) → dynamic
Draws cubic curve @function bezierCurveTo @memberof opentype.Path.prototype @param {number} x1 - x of control 1 @param {number} y1 - y of control 1 @param {number} x2 - x of control 2 @param {number} y2 - y of control 2 @param {number} x - x of path point @param {number} y - y of path point @see curveTo
extend(dynamic pathOrCommands) → dynamic
Add the given path or list of commands to the commands of this path. @param {Array} pathOrCommands - another opentype.Path, an opentype.BoundingBox, or an array of commands.
getBoundingBox() → dynamic
Calculate the bounding box of the path. @returns {opentype.BoundingBox}
lineTo(dynamic x, dynamic y) → dynamic
moveTo(num x, num y) → dynamic
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
quadraticCurveTo(dynamic x1, dynamic y1, dynamic x, dynamic y) → dynamic
quadTo(dynamic x1, dynamic y1, dynamic x, dynamic y) → dynamic
Draws quadratic curve @function quadTo @memberof opentype.Path.prototype @param {number} x1 - x of control @param {number} y1 - y of control @param {number} x - x of path point @param {number} y - y of path point
toPathData(int decimalPlaces) → dynamic
Convert the Path to a string of path data instructions See http://www.w3.org/TR/SVG/paths.html#PathData @param {number} decimalPlaces=2 - The amount of decimal places for floating-point values @return {string}
toString() String
A string representation of this object.
inherited
toSVG(dynamic decimalPlaces) → dynamic
Convert the path to an SVG

Operators

operator ==(Object other) bool
The equality operator.
inherited