//矩形 canvas.drawRect("左边距离左边框的距离","上边距离上边框的距离","右边距离左边框的距离","下边距离上边框的距离","画笔"); //线 canvas.drawLine("线的起始x坐标","起始y坐标","终止x左边","终止y坐标","画笔"); //文字 canvas.drawText("文字内容","文字x坐标","文字y坐标","画笔"); //圆形 canvas.drawCircle("圆心x坐标","圆心y坐标","圆半径","画笔"); Paint.setStrokeWidth(5);//设置画笔粗细 Paint.setColor(Color.BLACK);//设置画笔粗细 Paint.setTextSize(30);//设置画笔字体大小
自定义view画图,画笔设置
最新推荐文章于 2022-03-12 18:22:13 发布