With the help of 'WM_NCMOUSEMOVE' and 'WM_NCLBUTTONDOWN' you can be able to make a dockable controls, see below snippet for more detailhttp://www.codeproject.com/Articles/18812/WPF-Docking-LibraryThanksKoolprasd2003Editor, DotNetSpider MVMMicrosoft MVP 2014 [ASP.NET/IIS]

You can use a DockPanel instead of StackPanel. StackPanel explicitly doesn't care about visible space, whereas DockPanel does all of it's size calculation based on available space.The dock side of an element is defined by the attached property DockPanel.Dock. To dock an element to the center of the panel, it must be the last child of the panel and the LastChildFill property must be set to true.