Developing For Metro – WinRT: The Metro API

So far we’ve talked about Metro from the end-user perspective where indeed it is a style and a UI. But Metro isn’t a way to display existing Windows application, it’s what results from a new development model for writing applications. Metro, as the user sees it, is the result of the APIs and design guidelines developers follow in creating Metro applications.

With Windows 8 Microsoft will be introducing a new API: Windows RunTime (WinRT). Over the years much has been said about replacing Microsoft’s long-lived Win32 API, with some success. The .Net Framework supersedes Win32 to some extent, but at the end of the day Win32 is still significantly used in one way or another by many developers. WinRT is the API that will replace Win32 for application developers, and is the API developers will need to use to develop for Metro.

WinRT in a nutshell is a combination of the elements needed to make Metro work, along with subsets of features from Win32, COM, .Net, and HTML5/CSS3. As with pure .Net applications, WinRT applications are meant to be architecture agnostic, and ideally Microsoft would like developers writing applications in runtime or interpreted languages such as C#, VB, HTML5/CSS/JavaScript, and even Silverlight. C and C++ will be able to access Metro too, although there’s still some ambiguity about under which conditions those will be architecture agnostic. In any case WinRT – and thereby Metro – will be accessible from virtually every language Microsoft supports today in their Visual Studio IDE. And regardless of the underlying language, all Metro applications will behave like first-class applications.

With all of this talk about WinRT, Microsoft went through great lengths to reiterate that developers will continue to have access to older APIs for new applications and that Windows 8 will run everything that Windows 7 can run. This is both because traditional/desktop styled applications will not be going away any time soon, and because WinRT as it stands is for user-facing applications, not device drivers, services, or other backend code. In fact desktop applications will be supported indefinitely (look at how long support for 16bit Windows applications has continued to last), but Microsoft clearly wants developers developing for Metro whenever possible, and not for the desktop. For a great many applications this makes sense, but I’m not sure anyone really understands what this means for specialty applications like 3dsMax, Adobe Photoshop, and other workhorses that not only have large legacy codebases, but whose usage model doesn’t easily flow with Metro.

 To entice application developers to use WinRT and Metro, Microsoft will be using a carrot and a stick. The carrot will be the Windows Store, the stick is that non-Metro APIs will not be available for ARM. ARM is Metro-only from day one, and the Windows Store will be the enforcer (more on that later). So if developers wish to target both ARM and x86/x64 users, they will need to develop Metro applications.

Developers working with Metro will be using Microsoft Visual Studio 2011, which like Windows 8 is in development and will be the first version of Visual Studio to support Metro. We won’t spend too much time on Visual Studio, but it will provide development facilities for all of the languages Metro supports, including HTML/CSS/JavaScript. For UI programming Microsoft’s Expression Blend 5 will play a big part, as XAML will be the UI markup language for most of the languages excluding HTML5/CSS.

The hard sell for Microsoft will begin tomorrow when the developers arrive. It’s clear that Microsoft has attempted to structure WinRT to be familiar to existing Windows programmers, but developers are just as sheepish (if not more) than end-users when it comes to change. It will also be the beginning of the process where the development community figures out where desktop applications fit in amongst the new Metro order. Even if Microsoft can sell developers on Metro from day one, there’s still a massive army of legacy machines – everything currently running Windows – that need to be factored in.

Mobile Experience, IE10, Live Cloud, Samsung Developer Preview PC The Windows Store
POST A COMMENT

235 Comments

View All Comments

  • Booster - Thursday, September 15, 2011 - link

    It's the ribbon again, but infinitely worse. Metro is just outright stupid, that is.

    I remember watching a presentation by Julie Larson-Green where she pitched the ribbon back in 2006. IIRC she said that they listened to the users and created the ribbon according to their usage scenarios. So according to her the ribbon was next best thing since sliced bread.

    Who were they listening to? The ribbon looks better give or take, but it's less useful in the workflow, it's less effective, it's just plain worse than the old concept. That division of MS doesn't listen to users, it's like a dictatorship in which we have to use our PCs the way that madam wants us to. But she doesn't do any actual work on the PC like me for example. Hell, you can't even preview a page or print without setting up the ribbon, where's the usability? Why do I have to scroll between all those damn tiles?

    This Windows 8 fiasco is where MS finally needs to realize the situation and finally take the matters well in hand.
    Reply
  • archer75 - Thursday, September 15, 2011 - link

    You do realize you don't have to use the metro tile UI right? You can boot right in to a traditional desktop like you are used to.
    Plenty of updates here for the desktop user.

    Really this new metro UI just provides a better layer for tablets but the OS is still there which i'm really pumped about. I don't know how often i've been using my ipad and wishing I could access a real OS on it.
    Reply
  • Moricon - Friday, September 16, 2011 - link

    "Overall Windows 8 is extremely jarring right now from a desktop user perspective. Metro is the Windows shell, no ifs ands or butts. Metro applications can only be accessed through the Metro shell (i.e. the Start Screen), and the Metro shell is always what the tablet will boot up into. Explorer as we know it is the Metro shell – if you kill it, you kill Metro shell with it – so at this time it’s not possible to boot up into the traditional Windows desktop. Even if you could, the Start Menu is gone, replaced with Metro charms."

    Metro IS the windows Shell--- METRO IS EXPLORER!!!!

    Have you loaded the build, I have, played with it. IT SUCKS bigtime!

    Microsoft will go back on this, the pressure will be to great from the desktop user!

    There are improvements, better memory management, faster boot process, safer recovery options, faster work-flow (yes ribbon is actually better for non-power users, who use keyboard shortcuts.)

    Why can they not just bring those improvements to th Win desktop version and leave metro to Tablets, Netbooks and ARM anyway.

    My days of PC Gaming are coming to a close, most Games are crap! Looks seriously like Mint will become my main Work OS and I will keep a copy of WIN7 for my back catalog of games!
    Reply
  • MrBungle123 - Friday, September 16, 2011 - link

    How is this Metro crap going to work for those of us that make a living with a mouse and keyboard?

    I work in IT, I have to do everything from assisting users to writing programs. Its not uncommon for me to have Visual Studio, Outlook, IE, 2 databases, and 5 or 6 Remote Desktop connections going on at the same time.

    There is no way in hell I'm putting this garbage on my work computer, nor am i going to install it on any of the desktops/servers connected to my network. This is a user training nightmare, the resistance to migrating to Vista from XP is nothing compared to what the resistance of migrating from Win7 to Win8 will be if the final product is anything like this.
    Reply
  • talk2dfox - Friday, September 16, 2011 - link

    Does anyone else think Windows 8 seems to have no coherent strategy?

    For users:

    1) two different types of applications, which can't run side by side: what do you do if you are a business user who needs to switch efficiently between one application which is Metro-based and another which is not?

    2) switch to the desktop and click on the start button and you're back at the Metro UI? huh? Are the only desktop applications I can start directly from the desktop UI the ones which have links on the desktop?

    3) some settings are in the metro control panel, others in the old windows control panel

    4) too many gestures which will be impossible to remember because they bear no relation to anything you've used before. The whole reason why the touch experience of iPhone et al has caught on (and why even small children catch on to it quickly) is that it is familiar. Want to move what's currently on the screen up? put your finger on it and move it up as if it were a physical object. Want to zoom? use two fingers to "stretch" or "shrink" the image. So, what's the comparable analogy in Metro for swiping up to select a button? There isn't any. Not that Microsoft had much choice - they're trying to graft a touch experience onto an existing Windows UI which has too many different functions without physical analogies, so some of them are bound to be mapped to something weird. But that's the point - trying to graft a touch experience onto the existing Windows UI is never going to produce something coherent and intuitive.

    For developers:

    5) yet another API, but all the old APIs (.net and win32) still supported (but only on x86, not ARM).

    6) If you are starting to develop an application today, what should you use?

    Will an app built for Windows Phone 7 today be portable to Metro (and sellable via the Windows 8 store)? If not, will it run at all on an ARM-based metro phone or tablet? What about an x86 based tablet or desktop?

    What if you want to write an application to be used on Win 8 on all form factors? The only thing which will run on Win 8 on ARM will be Metro, but the development tools for Metro don't exist yet. Think about how far WP7 is behind iPhone and Android today, and then consider what the situation will be like for Win 8 which is just now reaching the point where Microsoft can demo the UI and talk about development.

    Contrast this situation with iOS/OS X: With a single language (objective C), a single development environment (xcode), and two variants of essentially the same framework (Cocoa), you can target iPhone/iPad and Mac.
    Reply

Log in

Don't have an account? Sign up now