예제 #1
0
 protected override void AddAttributesToElement(Element element, HtmlAttributes attributes)
 {
     for (int i = 0; i < attributes.Length; i++)
     {
         String localName = attributes.GetLocalName(i);
         String uri       = attributes.GetURI(i);
         if (!element.hasAttributeNS(uri, localName))
         {
             element.setAttributeNS(uri, localName, attributes.GetValue(i));
         }
     }
 }
예제 #2
0
        protected override Element CreateHtmlElementSetAsRoot(HtmlAttributes attributes)
        {
            Element rv = document.createElementNS("http://www.w3.org/1999/xhtml", "html");

            for (int i = 0; i < attributes.Length; i++)
            {
                rv.setAttributeNS(attributes.GetURI(i), attributes.GetLocalName(i), attributes.GetValue(i));
            }

            document.appendChild(rv);
            return(rv);
        }
예제 #3
0
 override protected void AddAttributesToElement(XmlElement element, HtmlAttributes attributes)
 {
     for (int i = 0; i < attributes.Length; i++)
     {
         String localName = attributes.GetLocalName(i);
         String uri       = attributes.GetURI(i);
         if (!element.HasAttribute(localName, uri))
         {
             element.SetAttribute(localName, uri,
                                  attributes.GetValue(i));
         }
     }
 }
예제 #4
0
        protected override Element CreateElement(string ns, string name, HtmlAttributes attributes)
        {
            if (OnCreateElement != null)
            {
                OnCreateElement(ns, name, attributes);
            }

            if (IsDebug)
            {
                GlobalLog.Write("Stop in CreateElement", LogChannel.NOTIFY_MSG);
                waiter.WaitOne();
            }

            Element rv = document.createElementNS(ns, name);

            for (int i = 0; i < attributes.Length; i++)
            {
                rv.setAttributeNS(attributes.GetURI(i), attributes.GetLocalName(i), attributes.GetValue(i));
            }
            return(rv);
        }