What you're looking for is a FlowLayout
. It doesn't exist natively in Android, but Romain Guy (a former Android engineer) gave a talk showing a quick implementation, and there are also several libraries available that you could use, or easily spin your own.
https://github.com/ApmeM/android-flowlayout
https://github.com/blazsolar/FlowLayout
http://nishantvnair.wordpress.com/2010/09/28/flowlayout-in-android/
http://hzqtc.github.io/2013/12/android-custom-layout-flowlayout.html