protected virtual void InitConfig(DockBaseConfig config)
 {
     var conf = (DockBaseConfig)config;
     conf.Children = Children
         .Select(layout => layout.GetConfig())
         .Cast<DockPaneBaseConfig>().ToArray();
 }
 public virtual void SetConfig(DockBaseConfig config)
 {
     if (Target != null)
         Target.InternalApplyConfig(config);
     foreach (var conf in config.Children)
         conf.Target.SetConfig(conf);
 }
 internal override void InternalApplyConfig(DockBaseConfig config)
 {
     while (LayoutEngine.OwnNodes.Count != 0)
     {
         var pane = (DockPaneBase)LayoutEngine.OwnNodes.First().Target;
         var parent = (DockNode)pane.Parent;
         parent.Items.Remove(pane);
     }
     foreach (var c in config.Children)
     {
         var p = (DockPaneBase)c.Target.Target;
         p.Name = c.Name;
         p.Length = c.Size;
         p.Align = c.Align;
         Items.Add(c.Target.Target);
     }
 }
 internal override void InternalInitConfig(DockBaseConfig config)
 {
     var conf = (DockPaneBaseConfig)config;
     conf.Name = Name;
 }
 internal override void InternalApplyConfig(DockBaseConfig config)
 {
     foreach (var c in config.Children)
     {
         var p = (DockPaneBase)c.Target.Target;
         p.Align = c.Align;
         p.Length = c.Size;
         p.Name = c.Name;
         Items.Add(p);
     }
 }
 internal abstract void InternalInitConfig(DockBaseConfig config);
 internal abstract void InternalApplyConfig(DockBaseConfig config);
 public void ApplyConfig(DockBaseConfig config)
 { LayoutEngine.SetConfig(config); }
        protected override void InitConfig(DockBaseConfig config)
        {
            var conf = (DockPaneBaseConfig)config;
            conf.Target = this;
            conf.Index = OwnNodes.IndexOf(this);
            conf.Align = Align;
            conf.Size = Length;
            Target.InternalInitConfig(conf);

            base.InitConfig(config);
        }
 internal override void InternalInitConfig(DockBaseConfig config) { }
        protected override void InitConfig(DockBaseConfig config)
        {
            var conf = (DockBayBaseConfig)config;
            conf.ChildCount = OwnNodes.Count;
            Target.InternalInitConfig(conf);

            base.InitConfig(config);
        }