示例#1
0
            public object Deserialize(object o, Altaxo.Serialization.Xml.IXmlDeserializationInfo info, object parent)
            {
                EllipseShape s = null != o ? (EllipseShape)o : new EllipseShape(info);

                info.GetBaseValueEmbedded(s, typeof(EllipseShape).BaseType, parent);

                return(s);
            }
    protected override void FinishDrawing()
    {
      RectangleF rect = GetNormalRectangle(_Points[0].layerCoord,_Points[1].layerCoord);
      EllipseShape go =  new EllipseShape(rect.X,rect.Y,rect.Width,rect.Height);

      // deselect the text tool
			_grac.SetGraphToolFromInternal( Altaxo.Gui.Graph.Viewing.GraphToolType.ObjectPointer);
      _grac.ActiveLayer.GraphObjects.Add(go);
      _grac.WinFormsController.RefreshGraph();
    }
    protected override void FinishDrawing()
    {
      RectangleF rect = GetNormalRectangle(_Points[0].layerCoord,_Points[1].layerCoord);
      EllipseShape go =  new EllipseShape(rect.X,rect.Y,rect.Width,rect.Height);

      // deselect the text tool
      this._grac.CurrentGraphToolType = typeof(GraphControllerMouseHandlers.ObjectPointerMouseHandler);
      _grac.Layers[_grac.CurrentLayerNumber].GraphObjects.Add(go);
      _grac.RefreshGraph();
    }
		protected override void FinishDrawing()
		{
			var rect = GetNormalRectangle(_Points[0].LayerCoordinates, _Points[1].LayerCoordinates);
			EllipseShape go = new EllipseShape(_grac.Doc.GetPropertyContext());
			go.SetParentSize(_grac.ActiveLayer.Size, false);
			go.SetRelativeSizePositionFromAbsoluteValues(rect.Size, rect.LeftTop);

			// deselect the text tool
			_grac.SetGraphToolFromInternal(GraphToolType.ObjectPointer);
			_grac.ActiveLayer.GraphObjects.Add(go);
		}
示例#5
0
 public EllipseShape(EllipseShape from)
     :
     base(from) // all is done here, since CopyFrom is virtual!
 {
 }
示例#6
0
            public void Serialize(object obj, Altaxo.Serialization.Xml.IXmlSerializationInfo info)
            {
                EllipseShape s = (EllipseShape)obj;

                info.AddBaseValueEmbedded(s, typeof(EllipseShape).BaseType);
            }
示例#7
0
        /// <summary>
        /// Deserializes the EllipseGraphic Version 0.
        /// </summary>
        /// <param name="obj">The empty EllipseGraphic object to deserialize into.</param>
        /// <param name="info">The serialization info.</param>
        /// <param name="context">The streaming context.</param>
        /// <param name="selector">The deserialization surrogate selector.</param>
        /// <returns>The deserialized EllipseGraphic.</returns>
        public override object SetObjectData(object obj, System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context, System.Runtime.Serialization.ISurrogateSelector selector)
        {
            EllipseShape s = (EllipseShape)base.SetObjectData(obj, info, context, selector);

            return(s);
        }
示例#8
0
        /// <summary>
        /// Serializes EllipseGraphic Version 0.
        /// </summary>
        /// <param name="info">The serialization info.</param>
        /// <param name="context">The streaming context.</param>
        public override void GetObjectData(System.Runtime.Serialization.SerializationInfo info, System.Runtime.Serialization.StreamingContext context)
        {
            EllipseShape s = this;

            base.GetObjectData(info, context);
        }
示例#9
0
 public EllipseShape(EllipseShape from)
     :
     base(from)
 {
 }
示例#10
0
 public EllipseShape(EllipseShape from)
   :
   base(from)
 {
 }
示例#11
0
		public EllipseShape(EllipseShape from)
			:
			base(from) // all is done here, since CopyFrom is virtual!
		{
		}