[android-developers] Re: Varying screen resolutions

2010-01-17 Thread Neilz
 Step 1: RT[F]M 
 ;^)http://developer.android.com/guide/practices/screens_support.html

Fair enough ;-) though it's not as much fun as chatting on a forum!

 The summary is that you can
 either leave android:anyDensity=false in your manifest to let the
 platform scale your bitmaps, or you can include bitmaps of different
 sizes for different screen densities.

Well, I read the docs, now that I know they're there, although I can't
say I find them very clear.

I tried various combinations of android:anyDensity and supports-
screens, but the default action seems to have been the best I could
get anyway. I set up two Emulators:

- Android 2.0 (level 5) WVGA800, density 240
- Android 2.0 (level 5) WVGA854, density 240

My app appears fine in the first, but in the second it gets shrunk and
leaves a black border.

Any ideas how I can get this working? Current manifest reads:

uses-sdk android:minSdkVersion=3  android:targetSdkVersion=4 /
supports-screens
  android:largeScreens=true
  android:normalScreens=true
  android:smallScreens=true
  android:anyDensity=false /
-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

[android-developers] Re: Varying screen resolutions

2010-01-16 Thread String
Step 1: RT[F]M ;^) 
http://developer.android.com/guide/practices/screens_support.html

Additionally, there was a LOT of discussion of this when multi-
resolution support came out in 1.6; some searching of this group
should turn up good information too. The summary is that you can
either leave android:anyDensity=false in your manifest to let the
platform scale your bitmaps, or you can include bitmaps of different
sizes for different screen densities.

String

On Jan 16, 1:40 pm, Neilz neilhorn...@googlemail.com wrote:
 Hi all. So, I've been building an app which I test on my Hero, with a
 screen size of 480 x 320. The app is dependent upon Bitmap images,
 placing them at specific screen positions (i.e. Canvas.drawBitmap
 (bitmap, x, y, null) etc.).

 Now of course I face the problem of how this app will be compatible
 with new devices such as the Droid (854 x 480) and Nexus (480 x 800).
 Testing on the emulator seems to show that there will be a large part
 of the screen unused.

 What are the options here? Is there some way that the final Canvas
 output can be translated to fit a different screen size? Do I have to
 resize my bitmaps depending on the screen size, and translate the x, y
 positions accordingly?

 Any suggestions appreciated!
-- 
You received this message because you are subscribed to the Google
Groups Android Developers group.
To post to this group, send email to android-developers@googlegroups.com
To unsubscribe from this group, send email to
android-developers+unsubscr...@googlegroups.com
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en