Beta-Lighting the web

One of the current most interesting technologies around is Microsoft Silverlight, whose intention is to provide a programmer and designer friendly way to develop web UIs. It is basically a subset of Windows Presentation Foundation, although it has a few minor differences that you will surely note along the way.

If you aren’t familiar to WPF either (as I was when I started trying Silverlight), it is a whole new paradigm that intends to replace WinForms. It defines each control through two files: the old .cs file with the code supporting the front-end and a XAML file. The latter is an XML which should be modified by the designer (after the initial square and black-and-white presentation coded by the programmer) to apply all the necessary styles to make it more human-friendly. Needless to say, WPF is much more than this, and it can’t be explained in a mere paragraph.

Back to Silverlight, you may consider it as the little brother of WPF, designed for web applications. A Silverlight plugin in the browser contains the runtime, and it downloads and executes a .xap file with the assemblies of the application being stored in the server. This allows C# code to be executed directly on the client, without needing to translate it to a massive amount of javascript.

However, note that most user-interaction events are restricted to the browser, therefore some very simple events such as double click are not present in Silverlight. Also, the whole NET framework has been stripped of some of its functionality to ensure it can be packaged in the small plugin; and only a few WPF controls are present without their full functionality (although there are plans to release up to a hundred controls in the release version).

The most recent available version is Silverlight 2.0 Beta 2, which offers some improvements from Beta 1. If you are interested in the details, I won’t be listing them here, since there is already an excellent post by Scott Guthrie containing all changes and even an explanation on how to use the new Visual State Manager in Blend.

In my opinion, the best improvement between the two betas is the fact that exceptions are now much more detailed, giving you a clue on where to find the error in the XAML, instead of just getting an “AG_BAD_PARSER_VALUE”. Note, however, that there are still several XAML errors that could be caught on compile-time that won’t show themselves until you run the application.

To sum up, WPF can be regarded as a new UI design paradigm, with Silverlight being a very powerful web based equivalent, and it is worth giving it a shot. But bear in mind that it is still a beta, containing some annoying bugs still waiting to be corrected, and some very useful features that are missing for no apparent reason. I have the intention to do most of my blogging around them.

One Response to Beta-Lighting the web

  1. Pingback: Santiago Palladino » Blog Archive » Silverlight 2 Beta 2 Breaking Changes

Leave a Reply

Your email address will not be published. Required fields are marked *


× one = 2

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>