| Package | com.yworks.graph.drawing |
| Class | public class ShapeNodeStyleRenderer |
| Inheritance | ShapeNodeStyleRenderer AbstractNodeStyleRenderer AbstractStyleRenderer Object |
IShapeNodeStyle instances.
| Property | Defined By | ||
|---|---|---|---|
| brightenHighlightBy : Number
The value to brighten the stroke color by
when drawing border highlights. | ShapeNodeStyleRenderer | ||
| darkenShadowBy : Number
The value to darken the stroke color by
when drawing border shadows. | ShapeNodeStyleRenderer | ||
![]() | item : IModelItem [read-only]
Gets the currently configured item. | AbstractStyleRenderer | |
![]() | layout : IRectangle [read-only]
Returns the INode.layout of the node this renderer is currently configured for. | AbstractNodeStyleRenderer | |
| roundRectEllipseHeight : Number
Get or set the default ellipse height used for drawing rounded corners. | ShapeNodeStyleRenderer | ||
| roundRectEllipseWidth : Number
Get or set the default ellipse width used for drawing rounded corners. | ShapeNodeStyleRenderer | ||
![]() | style : IVisualStyle [read-only]
Gets the currently configured style. | AbstractStyleRenderer | |
![]() | styleDescriptor : ICanvasObjectDescriptor [read-only]
Gets the ICanvasObjectDescriptor to use for new installations. | AbstractStyleRenderer | |
| Property | Defined By | ||
|---|---|---|---|
| fill : IFill [read-only]
Get the fill that is currently used by this renderer. | ShapeNodeStyleRenderer | ||
| shape : uint [read-only]
Get the shape that is currently used by this renderer. | ShapeNodeStyleRenderer | ||
| stroke : IStroke [read-only]
Get the stroke that is currently used by this renderer. | ShapeNodeStyleRenderer | ||
| Method | Defined By | ||
|---|---|---|---|
![]() | [override]
Returns a tight rectangular area where the whole rendering
would fit into. | AbstractNodeStyleRenderer | |
createDisplayObject(context:IDisplayObjectContext):DisplayObject [override] | ShapeNodeStyleRenderer | ||
![]() |
Configures the style and item parameters,
calls configure and returns this. | AbstractStyleRenderer | |
![]() |
Configures the style and item parameters,
does not call configure and returns this. | AbstractStyleRenderer | |
![]() |
Configures the style and item parameters,
calls configure and returns this. | AbstractStyleRenderer | |
![]() |
Configures the style and item parameters,
calls configure and returns this. | AbstractStyleRenderer | |
getIntersection(innerX:Number, innerY:Number, outerX:Number, outerY:Number, intersectionPoint:IPointSetter):Boolean [override]
Returns the intersection for the given line with this shape's geometry. | ShapeNodeStyleRenderer | ||
![]() |
Configures the style and item parameters,
calls configure and returns this. | AbstractStyleRenderer | |
[override]
Returns the outline of the shape using the node's layout. | ShapeNodeStyleRenderer | ||
![]() |
Configures the style and
item parameters,
calls configure and returns this. | AbstractNodeStyleRenderer | |
![]() |
Installs the model in the canvas at the given group using the styleDescriptor. | AbstractStyleRenderer | |
isHit(x:Number, y:Number, ctx:ICanvasContext):Boolean [override]
Determines if something has been hit at the given coordinates
in the world coordinate system. | ShapeNodeStyleRenderer | ||
![]() | [override]
Returns true if the corresponding
item is considered to intersect the given rectangular box.
This method may return false if the item cannot be
selected using a selection marquee or optionally if the
item is only partially contained within the box. | AbstractNodeStyleRenderer | |
isInside(x:Number, y:Number):Boolean [override]
Checks whether the given coordinate is deemed to lie within the shape's geometric bounds. | ShapeNodeStyleRenderer | ||
![]() |
Calls configure and tests the item using the style
for a visible intersection with the clip bounds. | AbstractStyleRenderer | |
lookup(type:Class):Object [override]
Implements the ILookup interface. | ShapeNodeStyleRenderer | ||
updateDisplayObject(oldDisplayObject:DisplayObject, context:IDisplayObjectContext):DisplayObject [override] | ShapeNodeStyleRenderer | ||
| Method | Defined By | ||
|---|---|---|---|
configure():void [override]
This is an empty implementation of the AbstractStyleRenderer.configure
method. | ShapeNodeStyleRenderer | ||
createRenderDataCache():Object
Creates an Object which reflects the current state of the style and the model item. | ShapeNodeStyleRenderer | ||
![]() | [override]
Factory method for the StyleDescriptor property. | AbstractNodeStyleRenderer | |
| ShapeNodeStyleRenderer | |||
![]() | setItem(item:IModelItem):void
Called by the various descriptor getters to initialize the item. | AbstractStyleRenderer | |
![]() | setStyle(style:IVisualStyle):void
Called by the various descriptor getters to initialize the style. | AbstractStyleRenderer | |
shouldRepaint(oldCache:Object):Boolean
Whether the current display object should be repainted. | ShapeNodeStyleRenderer | ||
updateLayout(obj:DisplayObject, context:IDisplayObjectContext):void | ShapeNodeStyleRenderer | ||
updateRenderDataCache(renderDataCache:Object):Object
Updates the given object with the current state of the style and the node. | ShapeNodeStyleRenderer | ||
| brightenHighlightBy | property |
brightenHighlightBy:NumberThe value to brighten the stroke color by when drawing border highlights.
Valid values are between 0 and 100.
The default value is 50.
public function get brightenHighlightBy():Number public function set brightenHighlightBy(value:Number):void| darkenShadowBy | property |
darkenShadowBy:NumberThe value to darken the stroke color by when drawing border shadows.
Valid values are between 0 and 100.
The default value is 50.
public function get darkenShadowBy():Number public function set darkenShadowBy(value:Number):void| fill | property |
fill:IFill [read-only] Get the fill that is currently used by this renderer.
This implementation retrieves the fill from the owning style.
protected function get fill():IFill| roundRectEllipseHeight | property |
roundRectEllipseHeight:NumberGet or set the default ellipse height used for drawing rounded corners.
public function get roundRectEllipseHeight():Number public function set roundRectEllipseHeight(value:Number):void| roundRectEllipseWidth | property |
roundRectEllipseWidth:NumberGet or set the default ellipse width used for drawing rounded corners.
public function get roundRectEllipseWidth():Number public function set roundRectEllipseWidth(value:Number):void| shape | property |
shape:uint [read-only] Get the shape that is currently used by this renderer.
This implementation retrieves the shape from the owning style.
protected function get shape():uint| stroke | property |
stroke:IStroke [read-only] Get the stroke that is currently used by this renderer.
This implementation retrieves the stroke from the owning style.
protected function get stroke():IStroke| configure | () | method |
override protected function configure():void
This is an empty implementation of the AbstractStyleRenderer.configure
method. Subclasses should override this.
| createDisplayObject | () | method |
override public function createDisplayObject(context:IDisplayObjectContext):DisplayObjectParameters
context:IDisplayObjectContext |
DisplayObject |
| createRenderDataCache | () | method |
protected function createRenderDataCache():ObjectCreates an Object which reflects the current state of the style and the model item.
ReturnsObject — An Object which reflects the current state of the style and the model item.
|
| getIntersection | () | method |
override public function getIntersection(innerX:Number, innerY:Number, outerX:Number, outerY:Number, intersectionPoint:IPointSetter):BooleanReturns the intersection for the given line with this shape's geometry.
Parameters
innerX:Number — The X coordinate of the first point of the line that is inside the shape.
| |
innerY:Number — The Y coordinate of the first point of the line that is inside the shape.
| |
outerX:Number — The X coordinate of the second point of the line that is outside the shape.
| |
outerY:Number — The Y coordinate of the second point of the line that is outside the shape.
| |
intersectionPoint:IPointSetter — The intersection point that is set if this method returns true.
|
Boolean — Whether an intersection was found.
|
| getOutline | () | method |
override public function getOutline():GeneralPath
Returns the outline of the shape using the node's layout.
GeneralPath — The outline of the bounds of the node.
|
| isHit | () | method |
override public function isHit(x:Number, y:Number, ctx:ICanvasContext):BooleanDetermines if something has been hit at the given coordinates in the world coordinate system.
Parameters
x:Number — the x-coordinate in world coordinate system
| |
y:Number — the y-coordinate in world coordinate system
| |
ctx:ICanvasContext — the context the hit test is performed in
|
Boolean — whether something has been hit
|
| isInside | () | method |
override public function isInside(x:Number, y:Number):BooleanChecks whether the given coordinate is deemed to lie within the shape's geometric bounds.
Parameters
x:Number — The x coordinate to test.
| |
y:Number — The y coordinate to test.
|
Boolean — True if the point lies within the shape.
|
| lookup | () | method |
override public function lookup(type:Class):Object
Implements the ILookup interface.
This method will be used by default if getContext has been queried for a
lookup implementation.
Note that it cannot be assumed that configure has already been invoked.
However, normally item and style will be correctly configured
if invoked directly after getContext.
Subclass implementations should make sure to configure this instance before they return this as a result
of a successful lookup.
Parameters
type:Class — The type to query for
|
Object — An implementation of the given type or null
|
| paint | () | method |
protected function paint(g:YGraphics, ctx:IDisplayObjectContext):void
Parameters
g:YGraphics | |
ctx:IDisplayObjectContext |
| shouldRepaint | () | method |
protected function shouldRepaint(oldCache:Object):BooleanWhether the current display object should be repainted.
Parameters
oldCache:Object — An object which reflects the state of the style and node
when the object was repainted the last time.
|
Boolean — true if a repaint is necessary.
|
| updateDisplayObject | () | method |
override public function updateDisplayObject(oldDisplayObject:DisplayObject, context:IDisplayObjectContext):DisplayObjectParameters
oldDisplayObject:DisplayObject | |
context:IDisplayObjectContext |
DisplayObject |
| updateLayout | () | method |
protected function updateLayout(obj:DisplayObject, context:IDisplayObjectContext):voidParameters
obj:DisplayObject | |
context:IDisplayObjectContext |
| updateRenderDataCache | () | method |
protected function updateRenderDataCache(renderDataCache:Object):ObjectUpdates the given object with the current state of the style and the node.
Parameters
renderDataCache:Object — The object to update.
|
Object — An object with the current state of the style and the node.
|