How to implement the following effects?The text color and the icon were changed after they were pressed

you can use selector for the background.

For the location you can use LinearLayout with horizontal orientation, and set weight for childs.

http://www.compiletimeerror.com/2014/03/android-button-selector-tutorial-with.html#.Vt6dQuZRLuw

Here is an example how to reach it.

Good luck!

Leave a Comment