by Michael S. Kaplan, published on 2008/07/08 10:01 -04:00, original URI: http://blogs.msdn.com/b/michkap/archive/2008/07/08/8706789.aspx
Dedicated to an Easter Egg poem, and its author...
Previous blogs in this series:
This blog in the series is a slight detour....
And I am going to go slightly out of order now.
The off-course jaunt started in my mind last time in a response to Part 2, regular reader Andrew West commented:
Surely the font installer does not need to know who exactly may or may not be using the font; it just broadcasts the WM_FONTCHANGE message and well-behaved applications will handle it and update their font information accordingly.
Now Andrew is quite right -- WM_FONTCHANGE is just the message that a responsible installer/uninstaller would send here.
Unfortunately there are many problems with the architecture -- some the fault of installers/uninstallers that are indirectly the fault of the difficulty of the task, and others the fault of the complex process that nevertheless has failed to keep up with some of the complexities of the underlying platform:
You get the idea.
The design here is quite sensible for a bygone era, but to be honest something better might really be considered.
But I digress.
The point is that even a "well-behaved application" that sends the message and a "well-behaved application" that receive it might not ever be able to communicate well enough to be told that something is up.
Despite the fact that the contents of a directory and the contents of a registry key were altered.
So in the end, the rules (if you work within the framework above) end up being quite simple:
So pretty much the only time that you never have to do anything is when the font in question is already installed. when you didn't have to do anything.
Yeesh. Talk about over-engineered! :-)
In the next part of the series we'll talk about the mechanics of the install and uninstall that must happen....
And in a later blog I will talk about my opinion of regular reader John Cowan's suggested "solution", here. :-)
This blog brought to you by ƒ (U+0192, aka LATIN SMALL LETTER F WITH HOOK)
John Cowan on 8 Jul 2008 2:13 PM:
Shucks, Michael, I didn't know you cared -- so much.
Michael S. Kaplan on 8 Jul 2008 4:28 PM:
For the sake of completeness (and so no one [else] gets the wrong idea!), I suppose I should include the poem....
C'mon, Join with Me
Baby, strap yourself onto my new DBEngine -
I'm revvin' my jets, headin' for heaven.
Together, girl, you and I can change the world.
Or at least run an update - let's give it a whirl.
Don't pull that old self-join trick on me.
You need my tables, and my primary key.
I've hurt you before, but I'll make amends,
Or deletes if you want, or selects, or appends.
Once the future looked dim, but now I declare
Our options are endless, no strings to compare.
I'm a dynaset baby, I'm fast and I'm free.
But I'll treat you right - no more DDE.
Hey, I'm grown up, I'm thirty-two-bit.
Bring all your old records, I'll take the hit.
I swear you're more than an object to me -
You're the top of my call stack, my whole MDB.
Girl, you're a user, and you need a group,
So don't get stuck in an infinite loop.
I'll import, secure, analyze, or insert.
I'll do what you want, I'll even convert.
I've got a watch on you baby, and it's about time.
If you don't change your values it'll sure be a crime.
I can't bear to see you in that exclusive lock -
C'mon, open up, we'll drive up the stock.
We'll churn through these records, fast we we're able.
C'mon, lighten up, let's go and make table.
Don't give me that look, don't give me that sigh.
I can't help it, I'm a rows and columns guy.
Our relationship's stable, there's no question.
I'll love you forever, or at least for this session.
referenced by
2008/09/08 On installing and removing fonts, Part 8: Sometimes being selfish makes you more trustworthy
2008/07/30 On installing and removing fonts, Part 7: What was the question, exactly?
2008/07/14 On installing and removing fonts, Part 5: The takeaway from that is...
2008/07/11 On installing and removing fonts, Part 4: The easiest part is the addition!