| Language \ Environment \ Comparison |

| Index

| The Processing 1.0 _ALPHA_ Reference is a work in progress. If you see any errors or have any comments, please write to: reas at groupc.net

Name |  | ### strokeWidth()
Examples |  |
    stroke(1);   // Default
    line(20, 20, 80, 20);

    stroke(4);   // Thicker
    line(20, 40, 80, 40);

    stroke(0.5); // Hairline
    line(20, 60, 80, 60);

    stroke(10);  // Beastly
    line(20, 80, 80, 80);
Description |  | Sets the width of the stroke used for lines or as the border around a shape. All widths are set in units of pixels.
Syntax |  |
    strokeWidth(width)
Parameters |  |
width |  | int or float: the weight (in pixels) of the stroke
Returns |  | None
Usage |  | Web & Application
Related |  | stroke() strokeMode()

| © 2003- 2001 Massachusetts Institute of Technology and Interaction Design Institute Ivrea |
| Processing is an open project initiated by Ben Fry and Casey Reas |