There are two ways to make a vertical toolbar. You can use the common CCS_VERT
style, or you can use the TBSTYLE_EX_VERTICAL
extended style which is specific to the toolbar. Why are there two ways of doing the same thing?
Because we messed up.
Whoever created the TBSTYLE_EX_VERTICAL
extended style didn’t realize that there was already a perfectly good way of specifying a vertical toolbar (namely, CCS_VERT
).
What’s worse, some vertical behavior is controlled by CCS_VERT
and some by TBSTYLE_EX_VERTICAL
. So if you want a vertical toolbar, you probably want to set both styles to cover all your bases on Windows XP.
Unfortunately, the story doesn’t get any better. Once this mistake was discovered, work was done to try to get the two styles in sync, so that setting one automatically set the other. The idea was to ensure that everybody got consistent behavior instead of getting half-and-half if you, say, turned on CCS_VERT
and forgot to turn on TBSTYLE_EX_VERTICAL
. But this was itself a failure, because there were some programs that let the two styles fall out of sync on purpose because they liked the half-and-half behavior.
It’s a mess. We’re sorry.
Pre-emptive snarky comment: “This is why Windows sucks.”
0 comments