如何填充Android Region的颜色?

时间:2017-02-28 08:36:59

标签: java android android-studio

我可以为特定的Android路径设置填充颜色,如下所示。

mPaint.setStyle(Paint.Style.STROKE);
mPaint.setColor(0xffffffff);
canvas.drawPath(path, mPaint);

mPaint.setStyle(Paint.Style.FILL);
mPaint.setColor(0xFF555555);
mPaint.setStrokeWidth(2);
canvas.drawPath(path, mPaint);

在画布上绘制路径后,我想更改特定区域的颜色。有没有办法用android Regions代替Paths

填充颜色

0 个答案:

没有答案