I noticed that the panes anchored inside a pane and not only the panes but also objects such as buttons, labels etc etc if they are inside a panel which in turn and in the main panel have no effect. Is this behavior correct?
I tried not to put anchor on the parent panel or put it and the same thing, it seems that the daughter anchors don't work.
For me, the parent and child panel anchors work well when I use the designer.
When the parent position is declared in the script, then child panel anchors do not work on parent panels.
For me, the parent and child panel anchors work well when I use the designer.
When the parent position is declared in the script, then child panel anchors do not work on parent panels.
the objects on the parent panel are fine, but except if inside the parent panel you have other panels and its objects, look at my image, those child panels and profile objects have no effect either with anchor or with anything except through code.
For example, if I size the child panel then the objects resize, otherwise they are as if they don't have it yet even if they have it. and I did everything as a designer.
this is an example where I resize panel 1 to see panel three below, in panel one there is panel 2 with its button and panel 1 has its button
I don't have to shrink the window but reposition the parent panel to see an underlying panel, and in this case the panel does not inherit the parent's anchors
this is an example where I resize panel 1 to see panel three below, in panel one there is panel 2 with its button and panel 1 has its button
I don't have to shrink the window but reposition the parent panel to see an underlying panel, and in this case the panel does not inherit the parent's anchors
the truth is that they are not taken into consideration, because if I model the window with the classic resize method they work
B4X:
Private Sub Button1_Click
' If Pane1.PrefWidth >= 580 Then
' Pane1.Left = Pane1.Left + 200
' Pane1.PrefWidth = Pane1.PrefWidth - 200
' Else
' Pane1.Left = Pane1.Left - 200
' Pane1.PrefWidth = Pane1.PrefWidth + 200
' End If
If Main.MainForm.WindowWidth >=600 Then
Main.MainForm.WindowWidth = Main.MainForm.WindowWidth-200
Else
Main.MainForm.WindowWidth = Main.MainForm.WindowWidth+200
End If
End Sub