I've just started learning to develop blackberry apps and I've hit a bit of a snag. I'm unsure how I could move around a background image that is large than the field/manager it is being applied to. Here's an image to illustrate what I mean:
So far I have tried adding a Bitmap to a BitmapField inside a AbsolutePositionManager thinking I would be able to set the size of the absolute manager and just move the bitmapfield around inside it. That isn't the case, the manage just takes the size of the content inside it :(
I come from a frontend web dev background so what I'm looking for is something that behaves similar to the 'background-position' attribute in css or some sort of image mask.
Thanks in advance!
-- update --
This is a code sample of where I have got to. I now have a custom sized manager that displays a chunk of a larger BitmapField. I just need a way to move that BitmapField around.
package mypackage; import net.rim.device.api.system.Bitmap; import net.rim.device.api.ui.component.BitmapField; import net.rim.device.api.ui.container.AbsoluteFieldManager; public class MyImage extends AbsoluteFieldManager { protected void sublayout(int maxWidth, int maxHeight){ int displayWidth = 326; int displayHeight = 79; super.sublayout(displayWidth, displayHeight); setExtent(displayWidth, displayHeight); } public MyImage(){ Bitmap _image = Bitmap.getBitmapResource("img.jpg"); BitmapField image = new BitmapField(_image); add(image); } }