文字の色を変更する
2011年2月12日(土) 10:43 PM
文字の色を変更するには、
AndroidManifest.xmlで
android:textColor=”#ffcc7a7a”を設定すればいいです。
” “で指定できるのは、”#rgb”, “#argb”, “#rrggbb”, “#aarrggbb”のいずれかです。
a: Alpha Channel(アルファチャネル)(透明度)
r: Red(赤)
g: Green(緑)
b: Blue(青)
<?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" android:orientation="vertical" android:layout_width="fill_parent" android:layout_height="fill_parent" android:background="@drawable/bg" > <Button android:id="@+id/myButton" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="次のActivityへ" android:textColor="#ffcc7a7a" /> </LinearLayout>
その他のコードは、背景画像を加える。
と同じです。
Tag:
コメントの更新情報
トラックバックURL
https://appli-info.jp/2011/02/12/%e6%96%87%e5%ad%97%e3%81%ae%e8%89%b2%e3%82%92%e5%a4%89%e6%9b%b4%e3%81%99%e3%82%8b/trackback/