BackgroundImage for createButton on Android
I know that backgroundImage does not work on android and that we are supposed to use image instead (Would be nice if we had the backgroundSelectedImage and backgroundImage for android though). It seems when using this method however that the touchable surface area decreases. Is there a better method that I should be using for using an image as a button in android. Thanks in advance for any replies.
3 Answers
-
Hey Joseph
backgroundImage for Button should be working now in HEAD.. I recently pushed some fixes surrounding this. You should be aware, however, that android skews your image and tries to make it "look" like a button, so it may not be exactly what you want. We have a built-in 9-patch parser that can take an Android-style 9-patch PNG and automatically stretch for use as a button's background image. You might check out the doc on 9-patch PNGs here:
http://developer.android.com/guide/developing/tools/draw9patch.html -
Sorry for the double post. Got the red error message and two messages were submitted.
-
Sorry for the double post. Got the red error message and two messages were submitted.