Paint為畫筆
常用方法
setARGB(int a, int b, int c, int d) 設置顏色0~255之間的整數
setColor(int color) 可以是常量或者Color.rgb(int , int , int , int )
setAlpha(int a) 透明度0~255之間
setAntiAlias(boolean a)
setDither(boolean b) 是否使用抖動,抖動會使顏色更平滑
setPathEffect(PathEffect effect) 路徑效果
setShader(Shader shader) 繪制顏色漸變,
setShadowLayer(float radius, float x, float y, int color) 陰影角度,x,y軸,顏色
setStrokeCap 填充樣式
setStrokeJoin 畫筆轉彎處連接風格
setStrokeWidth 筆觸寬度
setStyle 填充風格
setTextAlign 文字對齊方式
setTextSize
setFakeBoldText 是否為粗體
setXfermode 圖像重疊時的處理方式