I’ve heard many people ask for advice on creating attractive text layouts using WPF — with good reason! There are quite a few challenges, in my opinion, the top difficulties are:
- Differences from HTML/CSS: More than any other part of WPF, the
System.Windows.Documentsnamespace has many similarities with HTML/CSS — but the differences are significant enough to cause real issues. - Lack of good examples: The technology is still new, so there aren’t many role-models out there to learn from. The lack of view-source capability makes it tough to
steallearn from others. - Variable-column layout is hard: Without a doubt, designing a document that looks good when reflowed into a variable-number of columns is difficult.
- Lack of a designer: This is a tough one.
It’s a bit ambitious, but I’m going to do what I can to help fix these problems.
Obviously, this will take many entries — let me know if I’m missing anything, or if you have specific questions you’d like me to address.
2 Comments
Every programmer worth his/her salt has a copy of .Net reflector somewhere close. It is way better than having a peek by “View source”.
In case someone points out about an xbap, you only have to search in your application data and local settings\application directories to find the assemblies for an xbap application.
Most people don’t do any kind of obfuscation on their code and it is still possible to guess something from obfuscated code.
Tanveer — You’re absolutely correct, Reflector is indispensible (especially with the BAML Viewer add-in). However, many designers (Blend users) don’t use the tool. Also, real WPF apps can be hard to understand due to all the indirection and abstraction that happens through templating and styling, although AJAX-based websites also have much greater complexity than the old days of HTML 1.0 :)