Represent the list level style.
Inheritance: AbstractStyle
Exemplo n.º 1
0
        /// <summary>
        /// Add all possible ListLevelStyle objects automatically.
        /// Throws exception, if there are already ListLevelStyles
        /// which could'nt removed.
        /// </summary>
        /// <param name="typ">The Liststyle bullet, numbered, ..s</param>
        public void AutomaticAddListLevelStyles(ListStyles typ)
        {
            if (this.Node.ChildNodes.Count != 0)
            {
                try
                {
                    foreach (XmlNode xn in this.Node.ChildNodes)
                    {
                        this.Node.RemoveChild(xn);
                    }
                }
                catch (Exception ex)
                {
                    throw;
                }
            }

            this.ListlevelStyles.Clear();

            for (int i = 1; i <= 10; i++)
            {
                ListLevelStyle style = new ListLevelStyle(this.Document, this, typ, i);
                this.ListlevelStyles.Add(style);
                //this.Document.Styles.Add(style);
            }

            foreach (ListLevelStyle lls in this.ListlevelStyles)
            {
                this.Node.AppendChild(lls.Node);
            }
        }
Exemplo n.º 2
0
        /// <summary>
        /// Add all possible ListLevelStyle objects automatically.
        /// Throws exception, if there are already ListLevelStyles
        /// which could'nt removed.
        /// </summary>
        /// <param name="typ">The Liststyle bullet, numbered, ..s</param>
        public void AutomaticAddListLevelStyles(ListStyles typ)
        {
            Node.RemoveNodes();

            ListlevelStyles.Clear();

            for (int i = 1; i <= 10; i++)
            {
                ListLevelStyle style = new ListLevelStyle(Document, this, typ, i);
                ListlevelStyles.Add(style);
                //this.Document.Styles.Add(style);
            }

            foreach (ListLevelStyle lls in ListlevelStyles)
            {
                Node.Add(lls.Node);
            }
        }
Exemplo n.º 3
0
		/// <summary>
		/// Add all possible ListLevelStyle objects automatically.
		/// Throws exception, if there are already ListLevelStyles
		/// which could'nt removed.
		/// </summary>
		/// <param name="typ">The Liststyle bullet, numbered, ..s</param>
		public void AutomaticAddListLevelStyles(ListStyles typ)
		{
			if (this.Node.ChildNodes.Count != 0)
			{
				foreach(XmlNode xn in this.Node.ChildNodes)
					this.Node.RemoveChild(xn);
			}

			this.ListlevelStyles.Clear();

			for(int i = 1; i <= 10; i++)
			{
				ListLevelStyle style		= new ListLevelStyle(this.Document, this, typ, i);
				this.ListlevelStyles.Add(style);
				//this.Document.Styles.Add(style);
			}

			foreach(ListLevelStyle lls in this.ListlevelStyles)
				this.Node.AppendChild(lls.Node);
		}