private void mCurrentDrawing_ConstructionStepComplete(object sender, Drawing.ConstructionStepCompleteEventArgs args) { if (args.ConstructionComplete) { ConstructionInProgress = false; UpdateUndoRedo(); Drawing.ClearStatus(); } else { Drawing.RaiseDisplayProperties(Drawing.Behavior.PropertyBag); CommandRedo.Enabled = false; Drawing.RaiseStatusNotification(Drawing.Behavior.ConstructionHintText(args)); } }
public virtual void LoadDrawing(XElement element, string fileName) { PointBase.SuppressAutoLabelPoints = true; try { Clear(); Drawing.AddFromXml(element); Drawing.Name = fileName; Drawing.ClearStatus(); Drawing.ActionManager.Clear(); } catch (Exception ex) { Drawing.RaiseError(this, ex); } PointBase.SuppressAutoLabelPoints = false; }
protected void PlotFunction(string function) { var result = MEFHost.Instance.CompilerService.CompileFunction(Drawing, function); Func <double, double> func = result.Function; if (func != null) { var graph = CreateFunctionGraph(); graph.Drawing = Drawing; graph.FunctionText = function; Actions.Add(Drawing, graph); Drawing.ClearStatus(); } else { Drawing.RaiseStatusNotification(result.ToString()); } }