How would you create a docking library for WPF?

I want to implement a dock library in wpf with behavior similar to Adobe Photoshops CS3.

You can dock floating panels to other panels or docks by dragging and dropping. The docks have a fixed location.

Would you use the Docking Manager central class? What will the message flow look like? I was thinking about using two interfaces called IDock and IDockable, with a pane implementing both and a dock only implementing IDock.

I'm looking for some specific design patterns or OO principles that can help me here, so general design sounds. I know I am not entirely specific here, but that is because I don’t know where to start.

An example of moving a panel to a panel:

alt text http://dl.getdropbox.com/u/133877/Misc/Stackoverflow/wpf_dock_01.png

alt text http://dl.getdropbox.com/u/133877/Misc/Stackoverflow/wpf_dock_02.png

0


source to share


1 answer


Perhaps you could start looking into http://www.codeplex.com/AvalonDock which is a wpf docking library. There is probably a lot to learn from him.



+1


source







All Articles