Hey,
I have a win forms app that uses an mdi parent form. It's not the same feel as something like Word or as something like visual studio. It's a bunch of varying forms that float inside of the parent.
To convert this to wpf I was thinking I could just convert each form over as a wpf user control. Each menu option could create the corresponding user control, put it in a content pane, then add it to the XamDockManager as a "document". The user could then use the tabs to navigate through the different screens or could move/dock/float them around to arrange them.
Is this approach sound like a valid use of the XamDockManager? I want to have my screens in one "shell", but I also want it to be intuitive to the user. The docking/sizing piece feels awkward (do the user controls stay centered or resize to fill the visible region?). Also, hitting ctrl-tab within the dock manager and seeing a screen listed as a "file" feels awkward.
Any guidance would be greatly appreciated.
Thanks
Thank you for your responses.
I think that I will be able to use the XDM as-is -- I just wanted to make sure that using it in this way wasn't blatently incorrect.
I can't really say whether XDM will work for your data entry screens; you need to determine whether the layout functionality provided by the xdm works for your layout requirements. As to any other product, I'm still unsure what functionality you would be expecting. If you think a new product is needed then I would recommend submitting a suggestion with as much detail as possible about the specific requirements/functionality so it can be considered for a future version of the product. If you think that adding mdi window type layout to xdm would be helpful then you could also submit a suggestion for that but in the most basic usage, maximizing an mdi child is similar to having one document tab group since you just see the contents of a single "window".
The application that I want to convert doesn't really have "documents". It's really just a bunch of data entry screens and reports. I guess more or less I was fishing to see if the dock manager makes sense to be used with data entry screens, or if there is a specific way that it can be used to best suit data entry screens, or if Infragistics has any other wpf controls that might help in this sort of situation.
When I mentioned the awkwardness of sizing in my original post, I was just thinking about how every screen is likely to be put into a content pane that is a different size than the size the screen was originally designed in. I guess that all screens would all have to be set up carefully so that resizing would work intuitively?
jlotridge said: Is this approach sound like a valid use of the XamDockManager?
The DocumentContentHost is designed to provide a tabbed document interface similar to that of VS so if that tabbed document model fits your needs then it seems fine.
jlotridge said:The docking/sizing piece feels awkward (do the user controls stay centered or resize to fill the visible region?).
I'm not sure what you mean by awkward. The docking/sizing follows the behavior of VS. With regards to where/how the content of the ContentPane is positioned/arranged that is really up to you. By default the (Horizontal|Vertical)ContentAlignment is set to stretch so the content will be stretched to fill the content pane. You can change that based on your needs. As to what happens to the contents of whatever you put into the ContentPane (e.g. your usercontrol) again that is really up to you and the content within each. You would use whatever panels/etc. you would want to arrange the contents.
jlotridge said:Also, hitting ctrl-tab within the dock manager and seeing a screen listed as a "file" feels awkward.