round brackets in xaml syntax

后端 未结 1 1615
粉色の甜心
粉色の甜心 2021-02-09 05:38

when I\'m using ColorAnimation to change Background of control i\'m using following syntax:



        
1条回答
  •  不知归路
    2021-02-09 06:03

    Please see PropertyPath XAML Syntax:

    The parentheses indicate that this property in a PropertyPath should be constructed using a partial qualification. It can use an XML namespace to find the type with an appropriate mapping. The ownerType searches types that a XAML processor has access to, through the XmlnsDefinitionAttribute declarations in each assembly. Most applications have the default XML namespace mapped to the http://schemas.microsoft.com/winfx/2006/xaml/presentation namespace, so a prefix is usually only necessary for custom types or types otherwise outside that namespace. propertyName must resolve to be the name of a property existing on the ownerType. This syntax is generally used for one of the following cases:

    • The path is specified in XAML that is in a style or template that does not have a specified Target Type. A qualified usage is generally not valid for cases other than this, because in non-style, non-template cases, the property exists on an instance, not a type.

    • The property is an attached property.

    • You are binding to a static property.

    0 讨论(0)
提交回复
热议问题