Reputation: 49
I am trying to create a blog type app, at the moment I am using an image button to get replaced with an image using the picasso libaray. Although, how would I go about adding/inserting image(s) from my gallery to an edit text. I am not sure how to go about doing this:
Upvotes: 1
Views: 359
Reputation: 3349
Try using imageView.setCompountDrawablesWithInstrinsicBounds(drawable, null, null, null)
This way you can dynamically pass in the images you want to display from a gallery.
Upvotes: 0
Reputation: 3511
Although the image isn't very clear in describing your question, you can however use the below code to add a drawable in EditText.
<EditText
...
android:drawableLeft="@drawable/some_drawable"
android:drawablePadding="10dp"/>
Upvotes: 1