AODL.Document.Content.Text.Indexes.TableOfContents.NewXmlNode C# (CSharp) Метод

NewXmlNode() приватный Метод

News the XML node.
private NewXmlNode ( string stylename, bool protectChanges, string textName ) : void
stylename string The stylename.
protectChanges bool if set to true [protect changes].
textName string Name of the text.
Результат void
		private void NewXmlNode(string stylename, bool protectChanges, string textName)
		{
			this.Node		= ((TextDocument)this.Document).CreateNode("table-of-content", "text");

			XmlAttribute xa = ((TextDocument)this.Document).CreateAttribute("style-name", "text");
			xa.Value		= stylename;
			this.Node.Attributes.Append(xa);

			xa				= ((TextDocument)this.Document).CreateAttribute("protected", "text");
			xa.Value		= protectChanges.ToString().ToLower();
			this.Node.Attributes.Append(xa);

			xa				= ((TextDocument)this.Document).CreateAttribute("use-outline-level", "text");
			xa.Value		= "true";
			this.Node.Attributes.Append(xa);

			xa				= ((TextDocument)this.Document).CreateAttribute("name", "text");
			xa.Value		= ((textName!=null)?textName:"Table of Contents1");//+((TextDocument)this.Document).TableofContentsCount;
			this.Node.Attributes.Append(xa);
		}