Code example for GradientDrawable

Methods: setCornerRadius, setStroke

0
	Paint plane = new Paint();
	Paint redSolid = new Paint();
 
	GradientDrawable groundGradient = new GradientDrawable(
			GradientDrawable.Orientation.TOP_BOTTOM, new int[] { 0xc0d4a017,
					0xc0835c3b }); // Caramel to Brown Bear 
 
	private String altitude = "";
	private String remainBatt = "";
	private String battVolt = "";
	private String gpsFix = "";
 
	public HUD(Context context, AttributeSet attributeSet) {
		super(context, attributeSet);
		// getHolder().addCallback(this); 
 
		grid_paint.setColor(Color.rgb(100, 100, 100));
 
		groundGradient.setCornerRadius(0);
		groundGradient.setStroke(0, 0);
 
		// Per http://www.computerhope.com/htmcolor.htm 
		// Copper 
		ground.setARGB(220, 0xb8, 0x73, 0x33);
		sky.setARGB(220, 0, 113, 188);