Beispiel #1
0
        public override void OnChildrenLoaded()
        {
            // Add to the documents style:
            Node node = firstChild;

            if (node != null)
            {
                StyleSheet_ = htmlDocument.AddStyle(this, node.textContent);
            }
        }
        internal void BuildString(Css.StyleSheet sheet)
        {
            string result = "";

            foreach (Css.Rule rule in sheet.rules)
            {
                Css.StyleRule style = rule as Css.StyleRule;

                if (style == null)
                {
                    result += rule.GetType() + "\r\n";
                }
                else
                {
                    result += style.Selector.ToString() + "\r\n";
                }
            }

            ComputedNodeData = result;
        }