Maybe i'm doing something wrong but if i add a panel to a panel which is added to an activity (see code below) the the width of the "proddetailpnl" on a full HD tablet is still ~1920.
B4X:
Dim miniinfopnl As Panel
miniinfopnl.Initialize("miniinfopnl")
Activity.AddView(miniinfopnl, 10%x, 5%y, 20%x, 60%y)
proddetail.Initialize("proddetail")
miniinfopnl.AddView(proddetail, 0, 0, 100%x, 90%y)
Maybe someone can explain to me what i am doing wrong.:BangHead:
It would be simpler if you use a layout file. In that case you can load the layout file to the panel and %x / %y in the designer script will be related to the panel.
Alternatively, I have found the 'Designer Scripts' to be the best way to sort such issues out, because you can immediately check via the UI cloud what it will look like on a variety of devices. You then set all views relative to others, which makes things much easier. See the Designer Scripts tutorial here: http://www.b4x.com/forum/basic4andr...2522-designer-scripts-autoscale-tutorial.html
I'm just really curious why B4A behaves that way. It would make perfect sense for me if i add a view or whatever to a panel and the percent values are relative to the parent.