Skip to content

Specify lineWidth / stroke width #582

@scottpdo

Description

@scottpdo

It seems like it would be helpful if there were a way to specify a stroke thickness along with the stroke color. I know it can be done by getting and adjusting the context, but it would be more intuitive to have either a built-in function or parameter to do this.

Now:

var canvas = createCanvas( w, h );
canvas.drawingContext.lineWidth = 2;

Maybe something like:

strokeWidth(2);

Or:

stroke({
  color: 'foo',
  width: 2
});

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions