//加载点9位图
NinePatchDrawable npd = (NinePatchDrawable) getResources()
.getDrawable(R.drawable.xxxx);
//设置需要的范围边界
Rect rect = new Rect(left, top,top, bottom);
npd.setBounds(rect);
//最后在画布上画出来
npd.draw(canvas);
在自定义view中画 .9 的Bitmap
最新推荐文章于 2020-05-29 17:20:47 发布