[Gambas-user] vertical autoresize of a label
T Lee Davidson
t.lee.davidson at gmail.com
Sat Dec 16 15:49:45 CET 2023
On 12/15/23 23:38, roberto.premoli at tiscali.it wrote:
> hello,
> i have some texts (different size) to display.
> i put them into the same label as soon as i need to display them, and i set label.autoresize = true
> to make it resize to allow the label to show all the text.
>
> the problem is that resize change the .width, but i need orizontal size to be fixed: what I wanto to change is the
> it the vertical size, the .height.
AutoResize will adjust both the height and the width. If you need the width fixed, then set AutoResize to false and change the
height in your code. Perhaps with something like this:
Label1.Height = Label1.Font.Size + 10
--
Lee
More information about the User
mailing list