Podcast: Brian Noyes on the State of WPF and More
Wednesday, February 18, 2009, 12:56 PM
Posted by Ruben Steins
Two weeks ago, DotNetRocks had a very interesting talk with Brian Noyes, about the state of WPF and in what way companies are adopting it. They talked about the difficulties in getting this technology adopted by clients and several of the architectural intricacies of WPF.
Brian made a few interesting remarks. One of them was that he thinks people coming from an ASP.NET background have a less hard time getting to grips with the way markup and code are seperated in WPF. And I think that it's true, but ASP.NET and WPF also share that one big risk: if you're not carefull you'll end up with a very tightly coupled markup and code-behind (spaghetti). As Brian puts it:
In a perfect world, your code-behind file will contain a single line of code and that's the constructor with a call to InitializeComponent().
If only we'd live in a perfect world. All too often the coupling gets much tighter than you initially intended. Prism, on which Brian also worked, adresses some of these issues and does a good job by supporting the MVVM pattern, but even then, you're going to need some event redirecting in your code-behind.
One other thing that stuck to me was his asnwer to the question 'What are commmon mistakes people make when developing WPF application'. According to Brian, a lot of people are trying to build WPF application the same way they're doing WinForms. Dropping controls onto a form and connecting the interface to the data. This approach gets ugly very quickly in WPF, and in no way uses the architecture behind WPF to it full extent. One of the major benefits of WPF is the high level of 'seperation of concerns' you can achieve, and if you're still building the way you did in WinForms you're not leveraging this power at all.
All in all,
it's a good listen! So check it out.!