Class CellHighlight

A helper class to highlight cells. Here is an example for a given cell.

var highlight = new mxCellHighlight(graph, '#ff0000', 2);
highlight.highlight(graph.view.getState(cell)));

Constructors

Properties

dashed: boolean = false
graph: Graph

Reference to the enclosing graph.

true
highlightColor: string
keepOnTop: boolean = false

Specifies if the highlights should appear on top of everything else in the overlay pane.

false
opacity: number = 100
repaintHandler: Function
resetHandler: Function

Holds the handler that automatically invokes reset if the highlight should be hidden.

null
shape: null | Shape = null
spacing: number = 2

Specifies the spacing between the highlight for vertices and the vertex.

2
state: null | CellState = null

Reference to the CellState.

null
strokeWidth: number = 0

Methods

  • Returns true if this highlight is at the given position.

    Parameters

    • x: number
    • y: number

    Returns boolean

  • Sets the color of the rectangle used to highlight drop targets.

    Parameters

    • color: string

      String that represents the new highlight color.

    Returns void