Giter Club home page Giter Club logo

Comments (7)

dariush-fathie avatar dariush-fathie commented on June 17, 2024

Mr Paolino Angeletti , bottomNavigationView now support badge

from badger.

SoftwareAdvise avatar SoftwareAdvise commented on June 17, 2024

i dont talk about bottomNavigationMenu, but tabLayout.
immagine

from badger.

SoftwareAdvise avatar SoftwareAdvise commented on June 17, 2024

maybe i can try setting a custom view to tab layout item .. I'll try and update you!

from badger.

SoftwareAdvise avatar SoftwareAdvise commented on June 17, 2024

it may be very usefull also on general views.

from badger.

tynn avatar tynn commented on June 17, 2024

Hej @PaolinoAngeletti @SoftwareAdvise, I'm sorry for the late reply. This library only intends to add badges to a Drawable, not to a View. The TabLayout is mostly text therefore this library might not be the right one for your needs. You might be able to use it with the background though.

from badger.

PaolinoAngeletti avatar PaolinoAngeletti commented on June 17, 2024

mmm yes, but we can round the problem setting tab item as a view.
so, if you can implement setting badge on a general view (you've done it for image view, maybe you can do it with View, too) i can implement a way to solve the problem, and if you want i can explain this way to you..

from badger.

tynn avatar tynn commented on June 17, 2024

Which Drawable from a plain View would you choose? But if you have a good use-case for yourself, you could just implement the method within your domain. The method for ImageView is just three lines of code wrapping around sett(Drawable,Factory):

public static <T extends BadgeDrawable> T sett(@NonNull ImageView view, @NonNull BadgeDrawable.Factory<? extends T> factory) {
    Badger<T> badger = sett(view.getDrawable(), factory);
    view.setImageDrawable(badger.drawable);
    return badger.badge;
}

from badger.

Related Issues (8)

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.