Hello,

Suppose I have a tool window with a toolbar child. I want to be able to limit resizing of the tool window so it must always display every button (with as many rows as necessary). I know it's got to do with handling WM_SIZING and using AdjustWindowRectEx to change the RECT given, but I'm not sure how to make sure every button is visible and permit adjustment to a different layout.

So if I have a toolbar with 6 buttons on it, I could have:-
1x6 2x3 2x4 2x5 3x2 4x2 5x2 6x1
(Not always full rows)

I think the main issue is that free resizing affects both axes, whereas if I only changed one at a time it would be more straightforward.

Anyone got some input?