views:

46

answers:

2

Hey people,

I was wondering if there is a simple way to style a ListView along with it's items like the conversation in android's text message app. There are rounded corners and stuff like that, where I'm not sure how I could implement this myself.

I know that I could look for the source code of it, and try to copy from there, but it's a huge app with a lot of files and that's why I decided to ask first.

Thanks in advance, Jan Oliver

+1  A: 

Here is a good place to start http://code.google.com/events/io/2010/sessions/world-of-listview-android.html you are basically going to want to use an Adapter to inflate views you make in the xml editor. Once you have more specific questions we can go into more detail.

schwiz
Thanks for the link! I will watch it and see if it solves my problem.
janoliver
+1  A: 

I don't see any rounded corners in the stock sms app...? Either way, rounded corners are quite easy to do with 9-patch png files. Other than that the styling of the sms app is pretty simple. It contains a couple of TextViews, and one QuickContactBadge, a few different background colors, and that's it.

benvd
Thanks, that is probably what I was looking for. In the sms app, between the the messages of different dates, there is a black divider (actually it has a gradient as background) and the white messages have rounded corners.
janoliver