我可以在 textView 中设置全宽照片吗
抱歉我英语说得不好
我的代码:
public class ImageGetter implements Html.ImageGetter {
@Override
public Drawable getDrawable(String source) {
Drawable drawable = getResources().getDrawable(R.drawable.imgN);
if (source.equals("img1")) {
drawable = getResources().getDrawable(R.drawable.img1);
drawable.setBounds(0, 0, 100, 150);
return drawable;
}
}
width = 100% drawable.setBounds(0, 0, width, height);