Hi all, So, <worksheet> element has a child element called <sheetViews>, which contains a group of <sheetView> elements. It contains view data such as the cursor position, active sheet etc.
Here is a problem with importing these view settings. For us to set such view data, we have to gain access to the current controller, which is not available at time of file import. It appears to be set after the import is complete. This may be reasonable since a file typically gets loaded before the corresponding application frame gets shown. I have also looked into getting a XViewDataSupplier instance from the model since there is a model instance during import, but so far no luck. I have not looked far enough into this, but my gut feeling is that, the view data needs to be set before we can query for its instance, which it is not during import (correctly me if I'm wrong). Now, since we need to keep our design of the oox::xls code reasonably close to the design of the existing Excel binary filter, it's probably logical to do something similar to what the binary filter currently does for the view settings. I've discovered that the binary filter creates an instance of ScExtTabSettings for each sheet to temporarily store view settings of their respective sheet during import, and use ScExtTabSettingsCont as a container and ScExtDocOptions to control the life cycle of those ScExtTabSettings instances. Once the import is complete, the filter calls PostDocLoad() to commit the view settings collected during import. I could see us doing something similar for SpreadsheetML import. We would still need to work out a way to do equivalent of PostDocLoad(), but at least for now, we could create view setting container classes to start collecting view data during import. How does that sound? Kohei -- Kohei Yoshida - OpenOffice.org Engineer - Novell, Inc. <[EMAIL PROTECTED]> --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
