android 抽取主题样式

1、定义style.xml文件

    <style name="ButtonSytle" parent="@style/Themestyle">      //继承style
        <item name="android:layout_width">wrap_content</item>
         <item name="android:layout_height">wrap_content</item>
          <item name="android:text">提交</item>
           <item name="android:layout_alignParentBottom">true</item>
    </style>

2、在控件中引用

     <Button 
        style="@style/ButtonSytle"
        android:textColor="#ff0000"/>

posted @ 2016-03-17 08:44  云中鹤5786  阅读(127)  评论(0编辑  收藏  举报