我有一个控件,我想把一个颜色绑定到它自己的类中的普通属性。
但它无法工作?有什么线索吗?
我有这个
public Brush SeperatorColour
{
get { return (Brush)GetValue(SeperatorColourProperty); }
set { SetValue(SeperatorColourProperty, value); }
}
// Using a DependencyProperty as the backing store for SeperatorColour. This en
如果我定义了一个用户控件:
public partial class MainFooter : UserControl
{
public System.Windows.Media.Color BkColor;
}
它是xaml:
<UserControl x:Class="Test.MainFooter">
<Grid x:Name="LayoutRoot">
<Rectangle x:Name="rctBottom_Background2"
Ho