On Aug 29, 5:53 pm, Ash wrote:
> I am trying to get rid of the XML file and do everything using code. Please
> let me know if this is possible.
That's like swimming upstream - possible but not always an easy task
--
You received this message because you are subscribed to the Google
Groups "Andr
Thanks for sharing the sample code. Wonderful.
What about giving corners to the default Android button. At present I have
an xml file which does this
I am trying to get rid of the XML file and do everything using code. Please
let me know if this is possible.
--
You re
Just don't try to draw the gradient in ondraw with hardware acceleration turned
on
On Aug 26, 2011, at 10:57 AM, Andrew Pierce wrote:
> Use a GradientDrawable:
>
> int[] colors = new int[] { 0xFFB3ADAD, 0xFF858080 };
> GradientDrawable drawable = new
> GradientDrawable(GradientDrawable.Orienta
Use a GradientDrawable:
int[] colors = new int[] { 0xFFB3ADAD, 0xFF858080 };
GradientDrawable drawable = new
GradientDrawable(GradientDrawable.Orientation.TOP_BOTTOM, colors);
drawable.setShape(GradientDrawable.RECTANGLE);
drawable.setGradientType(GradientDrawable.LINEAR_GRADIENT);
On Aug 25, 7:2
Sure! That XML just creates a LinearGradient object. Look here:
http://developer.android.com/reference/android/graphics/LinearGradient.html
-blake
On Aug 25, 5:23 pm, Ash wrote:
> Currently I have an XML file which sets the gradient of the button
> background.
> Is it possible to achieve the
5 matches
Mail list logo