Thank you for visiting the BlackBerry Support Community Forums.
BlackBerry will be closing the BlackBerry Support Community Forums Device Forums on April 1st (Developers, see below)
BlackBerry remains committed to providing excellent customer support to our customers. We are delighted to direct you to the CrackBerry Forums, a well-established and thorough support channel, for continued BlackBerry support. Please visit http://forums.crackberry.com or http://crackberry.com/ask. You can also continue to visit BlackBerry Support or the BlackBerry Knowledge Base for official support options available for your BlackBerry Smartphone.
"When we launched CrackBerry.com 10 years ago, we set out to make it a fun and useful destination where BlackBerry Smartphone owners could share their excitement and learn to unleash the full potential of their BlackBerry. A decade later, the CrackBerry community is as active and passionate as ever and I know our knowledgeable members and volunteers will be excited to welcome and assist more BlackBerry owners with their questions."
- Kevin Michaluk, Founder, CrackBerry.com
Developers, for more information about the BlackBerry Developer Community please review Join the Conversation on the BlackBerry Developer Community Forums found on Inside BlackBerry.
05-17-2010 05:50 AM
I have a quick and probably very dumb question regarding the positioning of a bitmap as background in a screen. The relevant piece of code is the following:
And for some reason, Eclipse tells me that the three last parameters are incorrect (expecting int). What is the syntax then? I am using JDE 5.0.
Any kind of help would be appreciated, thanks!
05-17-2010 07:11 AM
I'm a newbie myself but a quick search using the community search option and using the phrase "set image as background" gives this as the first result:
The article is a Knowledge Base article and is probably what you are looking for.
05-17-2010 07:51 AM
I think u can go ahead like this:
create a vertical field maanger and place the image in the paint method
VerticalFieldManager vfm = new VerticalFieldManager()
final Bitmap background = Bitmap.getBitmapResource("back.png")
protected void paint(Graphics g)
int y = this.getVerticalScroll;
protected void sublayout(int width,int height)
//here u can set the position of other elements that belongs to this manager
05-18-2010 06:10 AM - edited 05-18-2010 06:13 AM
Thanks for the reply, however this would not center both verticaly and horizontaly the image, would it?
I have read the knowledge base article of course, it is just that I don't know how to use the following function for example:
Background bg = BackgroundFactory.createBitmapBackground(Bitmap bitmap, int positionX, int positionY, int repeat);
given the following possible arguments: