I want to design a button which looks like:
(Sorry, can't yet post images...)
Has anybody an idea how to layout? Use Buttons or TextViews? Is there an option to group 2 TextViews?
Thank you :)
I want to design a button which looks like:
(Sorry, can't yet post images...)
Has anybody an idea how to layout? Use Buttons or TextViews? Is there an option to group 2 TextViews?
Thank you :)
You create a layout and populate it as you want it to appear in your button, generate a bitmap image of the layout, and set that bitmap as the image in an ImageButton.
There are plenty of layout tutorials around.
There are examples of how to do the bitmap conversion:
http://www.brighthub.com/mobile/google-android/articles/30676.aspx
For the image button:
http://www.mkyong.com/android/android-imagebutton-example/
Although this uses a resource drawable. You just call setImageBitmap instead. See:
http://developer.android.com/reference/android/widget/ImageView.html
I can provide an example later tonight when I am at my pc.