LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Plotting a text in the middle of a polygon

Solved!
Go to solution

Hi

I have a polygon and a text field on a graph.

I would like to center the text field in the polygon. Therefore I should have the size of the bounding rectangle of the text.

I couldn't find an attribute giving this information.

Has someone an idea how I could achieve my goal?

Thank you

0 Kudos
Message 1 of 4
(2,123 Views)

A quick and dirty solution: use a (hidden) text message control with the same font and size you are using on the graph and operate based on the bounding rect of that control.



Proud to use LW/CVI from 3.1 on.

My contributions to the Developer Community
________________________________________
If I have helped you, why not giving me a kudos?
0 Kudos
Message 2 of 4
(2,099 Views)
Solution
Accepted by topic author Bertrand_ENAC

Hi

 

Maybe the function GetTextDisplaySize() works for you.

 

Jan

Message 3 of 4
(2,088 Views)

Thank you. Your answer was helpfull.

0 Kudos
Message 4 of 4
(1,996 Views)