ActionScript 3.0 :: LineGradientStyle - Drawing Hairline Stroke?

Jun 3, 2010

I am trying to draw a hairline stroke 200 px long like in the picture (3 colors). I have tried with this but i am not getting the same results:
Code:
var s:Sprite = new Sprite();
s.graphics.lineStyle(0 );
s.graphics.lineGradientStyle("linear", [0x111111, 0xcccccc,0x111111], [100,100,100], [0,128,255]);
s.graphics.lineTo(200,0);
addChild(s);

View 0 Replies


Similar Posts:


ActionScript 3.0 :: Have A Movieclip (hairline Stroke) And After Changing Its Width Or Height It Disappears?

Jan 4, 2010

i have a movieclip (hairline stroke) and after changing its width or height it disappears...

View 1 Replies

Drawing Tool - How To Add Stroke To Object

Apr 16, 2009

I'm having a hard time with strokes. First I selected a stroke and the properties panel would not let me change it's thickness. How to add a stroke to an object. We used to have a tool that allowed us to apply a stroke to an object. That is gone now. How we attach a line to an object now?? It looks like Adobe has changed Flash CS4 to be more like Photoshop. It is about as intuitive as a tax form.

View 1 Replies

ActionScript 3.0 :: Calling Drawing Tool Stroke Styles Presets ?

Mar 28, 2009

Is there a way in as3 to manually call one of the preset line stroke styles? I'm going to be drawing a line in as3 and want to use one of the stroke styles given in the pull down menu (6th down actually) in the line drawing tool in the gui.

View 1 Replies

ActionScript 3.0 :: Calling Stroke Styles From Line Drawing Tool?

Mar 28, 2009

Is there a way in as3 to manually call one of the preset line stroke styles? I need to call one of the stroke styles given in the pull down menu (6th down actually) in the line drawing tool. I.E. I'd like to be able to draw the exact same line via manual calls in as3 that I can draw with the line took in the GUI.

View 1 Replies

ActionScript 2.0 :: Change Movie Clip Height For More Then 220 Hairline Gets Thick

Aug 19, 2004

Check out "Attach Files".. I want to make a cube motion where my hairline will stay skinny.. (left cube) but if I change movie clip height for more then 220 my hairline gets thick! (right cube)

View 5 Replies

ActionScript 2.0 :: Make A Cube Motion Where Hairline Will Stay Skinny

Aug 19, 2004

Check out "Attach Files".. I want to make a cube motion where my hairline will stay skinny.. (left cube) but if I change movie clip height for more then 220 my hairline gets thick! (right cube)

View 5 Replies

ActionScript 3.0 :: Pencil Tool - Drawing Above A Image But The Drawing Is Below The Picture

Nov 9, 2010

i've tried to simulate a pencil tool, for drawing above a imagem, but the drawing is below the picture. How fix it?

[Code]....

View 3 Replies

ActionScript 3.0 :: Generate Drawing API Data From Drawing Object?

Jul 22, 2009

Basically I've got a reasonably complex drawing object in a fla and I want to reproduce it in a class definition using the drawing api. However obviously this is a tedious task, so is there some trick or automated method of doing this?

Last time I needed to do this it was a drawing of an arrow and I ended up writing down x,y,width,height values for everything but this one has curves in it which I don't have experience with drawing anyway.

View 2 Replies

ActionScript 2.0 :: Enabling Drawing Only When Drawing = True

Sep 28, 2009

I cannot get this to work. Without the "var drawing", "var drawing being true or false" and the "if statement", it works fine. But I need to add the "var drawing" so that you can only draw if you turn it on by pressing the "draw_btn" button. Note, I do not get an error, the script "apparently" contains no errors. Here is the code:

ActionScript Code:
var drawing = false
_root.createEmptyMovieClip("myLine", 0);

[Code].....

View 3 Replies

ActionScript 3.0 :: Drawing Over A Movieclip In A Custom Drawing App?

Jan 13, 2012

I've created a drawing tool which allows the user to draw on the canvas, the problem is that if I try to draw over a movieclip nothing happens. Is there a way I can allow for the user to draw over movieclips? For example if I had a background of paper?

Here's the code I'm using for it:

// This code is for drawing the lines on the page
//1.
var drawingLine:MovieClip = new MovieClip();
addChildAt(drawingLine,0);

[code]....

View 8 Replies

CS4 :: Add Stroke In It?

Apr 27, 2010

I need to know how to add a stroke to an object after I have created it.

I guess the simple way of explaining is if I draw a circle without a stroke, how do I add one to the circle?

View 1 Replies

ActionScript 3.0 :: Drawing Api Drawing 40,000 Objects

Feb 18, 2009

I need to draw on stage about 40,000 4x4 squares each a different color. The color is determined by an xml file. I have this working in as2 and have converted it to as3 the problem is the amount of time it takes to draw is causing cs4 to time out. I have extended the script time out to 60 seconds. In cs3 as2 it would draw the squares in about 15 seconds. I was hoping as3 cs4 would improve performance but seems to be the opposite. I have tried several methods such as adding children and various drawing variations. the bellow seems to work the best, but is still causing flash to crash.

ActionScript Code:
import flash.display.DisplayObject;
import flash.display.Graphics;
import flash.display.Shape;

[Code]...

View 9 Replies

Add A Stroke To Text In Flash?

Mar 20, 2009

Is there a way to add a stroke to text in flash and if so could you explain how? I am still on flash 8.

View 2 Replies

CS3 Sound On Keyboard Stroke

Jun 13, 2009

Well i've used flash a bit but i never really messed with sounds. I want to make kind of a drum tool fun thing that can play sounds, so i need to know how to make a sound play when you press a letter or buton on keyboard

View 1 Replies

Adding A Stroke To A Shape?

Aug 27, 2010

So I like the whole convert stroke to fill option in the Modify menu, but what if I want to apply a stroke to a fill?

In other words, if I created a circle, then delete the stroke, is there any way to the regenerate the stroke? I mean, if I press A I can see the contours of the fill - can I just turn that into a stroke? In the properties menu, if I click on stroke (which as its colour has the white box with a red diagonal line) it's all greyed out. Am I missing something obvious?

View 2 Replies

Professional :: Add Stroke To An Array

Nov 8, 2011

I'm trying to create a simple coloring book app and I've got it mostly working based on tutorials and code I've found on the web. I'm using an array for my color swatches and I'm trying to add a stroke but it's not working. The markers in the array are based on a symbol called "Colours".[code]

View 5 Replies

Actionscript 3 :: Add A Stroke To Text?

Apr 12, 2012

How do I add a stroke to text in Flex 4? Specifically I'd like to add it to a Label (the text will change in it).

The closest solution suggested has been to add a drop shadow filter as shown below. I've added a rectangle with a stroke for comparison. If the stroke weight is between 2 to 3 it's acceptable. If it's above or below that then it's too blurry or rough. In my case I need to support 2 to 6 weight.

A follow up question would be is it possible to create a stroke filter through Pixel Bender.

<s:VGroup>
<s:Label text="Select an example on the left. Right-click to view source."
color="#FF8C00"
top="10" left="10"

[Code].....

View 3 Replies

IDE :: How To Switch Off Stroke Color

Jan 20, 2010

How to switch off Stroke Color in Flash CS4. I am a learner.

View 2 Replies

ActionScript 3.0 :: Way To Add Stroke To A Text?

Jun 7, 2011

Is there any way to add stroke to a text? I'm quite surprised to have not found anything about this yet.

View 1 Replies

ActionScript 3.0 :: How To Add Stroke To Sprite

Mar 21, 2012

I have a series of previously created rectangles, all with a lineStyle(stoke), but later, when in the program, I highlight them via colorTranform with MOUSE_OVER, and and return the color back to its previous state with MOUSE_OUT, and try to re-apply the lineStyle, it returns the color, but not the lineStyle.

Here is my code:
function highlightSquare(e:MouseEvent) {
if (building == true) {
transform1.color = 0x00CCFF;
var temp1 = e.currentTarget;
temp1.transform.colorTransform = transform1;
[Code] .....

View 3 Replies

Apply A Stroke To An Imported Photo?

Nov 19, 2009

In Flash CS4, is it not possible to apply a stroke to an imported photo (which I've converted to a movie clip symbol)?

View 3 Replies

Professional :: Use The Pen Tool Without A Stroke - Only Fill

Jun 15, 2010

So we're sitting here at the studio trying to figure out how to use the pen tool without a stroke. We do most of the work in Illustrator, then paste it in Flash. Unfortunately, some objects sometimes disappear while breaking the object down, which means that we have to do some actual touchup work in Flash.

View 2 Replies

ActionScript 3.0 :: Score Text With Stroke?

Apr 26, 2011

Apparently you can add stroke to text dynamically. Therefore how can I produce a score text with stroke around the numbers. Would I have to create the ten numbers in photoshop or in flash breaking apart and using the ink bottle and simply call them as required. ie: 10 seconds calls in the 1 and the 0 shape mimicking a real timer. Adds more for the cpu to do but looks wonderful. What do angry birds or anything similar do.

View 2 Replies

ActionScript 3.0 :: Adding Stroke To Images?

Mar 22, 2009

I was wondering how I can add stroke to my images, I want tohave a white border (3 pixel) around my images and I am calling myimages from a image folder with a TXT or XML file. Is there a wayto add the stroke to them using AS3 so it automatically applies thestroke to all my images?

View 11 Replies

Actionscript :: FLEX Add Stroke Programmatically

May 4, 2010

how can I assign the stroke to my LineSeries, programmatically in Actionscript ?<mx:LineSeries stroke="{new Stroke(0xCC33CC, 2)}"/>How is it in Actionscript? LineSeries.stroke doesn't exist

View 2 Replies

ActionScript 3.0 :: Add Stroke To A Geometric Shape?

Oct 5, 2009

Is there an easy way to add a stroke to a geometric shape other than a modified glow filter? Say you draw a series of points and fill it in so you have a star pattern, how would you go about adding a 1px or 2px stroke to it?

View 3 Replies

ActionScript 3.0 :: Add Stroke To Images Loaded Via XML?

Jan 28, 2010

As the title says. How do I add a stroke or outline to the images loaded by my XML? I need to create a hover state and selected state. So when I rollover my images there is a blue stroke that goes around the image. I created a new movieClip called newHover and I thought I could add it using my loaders mouseout and mouseover events but the loader class doesn't support do that.Maybe adding a movieClip that has the stroke isn't the way to work this. how to accomplish this.

ActionScript Code:
//floor color1
var cityPic:Dictionary = new Dictionary();

[code].....

View 9 Replies

Actionscript 3.0 :: Getting Fill And Stroke Styles?

Mar 1, 2009

I have a Shape object called myShape which contains exactly one rectangle.Is there a way to know the stroke and fill styles of myShape? I want to get the fill color, fill alpha, stroke color, stroke alpha and stroke thickness of the rectangle in myShape.

View 1 Replies

IDE :: Way To Preserve A Stroke Whilst Resizing

Feb 24, 2009

I would like to know if there is a way of maintain the stroke size whilst resizing my object with actionscript.I have an object that imported from Illustrator with a 7pt stroke and would like that stroke to maintain its aspect even when resized to 10%

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved