"So, each player gets six cards, except for the dealer, uh, the player on the dealer's right, who, uh, gets seven." "On the right?" "Yes. The second card is turned up, except on Tuesdays" "On Tuesday..." "Mm-hmm. Oh, look what you got - two jacks! You got a half FizzBin already." "Heh-heh... I need another jack!" "No, no, if you got another jack, why you'd have, uh, a shralk." "A shralk?" "Yes, you'd be disqualified." "Oh" "No, what you need now is either a king and a deuce - except at night, of course, when you'd need a queen and a four" - Star Trek episode #46, where Kirk and Spock explain WPF
"So, each player gets six cards, except for the dealer, uh, the player on the dealer's right, who, uh, gets seven." "On the right?" "Yes. The second card is turned up, except on Tuesdays" "On Tuesday..." "Mm-hmm. Oh, look what you got - two jacks! You got a half FizzBin already." "Heh-heh... I need another jack!" "No, no, if you got another jack, why you'd have, uh, a shralk." "A shralk?" "Yes, you'd be disqualified." "Oh" "No, what you need now is either a king and a deuce - except at night, of course, when you'd need a queen and a four"
- Star Trek episode #46, where Kirk and Spock explain WPF
I've spent much of the past year working pretty intensively with WPF (and other technologies), working through all the major published references, posting demos to community sites, and occassionally presenting at meetings of the local .Net User's Group. WPF enables you to do some amazing things, and I LOVE it... but I always feel obligated to qualify my recommendations, whenever developers ask me whether I think they should be moving to the new technology.
This last issue is due to what I like to think of as the "FizzBin" nature of WPF, with ten different ways to implement any task, and no apparent reason to prefer one approach to another, and little guidance available to help you make a choice. Not only will the shortcomings of whatever choice you make become clear only much later in the project, but you are virtually guaranteed to have every developer on your project adopting a different approach, resulting in a major maintenance headache. Most frustrating of all are the inconsistencies that constantly trip you up, as you try to learn the framework.
Here are some considerations I'd suggest are important, to avoid making a big mess with WPF...
<Grid Background="{StaticResource brushWatermarkBackground}" > <TextBlock Margin="5,2" Text="Type something..." Foreground="{StaticResource brushForeground}" Visibility="{Binding ElementName=txtUserEntry, Path=Text.IsEmpty, Converter={StaticResource BooleanToVisibilityConverter}}" /> <TextBox Name="txtUserEntry" Background="Transparent" BorderBrush="{StaticResource brushBorder}" /></Grid>
There are some exceptions, especially when it comes to animation and setting DataContext but, in general, layout = markup, and you usually should not need to resort to code-behind just to set control properties.
MS User Experience Team UK - Lessons learned in teaming devs and designers on actual WPF projects Billy Hollis demos a very nice UI, discussing design/dev. lessons learned on an actual WPF project
Update (9/22/08): I laughed out loud when I first came accross the title "Teach Yourself WPF in 24 Hours" in a bookstore recently, but I found this to be an AMAZINGLY good book! It covers all the major areas of WPF succinctly and clearly, using non-trivial examples that are applicable to real-world projects, and even manages to sqeeze in mention of architecture and process issues that are usually ignored. I had some minor quibbles with some of the material, including the decision to use the MVP (Model-View-Presenter) pattern in all of the examples, but its still an excellent book. Don't get me wrong. You absolutely can NOT learn WPF in 24 hours, but you CAN get an excellent introduction to WPF concepts and techniques in the three to four days it will take you to get through this material, and I highly recommend that you start here, even if you've already had some exposure to the framework.