Ejemplo n.º 1
0
        public override void ParseXml(System.Xml.XmlElement aNode)
        {
            base.ParseXml(aNode);
            if (aNode.HasAttribute("readonly"))
            {
                FReadOnly = aNode.Attributes["readonly"].Value == "1";
            }
            else
            {
                FReadOnly = false;
            }

            if (aNode.HasAttribute("printonlytext"))
            {
                FPrintOnlyText = aNode.Attributes["printonlytext"].Value == "1";
            }
            else
            {
                FPrintOnlyText = true;
            }

            HC.SetBorderSideByPro(aNode.Attributes["border"].Value, FBorderSides);
            FBorderWidth = byte.Parse(aNode.Attributes["borderwidth"].Value);
            FText        = aNode.InnerText;
        }
Ejemplo n.º 2
0
 public override void ParseXml(System.Xml.XmlElement aNode)
 {
     base.ParseXml(aNode);
     FReadOnly = bool.Parse(aNode.Attributes["readonly"].Value);
     HC.SetBorderSideByPro(aNode.Attributes["border"].Value, FBorderSides);
     FBorderWidth = byte.Parse(aNode.Attributes["borderwidth"].Value);
     FText        = aNode.InnerText;
 }
Ejemplo n.º 3
0
        public void ParseXml(XmlElement aNode)
        {
            FWidth           = int.Parse(aNode.Attributes["width"].Value);
            FHeight          = int.Parse(aNode.Attributes["height"].Value);
            FRowSpan         = int.Parse(aNode.Attributes["rowspan"].Value);
            FColSpan         = int.Parse(aNode.Attributes["colspan"].Value);
            FAlignVert       = (HCAlignVert)(byte.Parse(aNode.Attributes["vert"].Value));
            FBackgroundColor = HC.GetXmlRGBColor(aNode.Attributes["bkcolor"].Value);
            HC.SetBorderSideByPro(aNode.Attributes["border"].Value, FBorderSides);

            if ((FRowSpan < 0) || (FColSpan < 0))
            {
                FCellData.Dispose();
                //FCellData = null;
            }
            else
            {
                FCellData.ParseXml(aNode.SelectSingleNode("items") as XmlElement);
            }
        }
Ejemplo n.º 4
0
        public virtual void ParseXml(XmlElement aNode)
        {
            FWidth           = int.Parse(aNode.Attributes["width"].Value);
            FHeight          = int.Parse(aNode.Attributes["height"].Value);
            FRowSpan         = int.Parse(aNode.Attributes["rowspan"].Value);
            FColSpan         = int.Parse(aNode.Attributes["colspan"].Value);
            FAlignVert       = (HCAlignVert)(byte.Parse(aNode.Attributes["vert"].Value));
            FBackgroundColor = HC.HCRGBStringToColor(aNode.Attributes["bkcolor"].Value);
            HC.SetBorderSideByPro(aNode.Attributes["border"].Value, FBorderSides);

            if ((FRowSpan < 0) || (FColSpan < 0))
            {
                FCellData.Dispose();
                FCellData = null;
            }
            else
            {
                FCellData.Width = FWidth;  // // 不准确的赋值,应该减去2个水平padding,加载时使用无大碍
                FCellData.ParseXml(aNode.SelectSingleNode("items") as XmlElement);
            }
        }