1

I want to make page background fully transparent in blackberry 10 cascades. How can i do this ??

I tried with following code but it is not working..

Page {
    Container {
        layout: DockLayout {}

        Label {
            text: qsTr("Hello World")
            textStyle.base: SystemDefaults.TextStyles.BigText
            verticalAlignment: VerticalAlignment.Center
            horizontalAlignment: HorizontalAlignment.Center
        }
        opacity : 0
        preferredWidth: 780.0
        preferredHeight: 1280.0
    }

}

Thanks

Sanket
  • 3,094
  • 1
  • 16
  • 19

2 Answers2

2

Try:

background: Color.Transparent

in your container.

barry
  • 4,037
  • 6
  • 41
  • 68
  • Are you sure? Since it is transparent you would see what ever is behind it, probably the application global background color. Your bar descriptor file should have a check box for transparent main window. I haven't tried that but maybe that's what you're looking for. – Richard Jun 13 '13 at 13:36
  • No the above code is used for container. The question is asked for Page transparency. So only the possible way is to make it as a dialogue and set that dialogue's main container as background: Color.Transparent – pranavjayadev Jan 22 '14 at 13:23
2

You can't make a Page transparent. Your best bet is to put your content in a Dialog, and set its opacity to 0. This will give you a full screen overlay over the current page.

http://developer.blackberry.com/cascades/reference/bb_cascades_dialog.html

Scott
  • 552
  • 3
  • 7