随笔分类 -  wpf

摘要:public IEnumerable GetOpenPopups() { return PresentationSource.CurrentSources.OfType() .Select(h => h.RootVisual) ... 阅读全文
posted @ 2015-09-09 14:42 法的空间 阅读(240) 评论(0) 推荐(0) 编辑
摘要:最近ms 更新对WPF支持,http://blogs.msdn.com/b/dotnet/archive/2014/11/12/the-roadmap-for-wpf.aspxWork on improving WPF has never really stopped, and bel... 阅读全文
posted @ 2014-11-15 14:47 法的空间 阅读(298) 评论(0) 推荐(0) 编辑
摘要:最近美国的PM传来消息,说微软在收集开发者的意见,会对WPF进行改进,微软会主要在1) performance 2) interop 3) touch and 4) access to WinRT APIs这4个方面有所改进。期待微软在下一个framwork中能给我们带来一些惊喜吧? 阅读全文
posted @ 2014-10-30 23:22 法的空间 阅读(237) 评论(0) 推荐(0) 编辑
摘要:最近看到一个bog.http://www.codeproject.com/Articles/818281/Is-WPF-dead-the-present-and-future-of-WPF大体上讲了一下WPF的现状,其实我们从微软的最近的态度也能看出些什么,微软在把精力都转移到了WINRT上面... 阅读全文
posted @ 2014-09-30 22:28 法的空间 阅读(217) 评论(0) 推荐(0) 编辑
摘要:[DllImport("user32.dll")]publicstaticexternIntPtrGetAncestor(IntPtrhWnd,intflags);vardialog=newCustomiDalog(); window=newWindow();window.Content=dialo... 阅读全文
posted @ 2014-05-22 11:14 法的空间 阅读(912) 评论(0) 推荐(0) 编辑
摘要:—目的 如果要在XAML里引用静态或动态对象实例,或在XAML中创建带有参数的类。这时,我们需要用到XAML扩展。XAML扩展常用来设定属性值。使用标识扩展,告诉 XAML 处理不要像通常那样将属性值视为文本字符串,而是通过类型转换把字符串转换为静态或动态实例。—格式 当XAML编译器看到大括号{}时,把大括号中的内容解释为XAML标记扩展。 如: 有两个标识扩展,一个是Binding标识扩展,一个是StaticResource扩展。—说明 1、标记扩展本身是一系列类,其基类为MarkupExtension(抽象类)。 2、从这个类中派生出十二个类,即:ResourseKey、 TypeEx. 阅读全文
posted @ 2013-08-27 10:59 法的空间 阅读(422) 评论(0) 推荐(0) 编辑
摘要:View Code xaml public class WaterMarkTextBox:TextBox { public string Watermark { get { return (string)GetValue(WatermarkProperty); } set { SetValue(WatermarkProperty, value); } } // Using a DependencyProperty as the backing store fo... 阅读全文
posted @ 2013-08-09 09:32 法的空间 阅读(429) 评论(0) 推荐(0) 编辑
摘要:(_S) View Code 阅读全文
posted @ 2013-08-02 10:50 法的空间 阅读(254) 评论(0) 推荐(0) 编辑
摘要:void mydataGird_MouseDoubleClick(object sender, MouseButtonEventArgs e) { Point aP = e.GetPosition(mydataGird); IInputElement obj = mydataGird.InputHitTest(aP); DependencyObject target = obj as DependencyObject; int i = 0; while (target !... 阅读全文
posted @ 2013-07-13 23:22 法的空间 阅读(771) 评论(0) 推荐(0) 编辑
摘要:/// /// AutoCompleteComboBox /// public class AutoCompleteComboBox : ComboBox { #region DependencyProperty public string WaterMark { get { return (string)GetValue(WaterMarkProperty); } set { SetValue(WaterMarkProperty, value); } } ... 阅读全文
posted @ 2013-07-10 19:39 法的空间 阅读(329) 评论(0) 推荐(0) 编辑
摘要:xaml View Code csusing System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Windows;using System.Windows.Controls;using System.Windows.Data;using System.Windows.Documents;using System.Windows.I... 阅读全文
posted @ 2013-07-07 12:22 法的空间 阅读(604) 评论(0) 推荐(0) 编辑
摘要:... 阅读全文
posted @ 2013-07-04 19:18 法的空间 阅读(226) 评论(0) 推荐(0) 编辑
摘要:View Code 阅读全文
posted @ 2013-07-01 22:34 法的空间 阅读(249) 评论(0) 推荐(0) 编辑
摘要:4.0里面不支持Generic.xaml里面 嵌套style4.5里面可以使用。可以在app.xaml 阅读全文
posted @ 2013-06-29 10:08 法的空间 阅读(399) 评论(0) 推荐(0) 编辑
摘要:this.Template = XamlReader.Load (" "); 阅读全文
posted @ 2013-06-29 00:34 法的空间 阅读(221) 评论(0) 推荐(0) 编辑
摘要:。(button使用contont写的时候) 当。button使用 依然会覆盖这段代码能消除全局textblock对button的影响 View Code textblock style这样。。b... 阅读全文
posted @ 2013-06-29 00:32 法的空间 阅读(1044) 评论(1) 推荐(0) 编辑
摘要:using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Windows.Controls;using System.Windows;using System.Windows.Input;namespace MyWPFCustomControls{ public class CustomTextBox : TextBox { public CustomTextBox() { } static Cu... 阅读全文
posted @ 2013-06-22 00:28 法的空间 阅读(314) 评论(0) 推荐(0) 编辑
摘要:<Grid Grid.Row="3" Grid.ColumnSpan="3"> <Grid.Resources> <SolidColorBrush x:Key="BackgroundColor" Color="#00000000"/> <SolidColorBrush x:Key="ForegroundColor" C... 阅读全文
posted @ 2013-05-30 15:47 法的空间 阅读(210) 评论(0) 推荐(0) 编辑
摘要:见文件 阅读全文
posted @ 2013-05-30 10:25 法的空间 阅读(119) 评论(0) 推荐(0) 编辑
摘要:csusing System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Threading.Tasks;using System.Windows;using System.Windows.Controls;using System.Windows.Media;namespace MCE.Gems.Common.Controls.CustomControls{ /// <summary> /// change textblock background color 阅读全文
posted @ 2013-05-25 17:42 法的空间 阅读(368) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示