OK, so you've just decided that WPF is the strategic technology of choice for your next-generation application, and you've taken the opportunity to flatten and reinstall your developer workstation. What should you put on it to create the perfect WPF development environment? There are so many good tools, utilities and samples out there, that I thought I'd put together a little checklist that will hopefully help folk out. I'd love to hear your suggestions for anything that I've missed: I'll try to keep this updated over time.
Base Environment
Tools and Utilities
Building a Code Toolbox
Sample Applications
I'm the kind of developer who likes lots of sample code available to me for copying concepts, ideas and techniques. Copy these to a \samples directory for quick access:
Also unpack %SdkTools%\..\Samples\WPFSamples.zip to a \samples\sdk directory so you can easily browse through all the samples without needing to go through the SDK documentation interface.
Now enable Windows Desktop Search (install WDS 3.0 here if you're running Windows XP) and configure it to index file contents of .xaml, .cs, .vb files as a bare minimum. Make sure it's set to index the entire \samples directory that you put the above samples into. Now you can quickly pull up every sample that shows the usage of (say) BitmapSource and ColorConvertedBitmap just by hitting Win+F and searching for those keywords.
Support
Tips and Tricks
Just in case anyone was wondering, you're safe to install the service pack for Visual Studio 2005 on a machine that has the .NET Framework 3.0 Extensions and/or the "WPF/E" project templates. One thing to be aware of is that Visual Studio 2005 SP1 includes the web application project types which are required as a prerequisite for the "WPF/E" installation, and you're strongly encouraged to remove the add-in that I mentioned in step 5 of this post before installing SP1.
If you're looking to learn WPF from a book, there are an increasing range of good choices out on the bookshelves that are based on the shipping APIs.
The latest book to be published is WPF Unleashed by Adam Nathan. If you've ever needed to do any coding to the Win32 API from a managed environment, chances are high that you've either got a well-thumbed copy of his book .NET and COM on your desk or you've found an API wrapper at his website pinvoke.net. Almost uniquely for a technical book, .NET and COM was so popular that there was a grass-roots developer campaign to resurrect it after it went out of print - for a while, it sold used for significantly over its list price on eBay, before the publisher ordered a new print run.
So what's the new book like? While I haven't yet had the opportunity to read the final manuscript from cover to cover, I've seen a number of draft chapters and there's a lot to like here. Adam has a readable, human style that isn't as dense or exhaustive in its coverage of each topic as Charles' work, but provides some great practical insights in the many sidebars scattered throughout the book that will help you apply WPF concepts to your own projects. As one of the key developers on the 3D team, I'm looking forward to reading Daniel Lehenbauer's contributions on that topic, particularly since there's only sketchy printed coverage available thus far on that topic.
For such a visual technology, SAMS have taken the smart choice of publishing the entire book in color, and that has a powerful impact on comprehension: being able to scan through code listings printed with the same color scheme as you'd see on-screen in Visual Studio makes it far easier to pick out the salient points. Of course, it's even more important for coverage of topics like styles or vector drawings, when color is everything. This book sets a new bar for visual polish, and I hope other publishers take note.
The publishers have been generous enough to offer a sample chapter available for download from this blog; it covers a number of the major new concepts in WPF - dependency properties, routed events, visual trees. Remember - you saw it here first!
Which of these three books should you buy? It's hard to make a categorical recommendation of just one title: they all have their strengths. If you're just starting out with WPF and are looking for a survey of the major elements and concepts, then Laurence's Apress book is a great introduction. If you're already developing with WPF, you'll find Charles' Microsoft Press book to be a treasure trove of elegant solutions, clever tricks and precise explanations. If you're looking for a good general purpose, approachable guide to the breadth of the WPF platform, then Adam's SAMS book is definitely worth a look.
I'm presuming that almost everyone who follows this blog has at least one of the Expression design tools on their machine; Expression Blend (formeddrly known as "Sparkle" or Expression Interactive Designer) is an essential part of the arsenal for any WPF developer; Expression Design is a capable graphics tool that can output XAML in either WPF or "WPF/E" dialects; Expression Web is a very worthy web development product for creating standards-compliant markup, and lastly Expression Media combines digital asset management (image and media cataloging and workflow) with media encoding tools.
We've just announced the coming out party in the United States for the tool suite, with events in San Francisco, Chicago and New York during the latter half of January. If you're in or nearby any of these cities, you can register to attend some designer-focused sessions, meet up with a bunch of us and even attend a cool cocktail party. Full details and event registration can be found at the website.
If you're not conveniently placed for these sessions, remember that we have our inaugural WPF online chat taking place this Thursday at 12:30pm Pacific; details in the preceding post.
Following on from a couple of requests, I'm delighted to announce that we'll be hosting our first ever live online technical chat with the WPF team on the MSDN site next Thursday, December 21st, at 12:30pm Pacific Time (that's 3:30pm ET, 8:30pm GMT, 9:30pm CET). We'll have a collection of the WPF team on hand to answer your technical questions, hear your feedback on what we should be doing in our next release, share great tips and tricks for using WPF, and just generally connecting with one another.
If you're interested, you can click on this ICS file to add the appointment to your calendar. And please feel free to RSVP in the comments section below so that we know to roll out the red carpet for you!
Hope to see you there!
[Update] Thanks to those who've pointed out my error - next Thursday is in fact the 21st, not the 20th. I've corrected the details above. Just testing!