问题
Is there a standard methodolgy for scaling image buttons using one image size across multiple blackberry phone model screen resolutions ?
I'm resizing encoded iamges based on display width. So to resize an image to a quarter length of the screen I do -
imageLength = Dislay.getWidth / 4;
Is there something better ?
Thanks
回答1:
I'm not sure I understand what you need.
Do you want to scale an image? If so, take a look at scaleImage32(int, int) method. Also, you should use methods from the Fixed32 class to calculate image sizes.
If you only want to scale a button, maybe this answer will help you.
来源:https://stackoverflow.com/questions/5578725/how-to-create-image-buttons-that-scale-across-multiple-resolutions