<TableRow xmlns:android="http://schemas.android.com/apk/res/android"           android:id="@+id/admin_row"           android:layout_width="fill_parent"           android:layout_height="wrap_content"           android:gravity="center_horizontal">     <RelativeLayout android:layout_width="fill_parent"                     android:layout_height="fill_parent"                     android:orientation="horizontal"                     android:background="@color/silver"> 

如果你按照上面设置 你会发现你的背景色不能全面的扩充,所以应该把红色的部分放在tableRow 下作为属性。

2.

requestWindowFeature(Window.FEATURE_CUSTOM_TITLE); setContentView(R.layout.my_layout); getWindow().setFeatureInt(Window.FEATURE_CUSTOM_TITLE, R.layout.my_custom_title);

<resources>     <style name="LargeTitleTheme">         <item name="android:windowTitleSize">40dip</item>     </style> </resources> 

<activity android:name=".MyCustomTitleActivity" android:theme="@style/LargeTitleTheme" /> 

其中xml文件放在values下

或者使用

requestWindowFeature(Window.FEATURE_NO_TITLE); 

更多相关文章

  1. android listview 的一些属性
  2. 相对布局 RelativeLayout 常用属性介绍
  3. Android RelativeLayout用到的一些重要的属性
  4. android布局属性预览
  5. Android xml ListView 的divider属性
  6. 『ANDROID』android:layout_gravity和android:gravity属性的区别
  7. Android下xml中RelativeLayout布局常见属性

随机推荐

  1. fatal error: libavutil/avconfig.h: No
  2. gradle批量打包Android(安卓)apk:不同的包
  3. android自定义属性三部曲
  4. Android(安卓)NDK之JNI使用例子
  5. Android显示从网络下载图片偏小的问题
  6. 第一节 登录界面
  7. [置顶] 关于Flurry的一些用法
  8. Android(安卓)-- AsyncTask
  9. Android安装应用失败UID 和 PID
  10. Android(安卓)Studio Gradle编译 参数配