Need help with FlycoTabLayout?
Click the “chat” button below for chat support from the developer who created it, or find similar developers for support.

About the developer

10.4K Stars 2.3K Forks MIT License 40 Commits 363 Opened issues


An Android TabLayout Lib

Services available


Need anything else?

Contributors list

# 4,330
40 commits


Android Arsenal


An Android TabLayout Lib has 3 kinds of TabLayout at present.

  • SlidingTabLayout: deeply modified from PagerSlidingTabStrip.

    • new added attribute
    • new added kinds of indicators
    • new added unread msg tip
    • new added method for convenience
        /** no need to set titles in adapter */
        public void setViewPager(ViewPager vp, String[] titles)
    /** no need to initialize even adapter */
    public void setViewPager(ViewPager vp, String[] titles, FragmentActivity fa, ArrayList<fragment> fragments) 

  • CommonTabLayout:unlike SlidingTabLayout's dependence on ViewPager,it is a tabLayout without dependence on ViewPager and can be used freely with other widgets together.

    • support kinds of indicators and indicator animation
    • support unread msg tip
    • support icon and icon gravity.
    • new added method for convenience
        /** support switch fragments itself */
        public void setTabData(ArrayList tabEntitys, FragmentManager fm, int containerViewId, ArrayList fragments)
  • SegmentTabLayout


Change Log

v2.0.0(2016-03-01) - remove the dependence of FlycoRoundView - new added method getIconView and getTitleView

v2.0.2(2016-04-23) - remove the dependence of NineOldAnimation(only support 3.0+)


    compile ''
    compile 'com.nineoldandroids:library:2.4.0'
    compile 'com.flyco.roundview:FlycoRoundView_Lib:[email protected]'
    compile 'com.flyco.tablayout:FlycoTabLayout_Lib:[email protected]'

After v2.0.0 dependencies{ compile '' compile 'com.nineoldandroids:library:2.4.0' compile 'com.flyco.tablayout:FlycoTabLayout_Lib:[email protected]' }

After v2.0.2(support 3.0+) dependencies{ compile '' compile 'com.flyco.tablayout:FlycoTabLayout_Lib:[email protected]' }


|name|format|description| |:---:|:---:|:---:| | tlindicatorcolor | color |set indicator color | tlindicatorheight | dimension |set indicator height | tlindicatorwidth | dimension |set indicator width | tlindicatormarginleft | dimension |set indicator margin,invalid when indicator width is greater than 0. | tlindicatormargintop | dimension |set indicator margin,invalid when indicator width is greater than 0. | tlindicatormarginright | dimension |set indicator margin,invalid when indicator width is greater than 0. | tlindicatormarginbottom | dimension |set indicator margin,invalid when indicator width is greater than 0. | tlindicatorcornerradius | dimension |set indicator corner radius | tlindicatorgravity | enum |set indicator gravity TOP or BOTTOM. | tlindicatorstyle | enum |set indicator style NORMAL or TRIANGLE or BLOCK | tlunderlinecolor | color |set underline color | tlunderlineheight | dimension |set underline height | tlunderlinegravity | enum |set underline gravity TOP or BOTTOM | tldividercolor | color |set divider color | tldividerwidth | dimension |set divider width | tldividerpadding |dimension| set divider paddingTop and paddingBottom | tltabpadding |dimension| set tab paddingLeft and paddingRight | tltabspaceequal |boolean| set tab space equal | tltabwidth |dimension| set tab width | tltextsize |dimension| set text size | tltextSelectColor |color| set text select color | tltextUnselectColor |color| set text unselect color | tltextBold |boolean| set text is bold | tliconWidth |dimension| set icon width(only for CommonTabLayout) | tliconHeight |dimension|set icon height(only for CommonTabLayout) | tliconVisible |boolean| set icon is visible(only for CommonTabLayout) | tliconGravity |enum| set icon gravity LEFT or TOP or RIGHT or BOTTOM(only for CommonTabLayout) | tliconMargin |dimension| set icon margin with text(only for CommonTabLayout) | tlindicatoranimenable |boolean| set indicator support animation(only for CommonTabLayout) | tlindicatoranimduration |integer| set indicator animation duration(only for CommonTabLayout) | tlindicatorbounceenable |boolean| set indicator aniamtion with bounce effect(only for CommonTabLayout) | tlindicatorwidthequaltitle |boolean| set indicator width same as text(only for SlidingTabLayout)



We use cookies. If you continue to browse the site, you agree to the use of cookies. For more information on our use of cookies please see our Privacy Policy.