Exemple #1
0
 public override SqlNode Clone()
 {
     return(new OffsetLimitClause()
     {
         Limit = Limit?.Clone() as ScalarExpression,
         Offset = Offset?.Clone() as ScalarExpression
     });
 }
Exemple #2
0
 public Allocation Copy()
 {
     return(new Allocation(
                LocalMustHave.DeepClone(),
                LocalNiceHave.DeepClone(),
                Offset.Clone(),
                Rotation));
 }
Exemple #3
0
        private void Offset_Remove(int index)
        {
            Offset     u    = _copy.Offsets[index].Clone();
            List <int> path = Track.GetPath(_copy);

            Program.Project.Undo.Add($"Copy Offset {index + 1} Removed", () => {
                ((Copy)Track.TraversePath(path)).Insert(index, u.Clone());
            }, () => {
                ((Copy)Track.TraversePath(path)).Remove(index);
            });

            _copy.Remove(index);
        }
Exemple #4
0
        public override object Clone()
        {
            Refe obj = new Refe(this.Direction);

            obj.Secondary = this.Secondary;
            if (Values != null)
            {
                obj.Values = this.Values.Clone();
            }
            if (Labels != null)
            {
                obj.Labels = this.Labels.Clone();
            }
            if (Type != null)
            {
                obj.Type = (string[])this.Type.Clone();
            }
            if (Color != null)
            {
                obj.Color = (string[])this.Color.Clone();
            }
            if (Size != null)
            {
                obj.Size = (string[])this.Size.Clone();
            }
            obj.FontSize  = this.FontSize;
            obj.FontColor = this.FontColor;
            obj.Bold      = this.Bold;
            obj.Italic    = this.Italic;
            obj.Angle     = this.Angle;
            if (this.Offset != null)
            {
                obj.Offset = (double[])Offset.Clone();
            }
            if (this.Placement != null)
            {
                obj.Offset = (double[])Placement.Clone();
            }

            return(obj);

            //(FontColor
            //(FontSize >
            //(Bold) cmnd
            //(Italic) cm
            //(Underline)
            //(Angle < Mt
            //(Offset !=
            //(Placement
        }
Exemple #5
0
        internal SLTransform2D Clone()
        {
            var trans = new SLTransform2D();

            trans.HasOffset  = HasOffset;
            trans.Offset     = Offset.Clone();
            trans.HasExtents = HasExtents;
            trans.Extents    = Extents.Clone();

            trans.Rotation       = Rotation;
            trans.HorizontalFlip = HorizontalFlip;
            trans.VerticalFlip   = VerticalFlip;

            return(trans);
        }
 /// <summary>
 /// Creates a clone of this instance
 /// </summary>
 /// <returns>A clone of this instance</returns>
 public object Clone()
 {
     return(new Probe
     {
         Type = Type,
         Value = Value,
         SecondaryValues = (int[])SecondaryValues.Clone(),
         Threshold = Threshold,
         Speed = Speed,
         DiveHeight = DiveHeight,
         Offset = (float[])Offset.Clone(),
         TriggerHeight = TriggerHeight,
         Inverted = Inverted,
         RecoveryTime = RecoveryTime,
         TravelSpeed = TravelSpeed,
         MaxProbeCount = MaxProbeCount,
         Tolerance = Tolerance,
         DisablesBed = DisablesBed,
         Persistent = Persistent
     });
 }
Exemple #7
0
        public override object Clone()
        {
            AxLabel axlab = new AxLabel(_scaleDirection);

            axlab.Text      = Text;
            axlab.FontSize  = FontSize;
            axlab.FontColor = FontColor;
            axlab.Angle     = Angle;
            axlab.Bold      = Bold;
            axlab.Italic    = Italic;
            axlab.Underline = Underline;
            axlab.Side      = Side;
            axlab.Visible   = this.Visible;
            if (Offset != null)
            {
                axlab.Offset = (double[])Offset.Clone();
            }
            axlab.ScalePrimary = ScalePrimary;

            return(axlab);
        }