Adding a Simple One-Color Fill : Graphics : Graphics Flash / Flex / ActionScript examples


Flash / Flex / ActionScript examples » Graphics » Graphics »

 

Adding a Simple One-Color Fill


 
package{
  import flash.display.*;
  
  public class Main extends Sprite{
    public function Main(){
        var shape:Shape = new Shape ();
        shape.graphics.lineStyle(00xFF0000);
        shape.graphics.beginFill(0xFFFF00,100);
        
        shape.graphics.lineTo(1000);
        shape.graphics.lineTo(100100);
        shape.graphics.lineTo(0100);
        shape.graphics.lineTo(00);
        shape.graphics.endFill();
        addChild(shape);

    }
  }
}

        



Leave a Comment / Note


 
Verification is used to prevent unwanted posts (spam). .


Flash / Flex / ActionScript examples

 Navioo Graphics
» Graphics