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: 202
Registered: ‎04-19-2011
My Device: Blackberry Bold 9780
My Carrier: TAM
Accepted Solution

is there any properties like USE_ALL_WIDTH or USE_ALL_HEIGHT

To developers,

I'm trying to create my app for cascade from java native sdk..

I want to ask about layout in cascade...

From my understanding : class container & layout in cascade = class manager in java

In java, manager can set its style with use_all_width or use_all_height...

What about in cascade? when i read cascade documentation, i found that layout can be set height or width using some integer value (it means absolute value). This is a bit dangerous if app can be tilt.

CMIIW

Developer
Posts: 18
Registered: ‎04-28-2012
My Device: Playbook & Dev Alpha
My Carrier: AIS

Re: is there any properties like USE_ALL_WIDTH or USE_ALL_HEIGHT

You can use spaceQuota property in StackLayoutProperties to do something like that.

Developer
Posts: 202
Registered: ‎04-19-2011
My Device: Blackberry Bold 9780
My Carrier: TAM

Re: is there any properties like USE_ALL_WIDTH or USE_ALL_HEIGHT

Thank you for your answer,

Can you explain more detail about spaceQuota?

Maybe in some sample code?

Developer
Posts: 150
Registered: ‎02-01-2009
My Device: Torch, PlayBook and Dev Alpha
My Carrier: SFR

Re: is there any properties like USE_ALL_WIDTH or USE_ALL_HEIGHT

Hi,

 

You can find more info about space quotas here (at bottom) :

 

https://developer.blackberry.com/cascades/documentation/ui/layouts/index.html

 

Nicolas

Developer
Posts: 21
Registered: ‎04-26-2012
My Device: BlackBerry 9800
My Carrier: BlackBerry

Re: is there any properties like USE_ALL_WIDTH or USE_ALL_HEIGHT

you can use layout properties to set Fill horizontally and Vertically.

 

Sample Code:

Container {
    layout: StackLayout {}
    layoutProperties: DockLayoutProperties {
        horizontalAlignment: HorizontalAlignment.Fill
        verticalAlignment: VerticalAlignment.Fill
    }

 

Developer
Posts: 202
Registered: ‎04-19-2011
My Device: Blackberry Bold 9780
My Carrier: TAM

Re: is there any properties like USE_ALL_WIDTH or USE_ALL_HEIGHT

Thank you for all the answer...

Now, i can layout my screen using both of space quota dan layoutProperties Fill atribute..