PPhys2D Home
A Phys2D adaptation for Processing.
  • information
  • reference
  • examples

Reference

  • Body Classes
    • PPBox
    • PPCircle
    • PPConvexPoly
    • PPLine
    • PPPoly
  • Body Functions
    • (PPBox)getHeight()
    • (PPBox)getWidth()
    • (PPBox)setSize()
    • (PPCircle)getSize()
    • (PPCircle)setSize()
    • addExcludedBody()
    • addForce()
    • adjustAngularVelocity()
    • adjustVelocity()
    • applyMatrix()
    • attachImage()
    • dettachImage()
    • getAngularVelocity()
    • getImageAlpha()
    • getRotation()
    • getVelocityX()
    • getVelocityY()
    • getX()
    • getY()
    • isResting()
    • isStatic()
    • isTouchingBody()
    • resetForces()
    • setAngularVelocity()
    • setDamping()
    • setDrawable()
    • setFillColor()
    • setFriction()
    • setGravityEffected()
    • setImageAlpha()
    • setMass()
    • setPosition()
    • setRestitution()
    • setRotatable()
    • setRotation()
    • setRotDamping()
    • setStaticBody()
    • setStrokeColor()
    • setStrokeWidth()
    • setVelocity()
  • World Classes
    • PPWorld
  • World Fucntions
    • add()
    • clear()
    • draw()
    • remove()
    • setDamping()
    • setEdges()
    • setEdgesFriction()
    • setEdgesRestitution()
    • setGravity()
    • step()

setStrokeWidth()

Description

Set the stroke width used to draw the body. This will not be used if an image is attached to the body. The stroke width is not considered in body collision.

Exemples

PPBox myBox = new PPBox(20, 30);
myBox.setStrokeWidth(3);
world.add(myBox);

Syntax

myBody.setStrokeWidth(width);

Parameters

width ->

float : the width of the stroke.

Jean-Maxime Couillard - jm.couillard@globetrotter.net - Website bulit using CodeIgnitier PHP Engine with valid XHTML 1.0 Strict