Profile Picture

NDockingFrameworkState.Save is not persisting restored size when NUIDocument is minimized

Posted By Brad Swearingen 13 Years Ago

NDockingFrameworkState.Save is not persisting restored size when...

Author
Message
Nevron Support
Posted 13 Years Ago
View Quick Profile
Supreme Being

Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)Supreme Being (4,435 reputation)

Group: Forum Members
Last Active: Last Week
Posts: 3,054, Visits: 4,009
Hi Brad,

The docking framework state saves only the Bounds of the documents.
When the document is minimized its bounds are the actual size and location of the minimized document.
If these bounds are saved when the document is restored it will not be displayed correctly.
The restored bounds are not persisted.

Best Regards,
Nevron Support Team



Brad Swearingen
Posted 13 Years Ago
View Quick Profile
Forum Guru

Forum Guru (53 reputation)Forum Guru (53 reputation)Forum Guru (53 reputation)Forum Guru (53 reputation)Forum Guru (53 reputation)Forum Guru (53 reputation)Forum Guru (53 reputation)Forum Guru (53 reputation)Forum Guru (53 reputation)

Group: Forum Members
Last Active: 8 Years Ago
Posts: 53, Visits: 3

I've got code like the following which persists my layout to a file correctly.

NDockingFrameworkState dfs = new NDockingFrameworkState(dm);

String curPath = -- my file path goes here --

dfs.PersistDocuments = true;

dfs.PersistStyles = true;

dfs.Save(curPath);

However, if a NUIDocument is minimized it doesn't save its restored location and size.  Thus, when loading that layout later the restored location and size is lost.  When I look in the saved .XML files I can see the postion and size are all set to 0 for the minimized NUIDocument.  If I manually edit this file and put appropriate location and size information in and then do the Load() on it the restored postions are used when the user clicks to restore the MDI document.  Is this a bug or is there a setting I need to indicate to show that the restored position should be persisted too?  I'm using the 11.1.17.12 build.

Here's what I see in the .XML file (and if I change those 0's to other numbers they get used during the Load method):

        <HostBounds>
          <Location>
            <X>0</X>
            <Y>0</Y>
          </Location>
          <Size>
            <Width>0</Width>
            <Height>0</Height>
          </Size>
          <X>0</X>
          <Y>0</Y>
          <Width>0</Width>
          <Height>0</Height>
        </HostBounds>
        <WindowState>Minimized</WindowState>





Similar Topics


Reading This Topic