Posted 14 years ago
by Robert Knight
Hi,
I am currently evaluating using the MDI for a project and have run into an issue.
My application involves a number of tabs, each containing a WinFormsHost. In order to display overlay graphics on top of these hosts I am binding another transparent windows position and size to the location of the host. The owner of these windows is my main application window.
This mostly works but I have a number of issues:
1. When a tool (or other window) is rafted it correctly appears above the overlay window. However if I then change tabs the overlay of the new primary tab appears over the tool window. This can be resolved by clicking the tool window and then back to the tab. I have implemented a couple of Activate calls in the tabbed host PrimaryWindowChanged to do this automatically but wondered if there was any alternative?
2. When a document, containing the WinFormsHost, is rafted the overlay window correctly follows the rafted window but after an initial move always appears behind it. I am assuming this is because the overlay windows owner is the main window. Have you any suggestions how I can resolve this?
3. When I have nested dockSites and rearrange my various tool windows the layout and position changed handlers on my overlay window are not getting called. Is there a general event I can hook into that indicates some change has occured to the layout one of the docksites and therefore force my overlay windows to reevaluate the position?
Thanks
Rob
[Modified at 07/26/2011 05:25 AM]
I am currently evaluating using the MDI for a project and have run into an issue.
My application involves a number of tabs, each containing a WinFormsHost. In order to display overlay graphics on top of these hosts I am binding another transparent windows position and size to the location of the host. The owner of these windows is my main application window.
This mostly works but I have a number of issues:
1. When a tool (or other window) is rafted it correctly appears above the overlay window. However if I then change tabs the overlay of the new primary tab appears over the tool window. This can be resolved by clicking the tool window and then back to the tab. I have implemented a couple of Activate calls in the tabbed host PrimaryWindowChanged to do this automatically but wondered if there was any alternative?
2. When a document, containing the WinFormsHost, is rafted the overlay window correctly follows the rafted window but after an initial move always appears behind it. I am assuming this is because the overlay windows owner is the main window. Have you any suggestions how I can resolve this?
3. When I have nested dockSites and rearrange my various tool windows the layout and position changed handlers on my overlay window are not getting called. Is there a general event I can hook into that indicates some change has occured to the layout one of the docksites and therefore force my overlay windows to reevaluate the position?
Thanks
Rob
[Modified at 07/26/2011 05:25 AM]