Package | io.github.ycabon.markings.lineClasses |
Class | public class IconPart |
Inheritance | IconPart flash.display.Sprite |
Implements | ILinePart, spark.core.IGraphicElementContainer |
This part creates and places markers along the line using Spark primitives from the Flex SDK:
BitmapImage
- draws a bitmap data from a source file or source URL.
Ellipse
- draws an ellipse.
Line
- draws a line between two points.
Path
- draws a series of path segments.
Rect
- draws a rectangle.
... <mk:AdvancedLineSymbol> <s:ArrayList> <mk:IconPart repeat="15"> <s:Ellipse width="10" height="10"> <s:fill> <s:SolidColor color="0xFD7F00"/> </s:fill> <s:stroke> <s:SolidColorStroke color="0xFFD92F" weight="2"/> </s:stroke> </s:Ellipse> </mk:IconPart> </s:ArrayList> </mk:AdvancedLineSymbol> ...MXML SyntaxHide MXML Syntax
The <mk:IconPart>
tag inherits all the tag attributes
of its superclass, and adds the following tag attributes:
<mk:IconPart Properties graphicElement="null" offset="NaN" repeat="NaN" rotate="false" />
Default MXML PropertygraphicElement
See also
Property | Defined By | ||
---|---|---|---|
graphicElement : GraphicElement
The element that will be repeated along the line. | IconPart | ||
offset : Number
Number that specifies the distance from the start of the Polyline. | IconPart | ||
percentOffset : Number
Number that specifies the distance from the start of the Polyline. | IconPart | ||
percentRepeat : Number
Number that specifies the distance between to repetitions of the graphicElement. | IconPart | ||
repeat : Number
Number that specifies the distance between to repetitions of the graphicElement. | IconPart | ||
rotate : Boolean
Whether or not the graphic element is rotated to make in look like it follows it. | IconPart |
Method | Defined By | ||
---|---|---|---|
IconPart(graphicElement:GraphicElement = null, offset:Number, percentOffset:Number, repeat:Number, percentRepeat:Number, rotate:Boolean = false)
Constructor. | IconPart |
Event | Summary | Defined By | ||
---|---|---|---|---|
Dispatched when the value of the part changes as a result of its properties modifications. | IconPart |
graphicElement | property |
graphicElement:GraphicElement
The element that will be repeated along the line. The element must not have filters, blend mode, transformations defined to be properly render.
The default value is null
.
This property can be used as the source for data binding.
public function get graphicElement():GraphicElement
public function set graphicElement(value:GraphicElement):void
See also
offset | property |
offset:Number
Number that specifies the distance from the start of the Polyline. One typical use of this property is for giving the impression of movement.
Note: You can specify a percentage value in the MXML
offset
attribute, such as offset="100%"
,
but you cannot use a percentage value in the offset
property in ActionScript.
Use the percentOffset
property instead.
Setting the percentOffset
property
resets this property to NaN.
The default value is NaN
.
This property can be used as the source for data binding.
public function get offset():Number
public function set offset(value:Number):void
See also
percentOffset | property |
percentOffset:Number
Number that specifies the distance from the start of the Polyline. One typical use of this property is for giving the impression of movement.
Setting the offset
property
resets this property to NaN.
The default value is NaN
.
This property can be used as the source for data binding.
public function get percentOffset():Number
public function set percentOffset(value:Number):void
See also
percentRepeat | property |
percentRepeat:Number
Number that specifies the distance between to repetitions of the graphicElement
.
If the value is NaN
, the element is not repeated.
Setting the repeat
property
resets this property to NaN.
The default value is NaN
.
This property can be used as the source for data binding.
public function get percentRepeat():Number
public function set percentRepeat(value:Number):void
See also
repeat | property |
repeat:Number
Number that specifies the distance between to repetitions of the graphicElement
.
If the value is NaN
, the element is not repeated.
Note: You can specify a percentage value in the MXML
repeat
attribute, such as repeat="100%"
,
but you cannot use a percentage value in the repeat
property in ActionScript.
Use the percentRepeat
property instead.
Setting the percentRepeat
property
resets this property to NaN.
The default value is NaN
.
This property can be used as the source for data binding.
public function get repeat():Number
public function set repeat(value:Number):void
See also
rotate | property |
rotate:Boolean
Whether or not the graphic element is rotated to make in look like it follows it.
Setting this flag to true
has some impact on performances if a lot of objects are render.
The default value is false
.
This property can be used as the source for data binding.
public function get rotate():Boolean
public function set rotate(value:Boolean):void
IconPart | () | Constructor |
public function IconPart(graphicElement:GraphicElement = null, offset:Number, percentOffset:Number, repeat:Number, percentRepeat:Number, rotate:Boolean = false)
Constructor.
ParametersgraphicElement:GraphicElement (default = null )
| |
offset:Number (default = NaN )
| |
percentOffset:Number (default = NaN )
| |
repeat:Number (default = NaN )
| |
percentRepeat:Number (default = NaN )
| |
rotate:Boolean (default = false )
|
change | Event |
flash.events.Event
flash.events.Event.CHANGE
Dispatched when the value of the part changes as a result of its properties modifications.