android-viewpager-indicator

码农软件 · 软件分类 · Android UI 组件 · 2019-04-26 21:13:52

软件介绍

一、简介

android-viewpager-indicator 是 Tab+ViewPager 切换控件。
GitHub地址:https://github.com/panxw/android-viewpager-indicator

二、使用示例

1. Android 布局文件:

    <com.allthelucky.common.view.ViewPagerIndicatorView
    android:id="@+id/viewpager_indicator_view"
    android:layout_width="match_parent"
    android:layout_height="wrap_content" />

2. 在 Java 代码中设置 ViewPagerIndicatorView:

    ViewPagerIndicatorView viewPagerIndicatorView; = (ViewPagerIndicatorView) findViewById(R.id.viewpager_indicator_view);
    final Map<String, View> map = new HashMap<String, View>();
    map.put("TAB1", LayoutInflater.from(this).inflate(R.layout.activity_sample_pager_0, null));
    map.put("TAB2", LayoutInflater.from(this).inflate(R.layout.activity_sample_pager_1, null));
    viewPagerIndicatorView.setupLayout(map);

3.效果图

ScreenShot

PS:
顺便宣传下自己的GitHub,https://github.com/panxw, 欢迎来Follow~

本文地址:https://codercto.com/soft/d/4457.html

一站式学习C编程

一站式学习C编程

宋劲杉 / 电子工业出版社 / 2011-3 / 59.00元

《一站式学习c编程》有两条线索,一条线索是以linux平台为载体全面深入地介绍c语言的语法和程序的工作原理,另一条线索是介绍程序设计的基本思想和开发调试方法。本书分为两部分:第一部分讲解编程语言和程序设计的基本思想方法,让读者从概念上认识c语言;第二部分结合操作系统和体系结构的知识讲解程序的工作原理,让读者从本质上认识c语言。 《一站式学习c编程》适合做零基础的初学者学习c语言的第一本教材,......一起来看看 《一站式学习C编程》 这本书的介绍吧!

CSS 压缩/解压工具
CSS 压缩/解压工具

在线压缩/解压 CSS 代码

XML、JSON 在线转换
XML、JSON 在线转换

在线XML、JSON转换工具

XML 在线格式化
XML 在线格式化

在线 XML 格式化压缩工具