Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic On mouseOver get the tablenode cell (Read 1617 times)
reshma16
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 3
Joined: Jan 3rd, 2020
On mouseOver get the tablenode cell
Jan 3rd, 2020 at 8:47am
Print Post  
How to get or select tablenode cell? or On mouse Over event how to get table node cell
  
Back to top
 
IP Logged
 
Slavcho
YaBB Moderator
*****
Offline


tech.support

Posts: 3153
Joined: Oct 19th, 2005
Re: On mouseOver get the tablenode cell
Reply #1 - Jan 3rd, 2020 at 10:53am
Print Post  
You could call table's cellFromPoint method from handlers of nodeClicked and nodePointed events. The result object contains cell's reference, grid indices and boundaries -

{ cell: cell, cellRect: cellRect, column: c, row: r }

The library does not provide built-in cell selection, you could implement your own with some event handling and changing cell's brush.

Regards,
Slavcho
Mindfusion
  
Back to top
 
IP Logged
 
reshma16
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 3
Joined: Jan 3rd, 2020
Re: On mouseOver get the tablenode cell
Reply #2 - Jan 7th, 2020 at 9:43am
Print Post  
It's used for me.
Thank you for the information
  
Back to top
 
IP Logged
 
Brarord
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 18
Joined: Dec 30th, 2019
Re: On mouseOver get the tablenode cell
Reply #3 - Jan 8th, 2020 at 1:35pm
Print Post  
You can do it in that way:

Code (Javascript)
Select All
canvas.addEventListener('mousemove', function () {
       var point = PivotPoint.Point;
       point.x = diagram.pointerPosition.x;
       point.y = diagram.pointerPosition.y;
       var tableNode = diagram.getNodeAt(point);
       if (tableNode) {
       var hoverCell = tableNode.cellFromPoint({x: point.x, y: point.y});
       }
}); 




Regards,
poor student  Undecided
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint