Composite WPF and the Ribbon Control

While working for WPF and Composite Application Library (CAL) for the first time, I had some difficulty both understanding their concepts and apply them in the optimal way, but I tried harder.

One of the benefits of CAL I found was the Command Binding which truly facilitates complying to the Model-View-ViewModel UI Design Architecture. But finding an easy implementation for them in all the desired control was not as easy as with default menu items and tool bars. A question on stackoverflow was asking about implementing the Command Binding with the WPF Ribbon which is downloadable within the WPF Futures, and not included in the out-of-box visual studio installation.

The trick was to make custom region adapters as those of menu and tool bar. I have found samples of  RibbonRegionAdapter.

To comply with CAL and Model-View-ViewModel,  the View containing the Ribbon will be be bound to a ViewModel containing all commands. These commands would be exposed publicly and available to other modules to attach Executed and CanExecute handlers. It is possible also to expose a generic method to add commands at run time by providing their image and location on the ribbon.

I found also open source implementation for binding the docking manager. The Composite WPF Contrib Project on CodePlex contains a TabGroupPaneRegionAdapter for Infragistics TabGroupPane.

Visual Studio 2010 (Rosario)

Microsoft has provided the first look at its new development platform Visual Studio 2010 which is based on the new .NET Framework 4.0.

Microsoft described the next release through the following five focus areas:

  • riding the next-generation platform wave
  • inspiring developer delight
  • powering breakthrough departmental applications
  • enabling emerging trends such as cloud computing
  • democratizing application life-cycle management (ALM)

Their efforts in the area of ALM is the next step after their launch of Team Foundation Server (TFS) in 2005 and their efforts to combine Management, Analysis, Design, Testing, and Deployment all together under one platform.

The new announced features includes enhanced modeling with new diagram types such as use case, activity, and sequence beside the tightly close integration of modeling with existing and new code.

My favorite in the new features is the new testing capabilities which includes a stand-alone Test Runner that allows for running manual test, and at the same time take system snapshots with pertinent information and can be even used to take video captures of what was done during the test and report a bug to TFS directly with the captured data as an attachment.

Another favorite is the Test Impact View, which allows the developer to view the code changes made and the impacted tests that needs to re-run before checking in the latest modification.

For more info you can check the Visual Studio Team System 2010 Overview page.