会了,加个android:gravity="center"即可
解决方案 »
- Andriod调用SQLite数据库的问题
- Android录制视频时使用LocalSocket进行处理
- 这个Activity有什么错误呢????
- 这段测试用例怎么写?(新手求教)
- 有谁用过apkplug框架开发过应用?
- [color=#FF0000]用过actionbarsherlock的进来看看,关于修改actionbarsherlock标题栏[/color]
- 问个支付宝手机网页支付的问题。
- Qt for Android 在工程项目->构建下 ,出现不兼容的构建
- Phonegap怎么打开Android创建的数据库
- 小白 今天装了android studio 遇到了点问题 求大佬指教
- 菜单问题
- 请问如何设置AlertDialog的样式?
页面跳转可以考虑换View而不换Activity。当然,看情况了。
<?xml version="1.0" encoding="UTF-8"?>
<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:layout_width="fill_parent" android:layout_height="wrap_content">
<TableLayout android:layout_width="fill_parent"
android:layout_height="wrap_content" android:background="#ffbbcc"
android:stretchColumns="*">
<TableRow>
<ImageView android:src="@drawable/icon" android:id="@+id/game01">
</ImageView>
<ImageView android:src="@drawable/icon" android:id="@+id/game02">
</ImageView>
<ImageView android:src="@drawable/icon" android:id="@+id/game03">
</ImageView>
</TableRow>
<TableRow>
<TextView android:id="@+id/text01" android:textColor="#000000"
android:text="游戏" android:layout_below="@id/game01"
android:layout_alignLeft="@id/game01" android:gravity="center" />
<TextView android:id="@+id/text02" android:textColor="#000000"
android:text="游戏" android:layout_below="@id/game01"
android:layout_toRightOf="@id/text01" android:gravity="center" />
<TextView android:textColor="#000000" android:text="游戏"
android:layout_below="@id/game01" android:layout_toRightOf="@id/text02"
android:gravity="center" />
</TableRow>
</TableLayout>
</RelativeLayout>
效果: