[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: TextLabel vanishes when resized
[Thread Prev] | [Thread Next]
- Subject: Re: TextLabel vanishes when resized
- From: 066ce286@xxxxxxx
- Date: Fri, 9 May 2025 13:02:12 +0200 (CEST)
- To: user@xxxxxxxxxxxxxxxxxxxxxx
BTW the TextLabel does not vanish anymore, with the same code. Maybe yesterday I should have restarted Gambas. ----- Mail original ----- > De: "Bruce Steers" <bsteers4@xxxxxxxxx> > À: user@xxxxxxxxxxxxxxxxxxxxxx > Envoyé: Vendredi 9 Mai 2025 11:46:41 > Objet: Re: TextLabel vanishes when resized > > On Fri, 9 May 2025 at 10:37, < 066ce286@xxxxxxx > wrote: > > > Hi, > > I'm trying to make a status bar with a [Text]Label. > > I resize it on the Form_Resize() event. > > Everything runs fine if 3statusBar" is a Label. But if it is a > TextLabel it just vanishes. > > Any hint ? > > (Gambas 3.20.3 ) > > Public Sub Form_Resize() > StatusBar.Width = Me.Width > StatusBar.Y = Me.Height - StatusBar.Height - 32 > StatusBar.X = 0 > 'Print "Status X/Y" & StatusBar.X & " / " & StatusBar.Y & " " & > StatusBar.Width & " x " & StatusBar.Height > 'StatusBar.Text = "Status X/Y" & StatusBar.X & " / " & StatusBar.Y & > " " & StatusBar.Width & " x " & StatusBar.Height & " computed Y=" & > (Me.Height - StatusBar.Height - 32) > End > > > Maybe the textlabel becomes too small to show the default html text > size? > > > I would not try to adjust it's height/width manually and just set > .AutoResize to true on the TextLabel > Then just use.. > StatusBar.Y = Me.Height - StatusBar.Height - 32 > > > > Respects > BruceS >
Re: TextLabel vanishes when resized | Bruce Steers <bsteers4@xxxxxxxxx> |