PresentationModel and WPF

Julian Dominguez is writing a series about the PresentationModel pattern and using it with WPF.  http://staff.southworks.net/blogs/jdominguez/archive/2008/05/20/First-approach-to-Presentation-Model-with-DataTemplates.aspx and Glenn Block has just posted a little on the same topic:  http://blogs.msdn.com/gblock/archive/2008/05/24/using-viewmodels-and-datatemplates-to-compose-your-ui.aspx. These two have been thinking a lot about application composition as part of the PRISM project.  WPF is still so new that we still don’t know all…

1

Visual States in XAML Templates

The Silverlight and desktop WPF implementations of Templates use the same syntax and programming model for describing the tree of objects that make up the control body, but differ in how they describe dynamic changes of the template.  In desktop WPF, this is done using Triggers…for example, a trivial Button Template might look like:        …

8

Podcast

A few months ago I was interviewed by Craig Shoemaker of Pixel8 about my experiences with Expression and WPF.  The podcast is up now at:  http://pixel8.infragistics.com/shows/gossman

2

We’re hiring

http://blogs.msdn.com/ivo_manolov/archive/2008/05/20/8526007.aspx

1

AttachedBehavior pattern sample

The ClickBehavior is about the simplest I can think of.  For illustration purposes I only included one command, but LeftClickCommand, DoubleClickCommand, MouseOverCommand etc. are all obvious extensions:   public static class ClickBehavior     {         public static DependencyProperty RightClickCommandProperty = DependencyProperty.RegisterAttached(“RightClick”,                     typeof(ICommand),                     typeof(ClickBehavior),                     new FrameworkPropertyMetadata(null, new PropertyChangedCallback(ClickBehavior.RightClickChanged)));           public static void…

4

.NET 3.5 SP1 Beta and WPF

Scott’s blog has an extensive list of the new stuff:  http://weblogs.asp.net/scottgu/archive/2008/05/12/visual-studio-2008-and-net-framework-3-5-service-pack-1-beta.aspx  If you scroll down about half way, you’ll find the WPF features:  better startup performance, target performance fixes in the other areas, a new hardware accelerated graphics effects architecture, DirectX interop and a series of data enhancements, most notably better support for writing data…

1

The Attached Behavior pattern

My favorite feature of WPF (desktop and web versions) is attached properties.  It would be good enough if attached properties merely enabled things like keeping layout properties (Canvas.Left) organized by the type of container rather than the type of content, but they also enable a great little design pattern:  Attached Behavior. Nikhil recently blogged about…

20

Silverlight: the art of subsetting

I am an architect of WPF, both the full desktop version and the subset that provides the UI framework for Silverlight.  This subsetting exercise raises challenges I’ve not run into before when designing software.  Simply put, how do we keep the framework small without completely changing the programming model?  Keeping it small is relatively easy:  just…

18