Petzold ’n’ Programming

Wednesday, August 30, 2006 11:00 am. Now that it’s almost obsolete, I’ve been wandering in the grown-over ways of .NET recently, with Programming Microsoft Windows Forms, 2005 Edition as my guide — by the great Charles Petzold, Windows book author extraordinaire. ... Petzold is a clever and sensitive fellow, but the weird thing I discovered is, whaddyano, he likes Windows programming!

The last time I brushed-up against Petzold, about four million years ago in 1996 or so, I had written a single Windows program the old-fashioned way, and used at least one of his books in aid of my pitiful and desperate efforts. This was so unpleasant that I wandered over to Egghead and bought a copy of Borland’s EZ-Windows Delphi programming environment. I appreciate that most normal human beings think all programming is chicken tracks, and I will not dispute this; let’s just say Delphi Pascal was much easier chicken tracks than raw C-language Windows.

In those dark times, Microsoft had their Visual Basic product from which Borland’s Delphi stold its ideas, but VB really couldn’t be used for adult work like the important endeavors in which I was engaged; it was a kiddy language. So of course the estimable Petzold didn’t write a book about that (well actually, since then he has written about Visual Basic .NET).

But now in these latter days, the guy who created Delphi, Anders Hejlsberg, had been stolen by Microsoft — actually about the time I was getting involved with Delphi — and is somehow a key player in the vast family of .NET programming environments which, to be sure, are still kiddy languages in a way, but at least appear to be fully grown-up, and they provide almost all the convenience of EZ program-creation that lazy programmers like myself insist on.

But, see, Petzold doesn’t like that. He doesn’t think you should create a button for a Windows program by just grabbing it from a palette and slapping it on a form. He thinks you should create the button in your own code, the way the Deity intended, and position it, set its caption, etc., right there in your program with decent detailed instructions. It’s so much simpler! It’s so much cleaner! It’s so much harder!

That Which is Simplest is Cheap

But all I really want to know, if you want it simpler, why program in Windows? It’s silly; and there’s nothing really simple about Petzold’s way, it’s just slightly simpler than the EZ way, and there’s so much junk and code in Windows — or any graphical desktop aka “Linux” — the “slightly” is probably somewhere down below 1%! Why not just do whatever’s easiest, the EZ aka “cheap” way?

Because Petzold is purer; he’s cleaner, he believes in something, and that is simplicity. ... It’s like the guy with the Hummer thinking he’s living the simple life when he turns off the air-conditioning!

And if you think I’m nuts, see Petzold’s web essay Does Visual Studio Rot the Mind? about how it’s better to learn programming the hard way. He doesn’t quite get to walking the 40 miles to school in the snow, but he does mysteriously evoke the numerous gadgets, remote controls, and other conveniences that one finds in the modern computerized home of which he clearly has dark suspicions....

Be Not Hard

But I do not mean to be harsh; the Petzold book and attitude is still fascinating because he takes the long way ’round, and if he does it for some weird philosophical disability — how are we different, any one of us? ... Does anyone really live a rational life? ... Not me, anyway. ...