Ben Williamson wrote:
> Anyone know how to add shadows to custom drawable objects? I'm trying 
> to create a custom Dialog window with a translucent blurred background 
> and a shadow behind the content wrapped window.
>
> I have the following drawable...
>
> <shape xmlns:android="http://schemas.android.com/apk/res/android";>
> <solid android:color="#77DDDDDD" />
> <stroke android:width="2dp" android:color="#FFFFFF"/>
> <corners android:radius="10dp" />
> <padding android:right="5dp" android:top="4dp" android:bottom="4dp" />
> </shape>
>
> and I've tried several things, first I tried adding a shadow node, 
> with the shadow attrs shadowColor, shadowRadius, shadowDy and 
> shadowDx. I've also tried adding the shadow attrs to my style as such....
>
> <style name="Theme.CustomDialog" parent="android:style/Theme.Dialog">
> <item name="android:windowIsFloating">true</item>
> <item name="android:windowNoTitle">true</item>
> <item name="android:padding">10dp</item>
> <item name="android:backgroundDimAmount">0</item>
> <item name="android:windowBackground">@drawable/filled_box</item>
> <item name="android:shadowColor">#000000</item>
> <item name="android:shadowRadius">5</item>
> <item name="android:shadowDy">3</item>
> </style>
>
> Which creates a horrible looking shadow behind the text on the buttons.
>
> Anyone know how I can get the shadow on the window itself?
>
> Thanks for the help!
I see from this url 
http://code.google.com/android/reference/android/R.styleable.html that 
the shadow attributes I was using are for TextView.... anyone know of 
anyway to do this for a window? Apparently there are no built in 
attributes, what a bummer.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google
Groups "Android Beginners" 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-beginners?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to