Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Position of text lines in ShapeNode (Read 2773 times)
tjugg
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 12
Joined: Oct 20th, 2017
Position of text lines in ShapeNode
Jan 19th, 2018 at 12:18pm
Print Post  
Hi, we have WPF TextBoxes added inside the shapenode, and we have our users write to them. Problem is, that we need to generate something from these shapenodes, and we would need the exact position of the textlines inside the textboxes. Is it anyhow possible to get the position of the text inside the textbox? E.g textBox.GetLines() would return a list of objects that contains the text and the position of the line relative to the canvas?

With PlainText I can get the text that contains all the newlinse and stuff like this, but the thing I would need is the actual position of the text.
« Last Edit: Jan 19th, 2018 at 1:41pm by tjugg »  
Back to top
 
IP Logged
 
Slavcho
YaBB Moderator
*****
Offline


tech.support

Posts: 3147
Joined: Oct 19th, 2005
Re: Position of text lines in ShapeNode
Reply #1 - Jan 19th, 2018 at 2:29pm
Print Post  
Hi,

We added a TextLines property last year retuning the line strings -
https://mindfusion.eu/Forum/YaBB.pl?num=1489395154/4#4

could still work for you if you multiple line index by font size. We'll see if we can get exact positions from underlying glyph-runs.

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


I Love MindFusion!

Posts: 12
Joined: Oct 20th, 2017
Re: Position of text lines in ShapeNode
Reply #2 - Jan 22nd, 2018 at 9:01am
Print Post  
Hi, I noticed the textlines property, but I think that we would really need to somehow fetch the actual position of the textline in the node Undecided

Br,
T
  
Back to top
 
IP Logged
 
tjugg
YaBB Newbies
*
Offline


I Love MindFusion!

Posts: 12
Joined: Oct 20th, 2017
Re: Position of text lines in ShapeNode
Reply #3 - Jan 22nd, 2018 at 9:48am
Print Post  
Just to make sure that you know what I mean, here is a piece of art to represent that.
  

textexample.png ( 5 KB | 89 Downloads )
textexample.png
Back to top
 
IP Logged
 
Slavcho
YaBB Moderator
*****
Offline


tech.support

Posts: 3147
Joined: Oct 19th, 2005
Re: Position of text lines in ShapeNode
Reply #4 - Jan 24th, 2018 at 9:54am
Print Post  
Now that's a masterpiece Wink Okay, we'll have it in mind for next release. Shouldn't be a problem if you use the EnableStyledText or PolygonalTextLayout properties, since we are using a custom text layout and formatting then. For plain-text formatting we'll try to get positions from the WPF visual tree.

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


I Love MindFusion!

Posts: 12
Joined: Oct 20th, 2017
Re: Position of text lines in ShapeNode
Reply #5 - Jan 24th, 2018 at 10:15am
Print Post  
Okay Smiley. Do you have any date when will the next release be done?

Br,
T
  
Back to top
 
IP Logged
 
Slavcho
YaBB Moderator
*****
Offline


tech.support

Posts: 3147
Joined: Oct 19th, 2005
Re: Position of text lines in ShapeNode
Reply #6 - Jan 24th, 2018 at 3:03pm
Print Post  
We try to release every 3-4 months, so at some point in March...

Regards,
Slavcho
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint