Coder Social home page Coder Social logo

liuhang1234 / dsltablayout Goto Github PK

View Code? Open in Web Editor NEW

This project forked from angcyo/dsltablayout

0.0 1.0 0.0 31.17 MB

:hearts: Android界最万能的TabLayout(不仅仅是TabLayout), 支持任意类型的item, 支持Drawable类型的指示器,智能开启滚动,支持横竖向布局等

Home Page: https://github.com/angcyo/DslAdapter

License: MIT License

Kotlin 100.00%

dsltablayout's Introduction

DslTabLayout

API GitHub branch checks state GitHub AndroidX GitHub top language JitPack

GitHub code size in bytes GitHub repo size GitHub last commit GitHub issues GitHub Repo stars GitHub forks

♥️ Android界最万能的TabLayout(不仅仅是TabLayout). 高能自绘控件, 继承自ViewGroup, 非组合控件.

Gitee仓库地址

文档地址

特性

  1. 支持任意类型的child视图.
  2. 支持任意类型Drawable指示器.
  3. 支持智能开启横向滚动.
  4. 支持智能开启平分item宽度(1.5.4后).
  5. 支持高凸模式, 允许某个child高出一节显示.
  6. 支持滑动选择模式, 滑动的时候智能选择上一个下一个.
  7. 支持角标配置.
  8. 支持ViewPagerViewPager2
  9. 支持竖向(2.0.0后)
  10. 支持指示器居中 靠左 靠右展示(2.1.0后)
  11. 支持选中后突出异形效果(2.2.0后)
  12. 支持RTL(3.0.0后, minSdk>=17)
  13. 支持指示器颜色滑动渐变效果(3.0.1后)
  14. 支持指示器闪现效果(3.1.0后)

直接当做横向/竖向LinearLayout使用方式即可, 无特殊要求.

入门使用

点击查看全部属性

点击查看事件回调

点击查看角标使用

关联ViewPager使用(兼容ViewPager2)

效果

一个DSLTabLayout可实现以下3中效果

高能自绘控件, 继承自ViewGroup, 非组合控件.

无需选择, xml配置即可, 还不赶紧收下?

带滚动效果和角标
带滚动效果和角标
普通和高凸效果
普通和高凸效果
带边框,分割线和滑动选择效果
分割线和滑动选择效果

竖向效果

竖向效果

竖向效果

竖向效果

突出效果

突出效果

突出效果

闪现效果

闪现效果

使用JitPack的方式, 引入库.

根目录中的 build.gradle

allprojects {
    repositories {
        ...
        maven { url 'https://jitpack.io' }
    }
}

APP目录中的 build.gradle

dependencies {
    implementation 'com.github.angcyo.DslTablayout:TabLayout:3.5.3'

    //可选
    implementation 'com.github.angcyo.DslTablayout:ViewPager1Delegate:3.5.3'
    //可选
    implementation 'com.github.angcyo.DslTablayout:ViewPager2Delegate:3.5.3'
}

更新日志

下载体验

扫码安装

扫码安装

License

FOSSA Status


群内有各(pian)种(ni)各(jin)样(qun)的大佬,等你来撩.

联系作者

点此QQ对话 该死的空格 点此快速加群

开源地址

扫码进群

给点鼓励

Stargazers over time

Stargazers over time

dsltablayout's People

Contributors

angcyo avatar

Watchers

James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.