[Gambas-user] problems with TextLables

Benoit Minisini gambas at ...1...
Wed Dec 29 11:12:41 CET 2004


On Tuesday 28 December 2004 23:39, Charlie Reinl wrote:
> Salut Benoit,
>
> I know it is 2 day before 1.0
> But I have problems with the TextLables (RC5)
>
> While trying to analyze the TextLable.Text I found that.
>
> How to handle '<'  and '>' , see example.(push Buttons)
>
> I wished I would have something like TextLable.TransformedText, which shows
> you the Text as it will displayed (without the format stuff)
>
> I need it for the attached ToolBox. To calculate the size off the
> TextLable.
>
> Amicalment
> Charlie

If I understand well, you need a function to know the dimension of the 
displayed HTML text. This is a problem in Qt :-)

You can try to put your text in a TextView, and use the TextWidth and 
TextHeight properties. I'm not sure that it works in every case, because 
these values seems to be calculated by Qt the later possible, i.e. when the 
TextView had been displayed.

Regards,

-- 
Benoit Minisini
mailto:gambas at ...1...




More information about the User mailing list