Recently, Charles Petzold has taken some heavy criticism for the organization of his book, Applications=Code+Markup. He wrote a pithy response that says today’s technical writing is becoming little more than a Powerpoint presentation. Don Box followed up with his own opinion on the topic, and now I’m going to chime in from my unique vantage of being a developer. I don’t work for Microsoft, I don’t write books. I just write code for a living and on ocassion share some of my discoveries with whomever stumbles into my hidden corner of the Interweb.
Digging a little deeper into the ruckus, I found an archived speech that Mr. Petzold (we’re not on a first name basis) had given to a developer group back in 2005. In it he makes an interesting observation (emphasis mine):
Can any one programmer master 60,000 methods and properties? I think not. One solution, of course, is specialization. I myself have specialized. This evening I hope no one will ask me questions about web forms or ASP .NET … because those aren’t my specialty. I do Windows Forms, and my language is C#.
I think Mr. Petzold’s book fell victim to a paradigm shift. I would argue that WPF development is more like ASP.Net development than it is Winforms development. If he was writing a book on ASP.Net development, I would be seriously surprised if he took the first half of the book to show how you can create Webform applications without using markup. Yes you can technically do it…the question is why? As he observed in his posts while writing the book, there are some things in WPF that you can do with much less effort using markup over C#. That’s the point…a lot of the framework is catered toward XAML.
If anyone were to ask me to name the root cause of this commotion, I would tell them that Mr. Petzold failed to make the paradigm leap. It’s as if a lifelong C developer were to write a book about C++ and not introduce the concept of classes until halfway through.