示例#1
0
 private void RecreatePen()
 {
     if (Stroke == null)
     {
         _pen = null;
     }
     else
     {
         var brush = Stroke.CloneCurrentValue();
         brush.Freeze();
         _pen = new Pen(brush, StrokeThickness);
         _pen.StartLineCap = StrokeLineCap;
         _pen.EndLineCap   = StrokeLineCap;
         _pen.DashStyle    = new DashStyle(StrokeDashArray, StrokeDashOffset);
         _pen.DashCap      = StrokeDashCap;
         _pen.Freeze();
     }
 }
示例#2
0
 public Character Clone(VisualObject owner, int index) => new Character(owner, Creator ?? Owner, index, Geometry?.CloneCurrentValue(), Fill?.CloneCurrentValue(), Stroke?.CloneCurrentValue(), SelectionFill?.CloneCurrentValue(), SelectionStroke?.CloneCurrentValue(), Transform, IsTransformed, IsHitTestVisible, Data);
示例#3
0
 public Character Clone() => new Character(Owner, Creator, Index, Geometry?.CloneCurrentValue(), Fill?.CloneCurrentValue(), Stroke?.CloneCurrentValue(), SelectionFill?.CloneCurrentValue(), SelectionStroke?.CloneCurrentValue(), Transform, IsTransformed, IsHitTestVisible, Data);