What is Property Value Inheritance – XAML ?

When you created a new Windows Phone App , you would have noticed the following in the MainPage.XAML’s PhoneApplicationPage  element .

 FontFamily="{StaticResource PhoneFontFamilyNormal}"
 FontSize="{StaticResource PhoneFontSizeNormal}"
 Foreground="{StaticResource PhoneForegroundBrush}"

The above sample code is an example of the Property Value Inheritance which indicates the default appearance of the child elements of the page when these properties are not set on the element.

The child element (for example : TextBlock) defined in a Windows Phone Page uses the closest ancestor’s value if it is not defined .

Leave A Reply

Your email address will not be published. Required fields are marked *

You May Also Like

In this post, you will learn about sync provider notifications in Windows 11 and how to disable or enable it...
In this tutorial, let’s learn how to enable or disable the startup sound in Windows 11. By default, when Windows...
The CameraCaptureTask allows the Windows Phone 7 App to launch the Camera Application . This will be useful when the...