文字模糊使用
if(Build.VERSION.SDK_INT >= Build.VERSION_CODES.HONEYCOMB){
//View从API Level 11才加入setLayerType方法 //设置View以软件渲染模式绘图
tvPhone.setLayerType(View.LAYER_TYPE_SOFTWARE,null);
}
SpannableString stringBuilder=new SpannableString("文字模糊");
stringBuilder.setSpan(new MaskFilterSpan(new BlurMaskFilter(10f,BlurMaskFilter.Blur.NORMAL)),
0,stringBuilder.length(), Spanned.SPAN_INCLUSIVE_EXCLUSIVE);
tv.setText(stringBuilder);