设为首页 加入收藏

TOP

Android 滚动Tab(二)
2014-11-24 03:32:23 来源: 作者: 【 】 浏览:1
Tags:Android 滚动 Tab
vertical" >
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:drawableTop="@drawable/me"
android:text="@string/about_me_email"/>


然后是AboutMeFragment.java


import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import com.lichen.remind.R;
public class AboutMeFragment extends Fragment {
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {
View rootView = inflater.inflate(R.layout.fragment_about_me,container, false);
return rootView;
}
}


--------------------------------------------------------------------------------


资源文件strings.xml中, 使用了传入参数的方式.


< xml version="1.0" encoding="utf-8" >

Remind
Settings
关于我
chain_li7@163.com
%1$d 个Tab
这是第 %1$d 个Tab页面


--------------------------------------------------------------------------------


这样就可以看到上图滚动Tab了.


首页 上一页 1 2 下一页 尾页 2/2/2
】【打印繁体】【投稿】【收藏】 【推荐】【举报】【评论】 【关闭】 【返回顶部
分享到: 
上一篇Android Action Bar 加入Back返回.. 下一篇Android Action Bar 自定义View

评论

帐  号: 密码: (新用户注册)
验 证 码:
表  情:
内  容:

·MySQL 安装及连接-腾 (2025-12-25 06:20:28)
·MySQL的下载、安装、 (2025-12-25 06:20:26)
·MySQL 中文网:探索 (2025-12-25 06:20:23)
·Shell脚本:Linux Sh (2025-12-25 05:50:11)
·VMware虚拟机安装Lin (2025-12-25 05:50:08)