android 选项卡(TabHost)如何放置在屏幕的底部

Feronia ·
更新时间:2024-09-20
· 787 次阅读

今天写Tab的时候由于TAB的跳转问题去查资料,倒反而发现更有趣的问题,就是如何将TAB放置在屏幕的底端。
代码如下:
<?xml version="1.0" encoding="utf-8"?>
<TabHost xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@android:id/tabhost"
android:layout_width="fill_parent"
android:layout_height="fill_parent" >
<LinearLayout
android:layout_width="fill_parent"
android:layout_height="fill_parent"
android:orientation="vertical" >
<FrameLayout
android:id="@android:id/tabcontent"
android:layout_width="fill_parent"
android:layout_height="0dip"
android:layout_weight="1"
android:padding="5dp" />
<TabWidget
android:id="@android:id/tabs"
android:layout_width="fill_parent"
android:layout_height="wrap_content"
/>
</LinearLayout>
</TabHost>
您可能感兴趣的文章:Android TabHost选项卡标签图标始终不出现的解决方法Android组件TabHost实现页面中多个选项卡切换效果android TabHost(选项卡)的使用方法android中TabHost的图标(48×48)和文字叠加解决方法Android控件之TabHost用法实例分析Android TabLayout(选项卡布局)简单用法实例分析Android实现底部导航栏功能(选项卡)Android多个TAB选项卡切换效果Android仿微信底部实现Tab选项卡切换效果Android开发之TabHost选项卡及相关疑难解决方法



tabhost 选项卡 Android

需要 登录 后方可回复, 如果你还没有账号请 注册新账号