C# WPF - Resizable Usercontrol / Page (Grab and dr

2019-08-27 18:40发布

问题:

How do you make a user-resizable user control in WPF?

For example, in Visual Studio the user can resize their panels, like the Solution Explorer. How can I make my page be resizable?

I know that making a grid splitter is a solution, but any other solution besides that? Also will it take into account the other pages in the main window and resize them accordingly as well?

And how do I set a maximum horizontal resize limit?

回答1:

you can achieve this effect with a SplitContainer