代码中添加drawableLeft/drawableRight等
Drawable rightDrawable = getResources().getDrawable(R.drawable.searchfield_search_icon_normal_filled)
rightDrawable.setBounds(0, 0, rightDrawable.getMinimumWidth(), rightDrawable.getMinimumHeight())
search_edit.setCompoundDrawables(null, null, rightDrawable, null)
Drawable drawable= getResources().getDrawable(R.drawable.drawable)
drawable.setBounds(0, 0, drawable.getMinimumWidth(), drawable.getMinimumHeight())
myTextview.setCompoundDrawables(drawable,null,null,null)