Determine where a style comes from? RRS feed

  • Question

  • In the HTML/CSS world that I'm used to, I can use Chrome to inspect an item on my page and find out exactly where a given property (colour etc), is being styled from. I can't find a way to do this in XAML? It's just that StandardStyles.xaml is considerably multi layered (lots of "BasedOn"), in the same way CSS often is. I feel like I want to be able to click on a styled property in an item and be able to navigate to the Style where it is being set. Can I do this?

    Specifically in this instance, I'm trying to replace all the grey around the app that seems to come with the wizard grid app. The background of my icons, splashscreen, grid items etc.. But I can't figure where it's coming from.


    • Edited by ThatAndyT Saturday, December 15, 2012 10:08 AM
    Saturday, December 15, 2012 9:59 AM

All replies

  • In the Wizard grid app tiles are getting colors because they are referring to images that are present in the asset folder.

    If you observe DataModel/SampleDataSource.CS in the constructor(SampleDataSource()) they are creating sample data item objects whose fourth parameter is the path of the image for that particular item. Each sample data item is added to a sample data group so you can change the colors of the tiles or you can replace them with your own images by changing the fourth parameter of the sample data item.

    2. if you observe the StandardStyles.xaml present in "common" folder of the solution there is a data template "Standard250x250ItemTemplate" present there you can change the title and subtitle which is present on the tile.

    3.if you observe the package.appxmanifest in the application go to applicationUI tab there you can observe the background color property. By modifying the value there you can change the splash screen color.


    Raja KPV


    • Proposed as answer by Raja KPV Wednesday, December 19, 2012 2:34 PM
    Monday, December 17, 2012 1:05 PM