5

How can I set a minimum size for the window in WinUI 3?

Problem

GIF Of The Problem

phuclv
  • 37,963
  • 15
  • 156
  • 475

1 Answers1

1

Currently, there is no MinSize or MaxSize properties yet on the Window class in WinUI3.

A workaround is that using the SetWindowSubclass function to hook WM_GETMINMAXINFO and set the min size.

Please check this Github link: How to set minimum window size (Desktop) which contains more discussion about this.

Roy Li - MSFT
  • 8,043
  • 1
  • 7
  • 13