Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
Developer
Posts: 27
Registered: ‎12-02-2012
My Device: BB10
My Carrier: CMCC
Accepted Solution

Can i do some relative layout in QML?

For example:

Container {

    id: A

    ......

}

 

Container {

    id: B

    verticalAlignmen.Top: A.Bottom

}

Developer
Posts: 6,473
Registered: ‎12-08-2010
My Device: PlayBook, Z10
My Carrier: none

Re: Can i do some relative layout in QML?

Using the LayoutUpdateHandler I mentioned in the related post you just made, you could technically do something like this if you used AbsoluteLayout. There are probably better approaches, e.g. just using the standard StackLayout approach which handles the case you describe above directly.

Peter Hansen -- (BB10 and dev-related blog posts at http://peterhansen.ca.)
Author of White Noise and Battery Guru for BB10 and for PlayBook | Get more from your battery!
Highlighted
Developer
Posts: 27
Registered: ‎12-02-2012
My Device: BB10
My Carrier: CMCC

Re: Can i do some relative layout in QML?

Thanks again, peter!