Example #1
0
        public override BaseShape copySelf()//重写身复制方法
        {
            LineShape copyLineShape = new LineShape();

            copyLineShape.setP1(this.getP1()); //复制起点
            copyLineShape.setP2(this.getP2()); //复制终点
            copyLineShape.penColor = this.penColor;
            copyLineShape.penwidth = this.penwidth;
            return(copyLineShape);
        }
Example #2
0
        public override BaseShape CopySelf()//重写身复制方法
        {
            LineShape copyLineShape = new LineShape();

            copyLineShape.SetP1(GetP1()); //复制起点
            copyLineShape.SetP2(GetP2()); //复制终点
            copyLineShape.PenColor = PenColor;
            copyLineShape.Penwidth = Penwidth;
            return(copyLineShape);
        }