I was trying to do it in this way, but it is not working. The list of cells which i want to highlight are in cellList.( includes a vertex and two edges). var highlight= new mxCellHighlight(graph, '#0000ff', 2); for(var i=0;i<cellList.length;i++) { highlight.highlight(graph.view.getState(cellList[i])); } This is inside mouseMove function. On mouse out , How do i hide the highlighting of these cells.

asked 29 May '12, 00:19

guest's gravatar image

guest
23113
accept rate: 0%


Create one mxCellHighlight instance per cell. Use mxCellHighlight.hide to hide the highlight and mxCellHighlight.destroy to destroy the instance, and remove all installed listeners and DOM nodes.

link

answered 29 May '12, 09:25

Gaudenz's gravatar image

Gaudenz
80.1k1310
accept rate: 39%

edited 29 May '12, 09:26

Thanks highlight is working fine. But i am not able to hide the highight or destroy is using instances of the highlight.I am including the hide code in mouseout function when the cell is null. Is there any other way ?

link

answered 30 May '12, 02:59

guest's gravatar image

guest
23113
accept rate: 0%

Works for me.

(30 May '12, 03:04) Gaudenz

ie in mouse Move function if cell is null , i am trying to do this for(var j=0;j<highlight.length;j++) { highlight[j].hide(); highlight[j].destroy(); } Is this right ?

(30 May '12, 03:09) guest
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×66
×11

Asked: 29 May '12, 00:19

Seen: 1,437 times

Last updated: 30 May '12, 03:09