Search code examples
qmlblackberry-10cascadeblackberry-cascades

Make a page background transparent in cascades


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


Solution

  • 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