I'm writing an appwidget and the main part of it will be a bitmap that I create. I've been unable to find a way to programatically find out what the size of the appwidget is.
I know how to request that I get a 4 x 1 size widget, but I don't think I can assume that my widget will be a specific size in pixels across all phones though (or even proportionally the same). Drawing the bitmap myself seems like the best thing to do since it's mostly parts of other graphics and the contents and amount of graphics will change depending on what I need to display. I would have preferred to dynamically build a layout for the RemoteViews, but it's not supported in SDK version 3 which is a requirement for my widget to support.
Anyway, I want to be able to take advantage of the maximum amount of pixels I have and would rather not have my bitmap stretched/shrunk, so knowing how many pixels I have is what I need. Anyone know how to do this?
I know how to request that I get a 4 x 1 size widget, but I don't think I can assume that my widget will be a specific size in pixels across all phones though (or even proportionally the same). Drawing the bitmap myself seems like the best thing to do since it's mostly parts of other graphics and the contents and amount of graphics will change depending on what I need to display. I would have preferred to dynamically build a layout for the RemoteViews, but it's not supported in SDK version 3 which is a requirement for my widget to support.
Anyway, I want to be able to take advantage of the maximum amount of pixels I have and would rather not have my bitmap stretched/shrunk, so knowing how many pixels I have is what I need. Anyone know how to do this?