Example #1
0
        private void AddCurveImplementation(Curve curve)
        {
            if (curve == null)
            {
                return;
            }

            Curvedline curved = new Curvedline(curve);
            Style      style  = new Style(curve);

            XmlNode             newNode  = null;
            XmlDocumentFragment fragment = null;

            string classId = null;

            //Add the line
            fragment          = base.CreateDocumentFragment();
            fragment.InnerXml = curved.ExtractCurve();

            newNode = ContainerNode.AppendChild(fragment);

            //Determine style
            classId = AddClassImplementation(style.GetStyle(), "");
            newNode.Attributes.GetNamedItem("class").InnerText = classId;
        }
 public override void Reset()
 {
     base.Reset();
     if (_marker == null)
     {
         _marker = new Marker(null);
     }
     if (_curvedline == null)
     {
         _curvedline = new Curvedline(null);
     }
 }
		public override void Reset()
		{
			base.Reset();
			if (_marker == null) _marker = new Marker(null);
			if (_curvedline == null) _curvedline = new Curvedline(null);
		}
		private void AddCurveImplementation(Curve curve)
		{
			if (curve == null) return;

			Curvedline curved = new Curvedline(curve);
			Style style = new Style(curve);

			XmlNode newNode = null;
			XmlDocumentFragment fragment = null;

			string classId = null;

			//Add the line
			fragment = base.CreateDocumentFragment();
			fragment.InnerXml = curved.ExtractCurve();

			newNode = ContainerNode.AppendChild(fragment);

			//Determine style
			classId = AddClassImplementation(style.GetStyle(), "");
			newNode.Attributes.GetNamedItem("class").InnerText = classId;
		}