[Gambas-user] how to detect resize of fmain?

Bruce Steers bsteers4 at gmail.com
Thu Mar 30 21:26:45 CEST 2023


On Thu, 30 Mar 2023, 20:21 , <roberto.premoli at tiscali.it> wrote:

> hello,
> I have some graphical elements (button, textarea, ecc) that are placed in
> some point of a main window: a button in top right corner, a text in the
> middle... you get the point.
> to place element i do as follow:
> button1.x= fmain.width - button.width
> textarea.x = fmain.width / 2
> textarea.y = fmain.height / 2
>
>
> the problem is that whet i maximise window or when resize the window
> moving the corner wth the nouse, the graphic element stay where they are:i
> stead i wist they get new position as far as fmain.widh amd fmain.height
> change.
>
> I wish to white a routine that replace all the elements, but i still not
> understood what is the trigger that i can notice me that fmain.height and
> fmain.widht are changed.
>
> Roberto
>

Look at From events in the wiki.

Did you know there is help about things like forms. You can read the help
and see what's possible in the gambas wiki .

Also when you type
Public Sub Form_

you will see a list of all form events.

Form_Resise event

Form_State event.



>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20230330/ca97eef0/attachment.htm>


More information about the User mailing list