JoeGeeky
JoeGeeky

Reputation: 3796

Adding a line break to a Windows Phone 7 App Title on the Live Tile

By default Windows Phone 7 (WP7) will render the applications <Title /> over the ApplicationIcon when pinned to the start screen. In my case, my title needs two lines to fully render.

Given the following WP7 App configuration as an example, is there any mechanism for inserting a line break in the application <Title /> and having it show a two line title on the Live Tile?

I've tried using the \n\r pattern as well as the encoded version &#13;&#10;. When using the encoded pattern, it appears as though the line break may actually be working but I still cannot see the second line.

<Deployment xmlns="http://schemas.microsoft.com/windowsphone/2009/deployment" AppPlatformVersion="7.0">
  <App ...>
    <Tokens>
      <PrimaryToken TokenID="AToken" TaskName="_default">
        <TemplateType5>
          ...
          <Title>Hello&#13;&#10;World</Title>
        </TemplateType5>
      </PrimaryToken>
    </Tokens>
  </App>
</Deployment>

Upvotes: 0

Views: 879

Answers (2)

Tom Verhoeff
Tom Verhoeff

Reputation: 1270

The Title tag for WP7 tile does not support a multi-line title. Your only choice is to insert the title in your tile design and give the title tag no content. Take this into account: - Background.png in your application root is the image used as a tile when pinning the application - Best practice is to give your logo and text a white color and the rest of the picture transparent. This will make your tile theme-aware. If you do this correctly people should not notice any difference with regular tiles apart from the double line

Good luck with implementing this. It would be great if you could share your final tile so other people facing this problem can use it for future reference.

Upvotes: 1

Chris Koenig
Chris Koenig

Reputation: 2748

I tried this too and don't think this is possible using the "traditional" technique of settting the title via the XML. I think you're best option is to use a custom background image that includes your multi-line title, formatting it's layout just the way you want it, then remove the tag from the XML configuration file all together. I've used this technique successfully with Push Notififcations on 7/7.1 and Local Tile Updates on 7.1.

Upvotes: 3

Related Questions