惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

P
Privacy & Cybersecurity Law Blog
Vercel News
Vercel News
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
N
Netflix TechBlog - Medium
罗磊的独立博客
F
Fortinet All Blogs
T
Threatpost
Y
Y Combinator Blog
博客园_首页
美团技术团队
Security Latest
Security Latest
博客园 - 三生石上(FineUI控件)
T
Tailwind CSS Blog
V
V2EX - 技术
The Cloudflare Blog
L
LINUX DO - 热门话题
博客园 - 司徒正美
Jina AI
Jina AI
P
Proofpoint News Feed
宝玉的分享
宝玉的分享
C
CXSECURITY Database RSS Feed - CXSecurity.com
C
Cybersecurity and Infrastructure Security Agency CISA
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
WordPress大学
WordPress大学
The Hacker News
The Hacker News
P
Privacy International News Feed
T
The Exploit Database - CXSecurity.com
Scott Helme
Scott Helme
有赞技术团队
有赞技术团队
V
V2EX
Stack Overflow Blog
Stack Overflow Blog
M
MIT News - Artificial intelligence
Latest news
Latest news
NISL@THU
NISL@THU
Google DeepMind News
Google DeepMind News
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
C
Cisco Blogs
雷峰网
雷峰网
Application and Cybersecurity Blog
Application and Cybersecurity Blog
B
Blog RSS Feed
W
WeLiveSecurity
D
DataBreaches.Net
G
Google Developers Blog
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
G
GRAHAM CLULEY
Spread Privacy
Spread Privacy
Know Your Adversary
Know Your Adversary
TaoSecurity Blog
TaoSecurity Blog
S
Securelist
Help Net Security
Help Net Security

博客园 - 紫色永恒

一段旅程的结束和另一端旅程的开始 Silverlight Client←→Server数据同步备忘代码 Expression Blend 5 Preview For Silverlight5 RC已发布 Siverlight5新功能/改进总结 [译]WCF RIA Services中的集合(2) [译]WCF RIA Services中的集合(1) Silverlight通过MVVM实现多语言实时切换(含源代码) Silverlight中服务通信方式的选择(WCF、Data Service、Ria Service) 记录来敦煌一周的情况 Silverlight奇技银巧7 - 巧用文件生成时间强制客户端载入最新xap文件 [ASP.NET MVC3]Chart的ActionResult扩展 如何将ASP.NET MVC2项目升级到MVC 3 RC Silverlight 4 GDR 1 更新 Silverlight奇技银巧6 - UserControl的继承 Silverlight 4 Training Kit更新 - 紫色永恒 Silverlight4的DataGrid改进与Toolkit2010.4中的新玩意 - 紫色永恒 Win03+IIS6部署.NetFramework4(ASP.NET4)的一点小经验 - 紫色永恒 4.13 Silverlight4 Will Come Silverlight4RC的API汇总(文本文件) - 紫色永恒
你应该知道的,那些未在Silverlight5Beta中出现的特性
紫色永恒 · 2011-04-26 · via 博客园 - 紫色永恒

距离Silverlight5(beta)华丽丽的亮相已经有一段日子了,园子里也有同道陆续放出了beta版中新玩意的体验和介绍,比如乱世经典这些文章,估计大家早也已经对beta版sl5带来的新特性了然于胸了。

而这篇文章的目的则是要向大家介绍一下那些没有赶上beta版末班车却又让我们“魂牵梦绕”的sl5新特性。废话少说,且听我一一道来。

  • DataContextChanged事件

顾名思义,当DataContext发生变化时将会触发该事件。现在sl的fans不用再羡慕wpf的这个事件了吧。不过话说回来,其实sl的FrameworkElement本来是提供了这个事件的,不过因为被标记为internal而一直无法使用。

来看一下示例代码:

this.DataContextChanged += View_DataContextChanged;
void View_DataContextChanged(object sender, 
                  DependencyPropertyChangedEventArgs e) {
    INotifyPropertyChanged customer;
    customer = e.OldValue as INotifyPropertyChanged;
    if (customer != null)
        customer.PropertyChanged -= customer_PropertyChanged;

    customer = e.NewValue as INotifyPropertyChanged;
    if (customer != null)
        customer.PropertyChanged += customer_PropertyChanged;
}

DependencyPrpertyChangedEventArges有三个属性NewValue、OldValue及Property。利用这个事件我们更好处理引用提高内存使用效率。

  • UpdateSourceTrigger新增了对PropertyChanged的支持

这个很有意义啊,人家WPF早就有这玩意而且在TextBox控件上是默认的UpdateSourceTrigger,而之前的sl就像个后娘养的…现在好了,做双向绑定的时候可以不再郁闷了。

  • 增强了文字清晰度

在之前的版本中,文字的清晰度一直备受怨念。不过微软说sl5中会提高文本与像素图像捕捉并为小型的阅读设备提供更好的体验。官方ppt中提供了下面这几张老图(当年介绍wpf4时候用过的),这是否代表我们暂且可以认为sl5最起码会做到wpf4的程度?

image

image

image

  • 矢量打印

如果让诸位用一个流行的词形容当前sl的打印功能,你们会想到什么?没错,就是“坑爹”。我们都知道,当前sl打印是基于bitmap(位图)的,而位图打印的两大缺陷则分别为占地面积大和缩放会照成很大损失。让我们看一些位图和矢量图的性能、容量、缩放清晰度对比

image

image

image

好吧,我想你懂的,这就是为什么矢量打印在sl5的wishlist中占据那么高的位置的原因。

  • Trick Play

这个东西我不大清楚,还望对媒体播放及TrickPlay有所了解的兄弟解惑。

暂时就这些吧,Silverlight5正式版将在2011年下半年登场,不过上文中提到的这些新特性会提前出现在Silverlight5的RC版中也是说不定的事哦~