The new development platform for so-called Metro apps is called WinRT, short for Windows Runtime. Its name suggests its potential future place as the principal runtime library for Windows. Developers who have already embraced the .NET Framework may find themselves shifting positions to make room.
WinRT is not the replacement for .NET. However, as Microsoft Windows engineer Ale Hole?ek told a press gathering at Build 2011 in Anaheim, it will present a new foundation for an alternative app model for Windows that Microsoft will promote as the modern style of Windows development.
As RWW saw in demonstrations here this week, Metro apps designed to be integrated with Windows 8’s new Start Screen can be developed without .NET and without XAML, using CSS and HTML5 instead. (Whether the word “pure” applies to either one will be determined by testing.) Although this Web-oriented model utilizes Internet Explorer libraries for rendering, these apps don’t appear in the browser itself. Like Silverlight apps, Metro HTML5 apps can stand alone, as can Metro XAML apps.
But Silverlight itself starts to play less of a factor, as WinRT takes over the role of providing system services to the application. Silverlight has been Microsoft’s initial effort to produce a subset of the .NET Framework that could conceivably be deployed cross-platform, though it’s fallen to the shoulders of open source developers such as Miguel de Icaza to do it for Linux and Mac.
var, then the variable name and
=, followed by
new and the library root name
As Hole?ek made clear, Silverlight is not going away. His prophetic statement, “We will preserve all of their investments,” referring to developed Silverlight apps, does indicate it might not be going very far forward.
Engineers showed that future tools will enable developers to endow existing Silverlight apps with a coat of paint, if you will, giving them a Metro-like style. But that’s as far as it goes – “Metro-like.” The jump from Silverlight to WinRT (if it’s worth doing rather than just starting over) requires a rewiring of existing apps. The reasons are technical, though perhaps unyielding: 1) The namespaces required by Silverlight and Metro apps are different, by virtue of Metro’s reliance upon WinRT; 2) Silverlight relies on the browser (IE) to provide networking code, while WinRT relies on underlying system services; 3) Silverlight assumes the browser is present but invisible, so it still sends navigation commands to IE, while WinRT manages navigation through system methods.
Microsoft continues to work with the W3C standards agency, he added, to integrate new controls such as the “grid” and “flex-box” used in Win8, into HTML5. The company is instrumental, he said, in helping to evolve HTML5 with services such as secure local storage and WebSockets for asynchronous communication.
But the one certain way Microsoft can prevent WinRT from being used by a Web-based app to mock a system service or device driver, the engineer said, was to simply prevent WinRT from being used for these purposes. There will be no WinRT-based device drivers. That may make it difficult for device driver makers to implement contracts, to invoke the new term, for the new Settings menu in Metro. Difficult but not impossible, as Microsoft demonstrated one working Print Preview app in Metro, built by HP.