Android java 绘制圆圈
自定义CircleView
package com.java.circle;
import android.content.Context;
import android.graphics.Canvas;
import android.graphics.Paint;
import android.view.View;
public class CircleView extends View {
private Paint paint;
private float x, y, radius;
public CircleView(Context context, float x, float y, float radius) {
super(context);
this.x = x;
this.y = y;
this.radius = radius;
initPaint();
}
private void initPaint() {
paint = new Paint();
paint.setAntiAlias(true);//消除锯齿
paint.setColor(0xFF0000FF); // 设置圆圈颜色为蓝色
paint.setStyle(Paint.Style.STROKE); // 设置为描边模式
paint.setStrokeWidth(5); // 设置描边宽度
}
标签:Paint,float,IOS,paint,radius,import,Android,Flutter,android
From: https://blog.csdn.net/u013491829/article/details/143820867