Thanks! It worked great for what I needed to do.
On Sep 23, 11:39 pm, kostmo <[email protected]> wrote:
> On Sep 9, 11:46 am, Sam <[email protected]> wrote:
>
> > Hi,
>
> > On a layout I want toscalethebackgroundimage (keeping it's aspect
> > ratio) to the space allocated when the page gets created. Anyone have
> > any idea how to do this?
>
> > I am using layout.setBackgroundDrawable() and am using a
> > BitmapDrawable to setGravity for clipping and filling, but don't see
> > any option for scaling.
>
> > Sam
>
> An old post suggested subclassing
> Drawable:http://groups.google.com/group/android-beginners/browse_thread/thread...
>
> I have done that here:http://www.anddev.org/viewtopic.php?p=27178#27178
>
> Also, for the original post, which I can't reply to anymore, the
> question was how to "Prevent image stretching in backgrounds". I
> believe an InsetDrawable would be appropriate for
> that.http://developer.android.com/reference/android/graphics/drawable/Inse...
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---