01-30-2011 09:03 PM
Hello, in the adobe documentation for ActionScript 3.0 the thickness parameter of flash.display.graphics.lineStyle is defined as:
"An integer that indicates the thickness of the line in points; "
How many pixels are in one point? Basically I need to know how many pixels a line created with a certain thickness will take up.
Solved! Go to Solution.
01-30-2011 10:35 PM
contrary to what the description says, i think the value is actually in pixels. from the times i've used it, eyeballing it looks like its in pixels.
here is an excerpt from a page on adobe.com where they show an example of its use. they also refer it to as a pixel value:
"... For example, this line of code tells the Shape named myShape to draw lines that are 2 pixels thick, red (0x990000), and 75% opaque: ..."
and the code example:
myShape.graphics.lineStyle(2, 0x990000, .75);
here is the page:
hope that helps. good luck!
01-31-2011 08:30 AM
In case you do encounter point as a measurement unit (generally in typography), note that it's now defined as 1/72 of an inch (0.0139"), or 0.3528mm.
01-31-2011 01:24 PM
Kudo for JRab - I couldn't figure out why when I set an opaque background to 1 or 100 it didn't change. It never clued in to me that it's a percentage and needs to be between 0 and 1.
01-31-2011 01:28 PM
in most places where they require an alpha value (percentage), its usually a decimal less than or equal to 1. it has stumped me and others in the past im sure. its common mistake so no worries. thanks for the kudo. glad i could help!