All Projects → ypicoleal → FancyTab

ypicoleal / FancyTab

Licence: MIT License
No description or website provided.

Programming Languages

java
68154 projects - #9 most used programming language

Projects that are alternatives of or similar to FancyTab

Notzz App
📝 A Simple Note-Taking App built to demonstrate the use of Modern Android development tools - (Kotlin, Coroutines, State Flow, Hilt-Dependency Injection, Jetpack DataStore, Architecture Components, MVVM, Room, Material Design Components).
Stars: ✭ 158 (+953.33%)
Mutual labels:  android-development, android-ui, android-studio
android-custom-view
No description or website provided.
Stars: ✭ 15 (+0%)
Mutual labels:  android-development, android-ui, android-studio
Customrefreshview
一个支持网络错误重试,无数据页(可自定义),无网络界面(可自定义)的上拉加载更多,下拉刷新控件
Stars: ✭ 160 (+966.67%)
Mutual labels:  android-development, android-ui, android-studio
Android Inappbilling
A sample which uses Google's Play Billing Library and it does InApp Purchases and Subscriptions.
Stars: ✭ 114 (+660%)
Mutual labels:  android-development, android-ui, android-studio
Reside-Menu
By applying viewpager animation you can also make AMAZING Reside Menu's
Stars: ✭ 72 (+380%)
Mutual labels:  android-development, android-ui, android-studio
Anychart Android
AnyChart Android Chart is an amazing data visualization library for easily creating interactive charts in Android apps. It runs on API 19+ (Android 4.4) and features dozens of built-in chart types.
Stars: ✭ 1,762 (+11646.67%)
Mutual labels:  android-development, android-ui, android-studio
Modern Android Development
Modern Android Development tools & key points
Stars: ✭ 219 (+1360%)
Mutual labels:  android-development, android-ui, android-studio
Zoomrecylerlayout
🎢 Zoom Recycler Layout Manager For Android Kotlin
Stars: ✭ 618 (+4020%)
Mutual labels:  android-development, android-ui, android-studio
Whatsapp Android App
This is sample code for layout for chatting app like Whatsapp.
Stars: ✭ 32 (+113.33%)
Mutual labels:  android-development, android-ui, android-studio
GitReposCompose
GitReposCompose is an Android application 📱 for showcasing Jetpack Compose for building declarative UI in Android. This demo app uses Github public API for fetching public repositories.
Stars: ✭ 32 (+113.33%)
Mutual labels:  android-development, android-ui, android-studio
Cameraxdemo
A sample camera app with CameraX API from Android Jetpack
Stars: ✭ 112 (+646.67%)
Mutual labels:  android-development, android-ui, android-studio
media-picker
Easy customizable picker for all your needs in Android application
Stars: ✭ 167 (+1013.33%)
Mutual labels:  android-development, android-ui, android-studio
Mediapicker
Easy customizable picker for all your needs in Android application
Stars: ✭ 105 (+600%)
Mutual labels:  android-development, android-ui, android-studio
Ibackdrop
A library to simply use Backdrop in your project (make it easy). Read more ->
Stars: ✭ 137 (+813.33%)
Mutual labels:  android-development, android-ui, android-studio
Androidkex
Extensions for Kotlin. Use the power of Kotlin to make your code smaller and beautiful.
Stars: ✭ 35 (+133.33%)
Mutual labels:  android-development, android-ui, android-studio
Advancedrecycleview
♻ RecycleView with multiple view types, inner horizontal RecycleView and layout animation
Stars: ✭ 172 (+1046.67%)
Mutual labels:  android-development, android-ui, android-studio
Awesome Android Ui
😎 A curated list of awesome Android UI/UX libraries
Stars: ✭ 353 (+2253.33%)
Mutual labels:  android-development, android-ui, android-studio
VideoPreLoading
Demo for video PreLoading/ PreCaching using ExoPlayer 2.13.3 in Android.
Stars: ✭ 61 (+306.67%)
Mutual labels:  android-development, android-ui, android-studio
Biometric-Authentication-Android
A sample implementation of AndroidX biometrics API using Kotlin. Authenticate using biometrics or PIN/Password if biometrics isn't available on device. Fully implemented in Jetpack compose using Material 3 dynamic theming and also has a separate implementation in xml with MDC 3.
Stars: ✭ 29 (+93.33%)
Mutual labels:  android-development, android-ui, android-studio
Android-daily-read-tips
log for articles and info in android for every developer
Stars: ✭ 13 (-13.33%)
Mutual labels:  android-development, android-ui, android-studio

Fancy Tab

A Tab layout inspired by the two shots "Scene Club Tickets. Interaction" and "Two Invites App" by Yaroslav Zubko

Demo:

alt text alt text

Usage

Add to your Android layout xml:

<com.github.ypicoleal.fancytablayout.FancyTabLayout
            android:id="@+id/tabs"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            app:tabFormat="onlyText" />

The options for the tabFormat are onlyText, imgTitle and onlyImg

Then in your activity bound it with your viewPager

FancyTabLayout tabLayout = (FancyTabLayout) findViewById(R.id.tabs);
tabLayout.setupWithViewPager(mViewPager);

If you are going to use the options imgTitle or onlyImg for tabFormat your FragmentPagerAdapter class will have to extend from FancyFragmentPageAdapter eg:

    private class SectionsPagerAdapter extends FancyFragmentPageAdapter {

        SectionsPagerAdapter(FragmentManager fm) {
            super(fm);
        }

        @Override
        public Object getPageImageURL(int position) {
            //your code about the url of the image
        }

        @Override
        public Fragment getItem(int position) {
            return PlaceholderFragment.newInstance(position);
        }

        @Override
        public int getCount() {
            return 10;
        }

        @Override
        public CharSequence getPageTitle(int position) {
            return "PAGE " + (position + 1)
        }
    }

And set the ImageLoader for the layout:

tabLayout.setImageLoader(new FancyTabLayout.ImageLoader() {
    @Override
    public void loadImage(ImageView view, Object url) {
        Picasso.with(MainActivity.this)
               .load((String) url)
               .placeholder(R.drawable.cube_closed_128)
               .into(view);
    }
});

Installation

Add jitpack.io to your root build.gradle, eg:

allprojects {
    repositories {
        jcenter()
        maven { url "https://jitpack.io" }
    }
}

then add the dependency to your project build.gradle:

dependencies {
    ...
    compile 'com.github.ypicoleal:FancyTab:0.0.2'
}

Notes

This library is in alpha state currently, if you hava a question or find an error please open an issue i will keep working in this project

License

MIT License

Copyright (c) 2017 Yamid Pico

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].