Struct nanovg::Path[][src]

pub struct Path<'a, 'b> where
    'b: 'a, 
{ /* fields omitted */ }

A path, the main type for most NanoVG drawing operations.

Methods

impl<'a, 'b> Path<'a, 'b>
[src]

Get the underlying context this path was created on.

Draw the current path by filling in it's shape. 'paint' specifies in which color/paint should fill be drawn. pass variables that implement Paint trait for now these are: Color, Gradient, ImagePattern 'options' specifies how filling should be done.

Draw the current path by stroking it's perimeter. 'paint' specifies in which color/paint should stroke be drawn. pass variables that implement Paint trait for now these are: Color, Gradient, ImagePattern 'options' specifies how stroking should be done.

Add an arc to the path.

Add a rectangle to the path.

Add a rounded rectangle to the path.

Add a rounded rectangle with varying corners to the path. top_radii and bottom_radii are both tuples in the form (left, right).

Add an ellipse to the path.

Add a circle to the path.

Add a line to the subpath.

Add a cubic bezier curve to the subpath.

Add a quadratic bezier curve to the subpath.

Add a arc to the subpath.

Set the winding of the subpath. The winding defines which parts of the subpath are 'inside' and which are 'outside'.

Start new sub-path with specified coordinates as the first point.

Close the path, ie. connect the first point and last point with a line.

Trait Implementations

impl<'a, 'b> Debug for Path<'a, 'b> where
    'b: 'a, 
[src]

Formats the value using the given formatter. Read more

Auto Trait Implementations

impl<'a, 'b> !Send for Path<'a, 'b>

impl<'a, 'b> !Sync for Path<'a, 'b>