CToolBarCtrl drawing taller than it should
My toolbar buttons are all 16x15, however I can't size any controls within 28 pixels of the toolbar or the toolbar and control will have drawing errors with eachother. when located 28 pixels below, there is a large gap between the toolbar and the control, and I'm pretty crunched for screen real estate. Not that 4 pixels makes a difference, but things just look tighter. I would like to get rid of these padded pixels at the bottom of the toolbar. I am calling CToolBarCtrl::SetButtonSize(CSize(16, 15)), which doesn't help. I tried to use CToolBarCtrl::SetMetrics, but apparently VC++ 6 doesn't have this function (it was the VS.NET documentation). There is no text on the toolbar. How do I stop it from drawing so tall? If it stuck to a 24 pixel tall rectangle at the top of the window, that would be perfect.
Thanks for any help.
Re: CToolBarCtrl drawing taller than it should
I found the solution, use CCS_NORESIZE in the style parameter when you create the toolbar, then manually do MoveWindow in OnSize.