1. Use your Android system's own transparent effects resources
<button Android:background= "@android: Color/transparent"/>2. Use ARGB to controlTranslucent<button android:background= "#e0000000"/>Transparent<button android:background= "#00000000"/>
The color and opacity (alpha) values are represented by hexadecimal notation. The range of values for any one color is 0 to 255 (00 to FF). For alpha,00, full transparency is expressed, and FF is completely opaque. The expression order is "Aabbggrr", where "Aa=alpha" (00 to FF); Bb=blue "(00 to FF); Gg=green "(00 to FF); Rr=red "(00 to FF). For example, if you want to apply a blue 50% opacity to an overlay, you should specify the following values: 7fff00003. Set the AlphaView v = Findviewbyid (r.id.content);//Find the ID of the layout you want to set the transparent backgroundV.getbackground (). Setalpha (+);//Transparency 0~255 transparency value, the smaller the value the more transparent
Three ways to set transparency on Android course---android (go)