ComponentFactory.Krypton.Docking.KryptonDockingManager.SaveConfigToXml C# (CSharp) Method

SaveConfigToXml() public method

Saves docking configuration information using a provider xml writer.
public SaveConfigToXml ( XmlWriter xmlWriter ) : void
xmlWriter XmlWriter Xml writer object.
return void
        public void SaveConfigToXml(XmlWriter xmlWriter)
        {
            // Remember the current culture setting
            CultureInfo culture = Thread.CurrentThread.CurrentCulture;

            try
            {
                // Associate a version number with the root element so that future versions of the code
                // will be able to be backwards compatible or at least recognise incompatible versions
                xmlWriter.WriteStartElement("KD");
                xmlWriter.WriteAttributeString("V", "1");

                // Give event handlers chance to embed custom data
                xmlWriter.WriteStartElement("DGD");
                OnGlobalSaving(new DockGlobalSavingEventArgs(this, xmlWriter));
                xmlWriter.WriteEndElement();

                // The element saves itself and all children recursively
                SaveElementToXml(xmlWriter);

                // Terminate the root element and document
                xmlWriter.WriteEndElement();
            }
            finally
            {
                // Put back the old culture before exiting routine
                Thread.CurrentThread.CurrentCulture = culture;
            }
        }
KryptonDockingManager