Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Java Development

Reply
Developer
Posts: 777
Registered: ‎07-21-2012
My Device: 9810

Move image from one position to another with zooming the image and screen in touch device

Hi

 

is there any way to put image from one position to another along with zooming of screen as well as image in blackberry (touch device).

 

Thanks

Developer
Posts: 19,612
Registered: ‎07-14-2008
My Device: Not Specified

Re: Move image from one position to another with zooming the image and screen in touch device

Let us look at moving first.

 

The appropriate method to move an image will depend on how you display the image.  The easiest option is display the image in a BitmapField, and then have your Manager move the Field using setPosition.  Alternatively you could treat your screen like a canvas and render the image on to it.  Then it is easy to move - you just paint in a different position, but you might struggle with proving the user with a method to select the image. 

 

You can zoom by scaling, have a look at this link:

http://supportforums.blackberry.com/t5/Java-Development/Photo-Manipulation/m-p/497116#M100505

 

and this one:

http://supportforums.blackberry.com/t5/Java-Development/Resizing-Transparent-Bitmaps/ta-p/703239