What's new in Microsoft Silverlight SDK 5.0.60401.0 Beta

Apr 14, 2011
  • Controls:
  • ItemsControl Search:
  • A user can now search a list of items in an ItemsControl using keyboard input. You can specify the property that identifies an item for search purposes by setting the TextPath attached property.
  • DrawingSurface:
  • DrawingSurface is a new control in Silverlight 5 Beta. DrawingSurface defines an area where 3-D content can be composed and rendered. You implement the rendering behavior through the event data of the Draw event.
  • Out-of-Browser:
  • You can display multiple Window instances in trusted, out-of-browser applications. This enables you to create non-modal dialog boxes, tear-off windows, and user-adjustable layouts that can span multiple monitors.
  • User Interface:
  • Detecting Double-Clicks:
  • Silverlight 5 Beta adds a ClickCount event data property to the MouseButtonEventArgs event data class. You can use this property to detect double-clicks, based on platform settings for the time duration that two clicks should be considered a double-click.
  • XAML:
  • Silverlight 5 Beta now has a MarkupExtension base class. By implementing the ProvideValue(IServiceProvider) method, you can define a custom markup extension, which can be understood and used by the Silverlight XAML parser. Services that are intended for markup extension service context enable several scenarios that were not possible in Silverlight 4 XAML. For example, it is now possible to implement a similar markup extension behavior to the x:Type markup extension from WPF XAML.
  • Certain structures that did not support an attribute syntax for setting their properties now support attribute syntax on properties. These structures are: CornerRadius, Thickness, Size, and Rect.
  • Data:
  • Data Binding
  • Silverlight 5 Beta enables you to debug data bindings by setting breakpoints on bindings in XAML. When a breakpoint is hit, you can use the Locals window to examine the state of a binding and identify any issues. For more information, see Data Binding.
  • Silverlight 5 Beta also includes several data binding enhancements, some of which were previously available only in Windows Presentation Foundation (WPF). These enhancements enable you to do the following:
  • Use data bindings with styles. To do this, use the Setter..::..Value property as a binding target. You will typically do this in XAML using the binding markup extension.
  • Bind to ancestors in the visual tree. To do this, set the Binding..::..RelativeSource property to FindAncestor.
  • Associate bound objects to data templates implicitly by type instead of explicitly by template name. To do this, set the DataTemplate..::..DataType property for each implicit template instead of specifying x:Key values.
  • Bind to dynamically-generated properties. To do this, implement the ICustomTypeProvider interface on classes with dynamic properties.
  • Application Model:
  • Silverlight 5 Beta includes the following enhancements for trusted applications:
  • Trusted applications can now access the local file system without restriction.
  • Out-of-browser trusted applications can create multiple Window instances.
  • System administrators can enable trusted applications to run inside the browser, simplifying enterprise deployment and application updates. This also enables you to use some previously out-of-browser-only features inside the browser, including the WebBrowser and NotificationWindow classes.
  • Media:
  • 3D Graphics:
  • Silverlight 5 Beta introduces the ability to use hardware accelerated 3D graphics in your Silverlight applications. This opens up a whole new set of scenarios that are possible in Silverlight, such as 3D drawn controls, data visualizers, 3D charts, scatter points, geographic overlays, and 3D games and simulations.
  • The core of the XNA Games Studio 4.0 graphics libraries is now included in Silverlight 5 Beta. Developers familiar with XNA will be able to quickly get up to speed with Silverlight 3D graphics programming.
  • Text:
  • Character Spacing:
  • Silverlight 5 Beta includes the ability to increase or decrease the amount of space in between characters in text. You can do this by using the CharacterSpacing property available in the Control, TextBlock, and TextElement classes.
  • Inter-line Spacing:
  • Silverlight 5 Beta enables you to increase or decrease the space between lines of text to increase readability or to change the look and feel of the body of text. You can do this by using the LineHeight and LineStackingStrategy properties available in the Block, TextBlock, TextBox, and RichTextBox.
  • Display Overflow Content in RichTextBox:
  • In Silverlight 5 Beta, you can display the content that does not fit in a RichTextBox in a RichTextBoxOverflow control.