Kostya,

The background is specified in XML exactly as you suggested.  When I
click and hold on the widget to drag it, Android's outline box is larger
than the widget itself.  If I write code to invoke setBackgroundColor()
in lieu of setbackgroundresource() the color fills in a larger square
than does the background resource.  Doesn't all that indicate that there
is something about the PNG file, itself, that needs to be changed to
make it appear larger?

...Jake

>>>>> "KV" == Kostya Vasilyev <[email protected]> writes:

   KV> I just dropped the image into my project, and set it as an
   KV> android:background for a layout (activity, not wiget).

   KV> It worked fine.

   KV> It's a good sign that your widget is getting filled with color -
   KV> perhaps there is something unusual about how you set the
   KV> background?

   KV> I would try the simplest thing possible - set it with
   KV> android:background and remove any code that might touch that.

   KV> -- Kostya

   KV> 2011/6/20 Jake Colman <[email protected]>

   >> 
   >> Using some new preference settings in my widget, the user can completely
   >> replace the background image with a color.  When I do that, the painted
   >> area is quite a bit larger than the area covered when I use the
   >> background image.  I think that is the equivalent of what you asked me
   >> to check, correct?
   >> 
   >> ...Jake
   >> 
   >> 
   >> >>>>> "KV" == Kostya Vasilyev <[email protected]> writes:
   >> 
   KV> It looks fine, and enlarges properly in draw9patch.  Are you
   KV> certain the layout where it's used as the background actually
   KV> gets larger width and / or height?
   >> 
   KV> Try setting android:background="#FF008040" or some such to check.
   >> 
   KV> -- Kostya
   >> 
   KV> 2011/6/20 Nikolay Elenkov <[email protected]>
   >> 

   KV> -- 
   KV> You received this message because you are subscribed to the Google
   KV> Groups "Android Developers" group.
   KV> To post to this group, send email to [email protected]
   KV> To unsubscribe from this group, send email to
   KV> [email protected]
   KV> For more options, visit this group at
   KV> http://groups.google.com/group/android-developers?hl=en

-- 
Jake Colman -- Android Tinkerer

-- 
You received this message because you are subscribed to the Google
Groups "Android Developers" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/android-developers?hl=en

Reply via email to