public void CopyFrom(ScatterPlotStyle from, bool suppressChangeEvent) { this._shape = from._shape; this._style = from._style; if (null == this._dropLine) { this._dropLine = new CSPlaneIDList(); } else { this._dropLine.Clear(); } this._dropLine.AddClonedRange(from._dropLine); this._pen = null == from._pen ? null : (PenX)from._pen.Clone(); this._independentColor = from._independentColor; this._independentSymbolSize = from._independentSymbolSize; this._symbolSize = from._symbolSize; this._relativePenWidth = from._relativePenWidth; this._skipFreq = from._skipFreq; this._cachedPath = null == from._cachedPath ? null : (GraphicsPath)from._cachedPath.Clone(); this._cachedFillPath = from._cachedFillPath; this._cachedFillBrush = null == from._cachedFillBrush ? null : (BrushX)from._cachedFillBrush.Clone(); this._parent = from._parent; if (!suppressChangeEvent) { OnChanged(); } }
public DropLinePlotStyle(CSPlaneID planeID, PenX3D pen) { if (null == pen) { throw new ArgumentNullException(nameof(pen)); } _dropTargets = new CSPlaneIDList(new[] { planeID }); // Cached values SetCachedValues(); }
public DropLinePlotStyle(IEnumerable <CSPlaneID> planeIDs, PenX pen) { if (null == pen) { throw new ArgumentNullException(nameof(pen)); } ChildSetMember(ref _pen, pen); _dropTargets = new CSPlaneIDList(planeIDs); // Cached values SetCachedValues(); }
public DropLinePlotStyle(Altaxo.Main.Properties.IReadOnlyPropertyBag context) { _dropTargets = new CSPlaneIDList(new[] { new CSPlaneID(2, 0) }); var color = GraphDocument.GetDefaultPlotColor(context); double penWidth = GraphDocument.GetDefaultPenWidth(context); _pen = new PenX3D(color, penWidth); _lineWidth1Offset = penWidth; _lineWidth1Factor = 0; _lineWidth2Offset = penWidth; _lineWidth2Factor = 0; }
public ScatterPlotStyle(XYPlotScatterStyles.Shape shape, XYPlotScatterStyles.Style style, float size, float penWidth, Color penColor) { _shape = shape; _style = style; _dropLine = new CSPlaneIDList(); _pen = new PenX(penColor, penWidth); _symbolSize = size; _relativePenWidth = penWidth / size; _skipFreq = 1; // Cached values SetCachedValues(); CreateEventChain(); }
public ScatterPlotStyle() { this._shape = XYPlotScatterStyles.Shape.Square; this._style = XYPlotScatterStyles.Style.Solid; this._dropLine = new CSPlaneIDList(); this._pen = new PenX(Color.Black); this._independentColor = false; this._symbolSize = 8; this._relativePenWidth = 0.1f; this._skipFreq = 1; this._cachedFillPath = true; // since default is solid this._cachedFillBrush = new BrushX(Color.Black); this._cachedPath = GetPath(_shape, _style, _symbolSize); CreateEventChain(); }
public void CopyFrom(DropLinePlotStyle from, Main.EventFiring eventFiring) { if (object.ReferenceEquals(this, from)) { return; } using (var suspendToken = SuspendGetToken()) { _independentSkipFrequency = from._independentSkipFrequency; _skipFrequency = from._skipFrequency; _ignoreMissingDataPoints = from._ignoreMissingDataPoints; _independentOnShiftingGroupStyles = from._independentOnShiftingGroupStyles; _dropTargets = from._dropTargets; // immutable _additionalDropTargetIsEnabled = from._additionalDropTargetIsEnabled; _additionalDropTargetPerpendicularAxis = from._additionalDropTargetPerpendicularAxis; _additionalDropTargetUsePhysicalBaseValue = from._additionalDropTargetUsePhysicalBaseValue; _additionalDropTargetBaseValue = from._additionalDropTargetBaseValue; ChildCopyToMember(ref _pen, from._pen); _independentColor = from._independentColor; _independentSymbolSize = from._independentSymbolSize; _symbolSize = from._symbolSize; _lineWidth1Offset = from._lineWidth1Offset; _lineWidth1Factor = from._lineWidth1Factor; _gapAtStartOffset = from._gapAtStartOffset; _gapAtStartFactor = from._gapAtStartFactor; _gapAtEndOffset = from._gapAtEndOffset; _gapAtEndFactor = from._gapAtEndFactor; EhSelfChanged(EventArgs.Empty); suspendToken.Resume(eventFiring); } }
public DropLinePlotStyle(Altaxo.Main.Properties.IReadOnlyPropertyBag context) { this._dropTargets = new CSPlaneIDList(new[] { new CSPlaneID(2, 0) }); var color = GraphDocument.GetDefaultPlotColor(context); double penWidth = GraphDocument.GetDefaultPenWidth(context); _pen = new PenX3D(color, penWidth); _lineWidth1Offset = penWidth; _lineWidth1Factor = 0; _lineWidth2Offset = penWidth; _lineWidth2Factor = 0; }
public DropLinePlotStyle(CSPlaneID planeID, PenX3D pen) { if (null == pen) throw new ArgumentNullException(nameof(pen)); this._dropTargets = new CSPlaneIDList(new[] { planeID }); // Cached values SetCachedValues(); }
public void CopyFrom(DropLinePlotStyle from, Main.EventFiring eventFiring) { if (object.ReferenceEquals(this, from)) return; using (var suspendToken = SuspendGetToken()) { this._independentSkipFreq = from._independentSkipFreq; this._skipFreq = from._skipFreq; this._dropTargets = from._dropTargets; // immutable this._additionalDropTargetIsEnabled = from._additionalDropTargetIsEnabled; this._additionalDropTargetPerpendicularAxis = from._additionalDropTargetPerpendicularAxis; this._additionalDropTargetUsePhysicalBaseValue = from._additionalDropTargetUsePhysicalBaseValue; this._additionalDropTargetBaseValue = from._additionalDropTargetBaseValue; this._pen = from._pen; // immutable this._independentColor = from._independentColor; _independentSymbolSize = from._independentSymbolSize; _symbolSize = from._symbolSize; _lineWidth1Offset = from._lineWidth1Offset; _lineWidth1Factor = from._lineWidth1Factor; _lineWidth2Offset = from._lineWidth2Offset; _lineWidth2Factor = from._lineWidth2Factor; this._gapAtStartOffset = from._gapAtStartOffset; this._gapAtStartFactor = from._gapAtStartFactor; this._gapAtEndOffset = from._gapAtEndOffset; this._gapAtEndFactor = from._gapAtEndFactor; EhSelfChanged(EventArgs.Empty); suspendToken.Resume(eventFiring); } }
public void CopyFrom(ScatterPlotStyle from, bool suppressChangeEvent) { this._shape = from._shape; this._style = from._style; if(null==this._dropLine) this._dropLine = new CSPlaneIDList(); else this._dropLine.Clear(); this._dropLine.AddClonedRange(from._dropLine); this._pen = null == from._pen ? null : (PenX)from._pen.Clone(); this._independentColor = from._independentColor; this._independentSymbolSize = from._independentSymbolSize; this._symbolSize = from._symbolSize; this._relativePenWidth = from._relativePenWidth; this._skipFreq = from._skipFreq; this._cachedPath = null == from._cachedPath ? null : (GraphicsPath)from._cachedPath.Clone(); this._cachedFillPath = from._cachedFillPath; this._cachedFillBrush = null == from._cachedFillBrush ? null : (BrushX)from._cachedFillBrush.Clone(); this._parent = from._parent; if (!suppressChangeEvent) OnChanged(); }
public DropLinePlotStyle(IEnumerable<CSPlaneID> planeIDs, PenX pen) { if (null == pen) throw new ArgumentNullException(nameof(pen)); ChildSetMember(ref _pen, pen); this._dropTargets = new CSPlaneIDList(planeIDs); // Cached values SetCachedValues(); }