Exploring the PlayBook application’s blackberry-tablet.xml

Posted on January 20, 2011 | 23 comments

UPDATE: RIM has provide documentation on the blackberry-tablet.xml located here.

With the release of the BlackBerry Tablet OS SDK for Adobe AIR Beta 3 (0.9.2) developers have access to a new PlayBook application descriptor file called “blackberry-tablet.xml”. This file has to be named exactly “blackberry-tablet.xml” and be placed in the root of the application structure, basically along side the AIR typical Xxxx-app.xml descriptor file.

I created a simple example application (BlackBerryTabletXMLOptions) that displays a smiley face image to the screen to talk about a couple of the attributes in the blackberry-tablet.xml file.

Here is what the application looks like:

Smiley Face App

You might be wondering how I got an application to show up over the main interface of the PlayBook. Well lets take a look at the blackberry-tablet.xml:

  <publisher>Renaun Erickson</publisher>

What makes this work is the “transparent” attribute set to true. This allows your application to render transparently over the main interface of the playbook. The other attributes in the xml file to call out are “category”, “icon.image”, and “splashscreen”. First the category allows you to set the values: core.media, core.internet, core.games, and core.utils. This category value is used to place the application and its custom icon defined in the xml above in the application categories that show up on the main screen of the PlayBook. See below that the BBTabletXMLOptions application is installed in the Media category area.

Application in Media Category

The splashscreen is the last attribute that is in this application. It takes a 1024×600 image that is shown before the application is activated.

  • Alan

    Thanks for the write up. PlayBook looks like an interesting platform for Flash development. Whatever info you can provide about the platform is much appreciated.

  • http://unitedmindset.com/jonbcampos Jonathan Campos

    So how do you include this xml in your command line build? is there another argument you need to use or just include this path after the application descriptor?

  • http://www.renaun.com Renaun Erickson

    Just add it so the blackberry-tablet.xml is added to the zipped up app, like adding icons. so something like ./blackberry-airpackager -package MyApp.bar -installApp -launchApp MyApp-app.xml MyApp.swf blackberry-tablet.xml myicon.png -device

  • http://peterhansen.ca Peter Hansen
  • http://www.yacafx.com yacaFx

    how can i do for display my app on two categaries?? for example i like my app shows under internet and media… just i add anothes categorie tag at xml descriptor file??

    • http://www.renaun.com Renaun Erickson

      I am not sure, I haven’t found any examples of this and do not know if its will be a limitation.

  • http://digiflare.com Mukul Seth

    Hi Renaun,

    Thanks for this piece of information. I was wondering if there is a way to set a different splash screen image for different orientations. I’ve set the default for Landscape, but it get horribly stretched when I launch in Portrait mode.

    • http://www.renaun.com Renaun Erickson

      Not at this time.

  • http://chall3ng3r.com chall3ng3r

    Hi Renaun,

    Thanks for sharing this info. I have one question.

    Do I still need to specifiy icon in app.xml file if I specifiy icon blackberry-tablet.xml?


    // chall3ng3r //

    • http://www.renaun.com Renaun Erickson

      You do not need to set the icon file in the app.xml

      • http://www.chall3ng3r.com chall3ng3r

        Thanks. My first app is almost ready :)

        // chall3ng3r //

  • http://www.globaltv.com Paul Bradley

    Is it possible to turn off scaling when the Playbook is rotated from landscape to protrait?

    I am using the 9.3 SDK and setting:

    stage.scaleMode = StageScaleMode.NO_SCALE;

    But the stage still scales when rotated.

    • http://www.renaun.com Renaun Erickson

      Seems to be a simulator bug. I can confirm the scaling in the sim and will double check later.

    • http://www.globaltv.com Paul Bradley

      I found the answer on the Blackberry forums.

  • http://www.thogek.com/ Thogek

    Cool stuff.
    Any idea how to do this same thing with the WebWorks API?

    • http://www.renaun.com Renaun Erickson

      Not sure about WebWorks, I let u know if I find something out

  • http://www.thogek.com/ Thogek

    Also, is there documentation outlining all of the options supported by the blackberry-tablet.xml file? (Seems like there must be, but I’m having trouble finding any…) Thanks!

    • http://www.renaun.com Renaun Erickson

      No there is not detail information on all the options available in blackberry-tablet.xml at this time.

      • http://www.thogek.com/ Thogek

        Sigh. That’s going to make troubleshooting the thing rather hit-and-miss.

  • Brian

    Thanks for this info. The config info is now posted here: http://bit.ly/fdelw6
    But under “Splashscreen” is says: “The screen resolution of the BlackBerry® PlayBook™ tablet is 1200 by 600 pixels. Your splash screen should be this size to fill the screen.”

    But everywhere else — including here — it says the screensize is 1024×600.

    • http://www.renaun.com Renaun Erickson

      If you write some code and test it in the simulator it says the screen res is 1024×600. I would assume that the 1200×600 is a typo in the docs.

      Capabilities.screenResolutionX + " - " + Capabilities.screenResolutionY

  • Gadi

    i am trying to see how a PlayBook app can register to be opened through an http link. I know there’s the allowBrowserInvocation value in the -app.xml file, but where do we have to write the url type that the app deals with? any post on this, by any chance?

    • Anonymous

      Sorry don’t have any info on this question.