How To Get The Height Of Area Of A Multiline Text

I have a list that contains some texts and images that going to be downloaded. I have to set the coordinates of the image below the text and as the text is multiline, I need some way to find the exact height of the text area to set image properly after it.

Can someone here suggest me how to tackle it.

Thanks in advance

I’m pretty sure it’s just 

[lua]

myText.contentHeight

[/lua]

C

Thank you so much…
I was doing something wrong in handling wrapping of text.

I’m pretty sure it’s just 

[lua]

myText.contentHeight

[/lua]

C

Thank you so much…
I was doing something wrong in handling wrapping of text.

myText.contentHeight returns full height of myText object.

for example:

myText = display.newEmbossedText("very\_big\_text\_here", 0, 0, 400,100, nil, 20) print(myText.contentHeight)  

and i get 112. how i can detect text height only?

you should set the height parameter to 0 …

myText = display.newEmbossedText("very\_big\_text\_here", 0, 0, 400,0, nil, 20) print(myText.contentHeight) or  print(myText.height)  

thank you!

myText.contentHeight returns full height of myText object.

for example:

myText = display.newEmbossedText("very\_big\_text\_here", 0, 0, 400,100, nil, 20) print(myText.contentHeight)  

and i get 112. how i can detect text height only?

you should set the height parameter to 0 …

myText = display.newEmbossedText("very\_big\_text\_here", 0, 0, 400,0, nil, 20) print(myText.contentHeight) or  print(myText.height)  

thank you!