-3

This image is from medium android application. The white boxes are the selected items. How can I make list of items like this and let the user select some of them in android?

Image1

Stephen Rauch
  • 47,830
  • 31
  • 106
  • 135
ayakhaled
  • 71
  • 1
  • 1
  • 10
  • 2
    Questions that are just a picture and "how do I make this?" are off topic (see [help/on-topic]) on StackOverflow. You should attempt yourself and then ask for help when you have a _specific_ programming problem (i.e., some code) – David Rawson Feb 09 '17 at 01:12

1 Answers1

0

You can import two images and use one or the other depending on if the item is selected or not, for this you need to use a selector.

It´s like this one android button selector,

Also, I recommend you to use a 9-patch images, you can see more about it here https://developer.android.com/studio/write/draw9patch.html

As the webpage says "They are bitmap images that automatically resize to accommodate the contents of the view and the size of the screen" so I think they would be perfect for your application

Community
  • 1
  • 1