I have implement something like the following on J2me.
Is it possible to implement the same for Android?
i> I have a strip of image which I am keeping on the drawable folder. The image width & height is small.
ii> Now , using Android code & layout xml , I want to repeat displaying the small image strip so that an entire status bar / header is drawn for a screen with the use of repeating images.(mutiple image strips will ultimately draw the entire header)
The reason for implementing the header / status bar in this manner is to avoid keeping the entire header image on the drawable folder which increases the mobile application size.
Kindly provide me your inputs/sample code if anyone has done any implementation with the above logic.
Thanks in advance.
Yes, you can have tiled bitmaps in android.
If your tile is in
drawable/background.png, then indrawable/background_tile.xml:And then you can set the background of a
Viewto be your tiled bitmap in your layout:You could set the background of a
LinearLayoutor otherViewsubclass as well.