最新评论

Re:IEnumerable, IEnumerator yanghe1117 2011-11-07 22:43  
nice
注意,(0,0)指的是矩形的左上角,(1,1)指的是矩形的左上角。所以颜色的渐变效果如下 ?
Re:IEnumerable, IEnumerator 小比丘 2011-05-31 11:06  
mark
Re:WPF自定义控件 崔鹏飞 2011-01-17 15:48  
刚才在一个空的项目模板里被ThemeInfoAttribute折磨了半天
Re:IFormatProvider接口 karies 2011-01-11 15:19  
写的很详细,只是代码的配色看着很晕
Re:显示不同Theme下WPF控件的Template 比尔锅盖 2010-11-21 16:08  
拿走了,谢谢~
Re:WPF放大镜程序-VisualBrush的使用 槑槑 2010-08-17 23:48  
好文..楼主08年就开始做WPF了啊,,,厉害...
Re:IFormatProvider接口 thestoryofsnow 2010-07-08 14:48  
很详细 很感谢
re: IEnumerable, IEnumerator hhh 2009-05-18 11:09  
bu cuo a
只有DependencyObject才能参与dependency property system,所以如果我们定义了一个类,它拥有自己的自定义的dependency property,则这个类必须继承自DependencyObject。
re: IEnumerable, IEnumerator 小狼狗 2009-02-18 14:29  
zheyang a
re: 寻找到DataTemplate中定义的元素 Bob-wei 2009-01-14 19:36  
我是说像这个:myContentPresenter.ContentTemplate.FindName("textBlock",myContentPresenter)
为什么要myContentPresenter.ApplyTemplate()后才能得到它FindName找到的对象。

re: 寻找到DataTemplate中定义的元素 cutebear 2009-01-14 18:57  
你能贴一段代码看看吗,我不是很清楚你的意思
re: 寻找到DataTemplate中定义的元素 Bob-wei 2009-01-14 09:38  
按道理使用 myContentPresenter.ContentTemplate.FindName("textBlock",myContentPresenter) 应该得到名称为 textBlock 的TextBlock(UIElement)对象,但是我在 ItemsControls 而不是 ListBox 中使用这种方法却得到一个错误:“此操作仅在应用此模板的元素上有效。”

myContentPresenter.ContentTemplate是存在的,它等于在资源中定义的DataTemplate,如果使用myContentPresenter.ContentTemplate.LoadContent() 方法还可以得到 DataTemplate 实例化后的根元素。

这种问题怎么解释??
re: WPF自定义控件 cutebear 2009-01-05 17:18  
这个网址打不开啊@Moli
re: WPF自定义控件 Moli 2009-01-03 01:18  
WPF学习论坛:http://wpf.5d6d.com
小小广告下,麻烦你啦~ ^_^~
re: WPF DataBinding cutebear 2008-11-27 15:27  
如何确定控件缺省的BindingMode:
One of the BindingMode values. The default is Default, which returns the default binding mode value of the target dependency property. However, the default value varies for each dependency property. In general, user-editable control properties, such as those of text boxes and check boxes, default to two-way bindings, whereas most other properties default to one-way bindings.
A programmatic way to determine whether a dependency property binds one-way or two-way by default is to get the property metadata of the property using GetMetadata and then check the Boolean value of the BindsTwoWayByDefault property.
例如:确定一个名称为myComboBox的ComboBox控件的SelectedItem属性是不是双向绑定的:((System.Windows.FrameworkPropertyMetadata)(ComboBox.SelectedItemProperty.GetMetadata(myComboBox))).BindsTwoWayByDefault
re: 今天挺开心 任力 2008-08-01 14:10  
欢迎欢迎~~~
一起努力喔
re: 今天挺开心 丁学 2008-08-01 14:10  
我也mark一下,哈哈,希望博主常来

导航

统计

公告