Owner Drawn ComboBox (Drop List). Static Text Box shrinks
Posted on 2008-10-15
I've created an Owner-Draw CComboBox and derived a class from it. This works and my owner-draw processing works correctly (basically just displaying an abbreviated version of the text of each item).
On the dialog designer, the combo box is 12 dialog units high, which is what I want.
However, when the program runs, it shrinks to about 9 DLU high and the text in both the text box section and in the list section is terribly squashed up. When I turn Owner-Draw off, the correct height of 12 DLU is restored.
What's going on here ?
All I am overloading is the DrawItem() member function.
Do I need to override something else, in order to tell Windows what size of rectangle I want ?
((This isn't the usual question of "how do I set the height of the drop box part". I've solved that one.))