Window Resize question (MFC)
I want to make a window resizable, but I want to limit exactly how it can be resized. For instance, I am drawing a game board and the board is exactly a square. So when the user resizes horizontally, I want the window to also grow vertically by the same amount. Also, I don't want the board to be less than some minimum size, so I want to disallow resizing if the window is getting too small.
My first guess is to handle WM_SIZE, and then use some Win32 API call to resize the window (based on input params) if they doesn't conform to my liking. Does this sound right or is there some other approach? And what would that API call be?