/// <summary> /// Clone this instance /// </summary> public override DrawObject Clone() { DrawText drawText = new DrawText(Parentpagelist); drawText._font = _font; drawText._theText = _theText; drawText.rectangle = rectangle; FillDrawObjectFields(drawText); return(drawText); }
public override void OnMouseDown(DrawArea drawArea, MouseEventArgs e) { Point p = drawArea.BackTrackMouse(new Point(e.X, e.Y)); TextDialog td = new TextDialog(); string t = "Text"; Color c = Color.Black; Font f = new Font("Arial", 10); DrawText o; AddNewObject(drawArea, (o = new DrawText(drawArea.Pages, p.X, p.Y, t, f, c))); o.Dirty = true; o.oIndex = drawArea.Pages.GetNewobjectoIndex(); DCS.Forms.MainForm.Instance().m_propertyGrid.SelectedObject = o; DCS.Forms.MainForm.Instance().m_propertyGrid.Refresh(); }