yfiles.client.tiles.GraphHighlighter
Class GraphHighlighter

The default implementation of a highlighter that draws the visual representation of node or edge highlights.

This implementation draws a transparent gray box for highlighted nodes. Edges are highlighted by drawing a small gray box on top of all bends and on the ports.

 
Constructor Summary
GraphHighlighter()
           The default implementation of a highlighter that draws the visual representation of node or edge highlights.
 
Method Summary
  drawEdgeHighlight(/*GraphCanvas*/ canvas, /*DomNode*/ parentDiv, /*Number*/ controlPointIndex, /*Object[]*/ controlPoints)
          draw an overlay which indicates that an edge is highlighted. Note that this function is called for each control point of the edge.
  drawNodeHighlight(/*GraphCanvas*/ canvas, /*DomNode*/ highlightDiv, /*GraphBounds*/ nodeBounds)
          draw a node highlight.
 
Constructor Detail

GraphHighlighter

GraphHighlighter()
The default implementation of a highlighter that draws the visual representation of node or edge highlights.
This implementation draws a transparent gray box for highlighted nodes. Edges are highlighted by drawing a small gray box on top of all bends and on the ports.
Method Detail

drawEdgeHighlight

drawEdgeHighlight(/*GraphCanvas*/ canvas, /*DomNode*/ parentDiv, /*Number*/ controlPointIndex, /*Object[]*/ controlPoints)
draw an overlay which indicates that an edge is highlighted. Note that this function is called for each control point of the edge.
Parameters:
canvas - The GraphCanvas instance
parentDiv - The parent element where highlight elements can be added. No positioning information is assigned to the parent element.
controlPointIndex - The current control point index
controlPoints - The array that contains the the control point as indicated by controlPointIndex.

drawNodeHighlight

drawNodeHighlight(/*GraphCanvas*/ canvas, /*DomNode*/ highlightDiv, /*GraphBounds*/ nodeBounds)
draw a node highlight.
Parameters:
canvas - The GraphCanvas instance
highlightDiv - A html div element that is located on top of the highlighted node. The size and location of the div ist determined by the node bounds, The canvas' zoom level and by the canvas' highlightNodeSurroundPixels property.
nodeBounds - The bounds of the highlighted node.

Copyright © 2006-2011 yWorks GmbH. All rights reserved.