Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Obtaining text bounds (Read 993 times)
Dexter
Junior Member
**
Offline


I love YaBB 1G - SP1!

Posts: 62
Joined: Jun 25th, 2009
Obtaining text bounds
Aug 26th, 2009 at 7:54am
Print Post  
Hi there! Is there any way of calculating if the user double clicks the text of a shape node/table node cell and not the node it self? Meaning the user double click the text and the user double click the region inside the node but not on the text.

Best regards,
dexter
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Obtaining text bounds
Reply #1 - Aug 26th, 2009 at 11:58am
Print Post  
Hi,

You could call the Diagram.MeasureString method to get the text size. Then you can determine the text bounds from the size, the text alignment specified in TextFormat, and from node.Bounds.

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint