Hi Colin,
I faced the same problem years before.
Note that users can mix Element and Type parameters when creating families.
Width parameter may be type-depending, while height parameter may not, that will vary between families.
Same for doors and BuiltInParameter.DOOR_HEIGHT and DOOR_WIDTH.
By the way, Jeremy provided the solution before I did:
"Anyway, to address your question: these parameters may well be driven by the window family definition and its types."
Have a nice weekend,
Revitalizer