Skip to main content

Silverlight


SilverLight is a subset of WPF, and also a superSet of WPF, whatever that means.

It is a cross-browser, cross-platform plug-in.
Create rich interactive applications for the web(RIAs).

Originaly invented as competitor to flash.
Lightweight runtime (under 5MB)
Based on XAML
NIce interactive rich experience, like javascript runs on the client side, in the case of silverlight, there is a run time running on the client side.
With content delivered to the browser.

Why Silverlight, leverages the .net framewor, rich experience.
Provides video, vector graphics, persepective 3d, feature like deep zoom. +100 controls.
Allows 1080p true HD., or H.264 (MP4) WMV with smooth stream ing.
They can also be ran on the desktop wihtout any current connectivity.
CLR support was introled in silverlight 2 support.
Silverlight 3 added navigation, validation modal windows, layout.
Silverlight 4 adds, printing, new controls including datagrikd, enhanced data binding including drag and drop. Adds Toast notification windows like outlook.
Offline digital right management (DRM)
Reading writting special user folders. Com interop.
2008 is silverlight 3.
Visual Studio 2010 use silverlight 4 but comes with 3, version 4 ahs to be downloaded. Can also be developped with Expression Blend(layout, animation, effect, but doesn't feel like visual studio, Expression Blend is included with a MSDN subscription.
To check if its' installed, navigate to http://www.microsft.com/silverlight/get-started/install/default.aspx. The control panel can also show which Microsoft Silverlight and Microsoft Silverlight SDK is installed.
Exppression Blend works in a more visual way.

Silverlight application template creates a XAP file that is ran on the client machine.
Always download the silverlight conttrols from codeplex.
Silverlight Business Application includes looogin and membership.

WPF vs. Silverlight

Silverlight is a client side technology because it runs on the client side.
Both technlogy use xaml and allow you create clietn application.
WPF used of all the .net framework, while silverlight has only a subset.
WPF runs as a windows application, a browser application format is a xbap, but still running on the client, not every broswers support xbap.
WPF runs only on windows and windows xp or above, full 3d support.
Silverlight ships independently, inst part of the .net framework.
choice depnds on audience, technolical needs, deployment.

Silverlight keeps growing, for example COM Interop allows it to talk to Office.

Inconvinient. Developpers creatint applications generely create ungly applications.
Good XAML applciation require graphic designers, but far easier to create good looking apps with XAML, espcialy with Expression Blend.
XAML is a XML-based grammar thad declaratively defines Silverlight applications.
WebForms, is a set of classes, must write code to generate the interface.
For Silverlight, you can write code or can write XAML.
The name of an element in XAML will not always match the class name in code, but each element does have a class.

When creating a project, visual studio will add a second project, the host, which will be the web app hosting the silverlight project.
In design mode, the fixed size root tag on the form will modifiy the code so the content doesn't stretch.

By default, the template starts with a user control, a few namespaces references and a grid. some of the namespaces or obejcts have prefixes, representing their namespaces.
Things with no prefixes usualy deal with presentation.

Right clicking the designer allows to show DocumenntOutline, that shows the heiarchy of the controls and the same can be done in the details pane at the bottom of the window.

Comments

Popular posts from this blog

Rxjs Forkjoin vs Zip

These Rxjs combination operators are handy to make Rest calls in parallel and combine their results. Both take n observables and will return the results, with the difference that forkJoin will complete even if one of the nested observables errors of completes.

React JS Patterns

React JS is always evolving, and evolving quickly. These evolutions can be very significant ones, for example, the addition of hooks. React has a lot of code patterns, often these patterns are motivated by the DRY and/or the open-close principle. These patterns sometimes come in to replace a previous one, yet the previous ones still stays in use, as a consequence, the list of patterns keep growing. The goal of the next few posts will be to list the patterns commonly used in React JS developpement. Some patterns are more specific to JSX and I will start with these, and maybe add patterns specific to Redux.

Object.create vs. Object.Assign

The two functions return a new Object but with a difference. Object.assign will go through an enumerable and copy it's properties. Object.create will create a new empty object but link it's proto chain to the old object. One way to view this is with JSON.stringify(newCreatedObject) this would return an empty object, since all the properties are not part of the object's own properties, but inherited through prototype inheritance. In both case, the advantage is it allows to extended existing objects without modifying the original. This is particularly important when receiving arguments from a caller, in this case it's better to use these methods instead of modifying the caller's object since he might have planned to use it again later, expecting it to be in it's original state.