Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic How can i find node position (Read 1777 times)
oxzorxxo
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 13
Joined: Nov 26th, 2018
How can i find node position
Nov 26th, 2018 at 9:56am
Print Post  
How can i find node position, like x and y using javascript Smiley
  
Back to top
 
IP Logged
 
Slavcho
YaBB Moderator
*****
Offline


tech.support

Posts: 3435
Joined: Oct 19th, 2005
Re: How can i find node position
Reply #1 - Nov 26th, 2018 at 11:11am
Print Post  
Try the node.Bounds property -

Code
Select All
function onNodeClicked(sender, args)
{
	var node = args.getNode();
	var pos = node.getBounds().topLeft();
	console.log("x = " + pos.x);
	console.log("y = " + pos.y);
} 



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


I Love MindFusion!

Posts: 13
Joined: Nov 26th, 2018
Re: How can i find node position
Reply #2 - Nov 28th, 2018 at 6:19am
Print Post  
thank you Cheesy
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint