GithubHelp home page GithubHelp logo

Comments (6)

Hi-Mike avatar Hi-Mike commented on July 26, 2024 4

给后来的人看,两张图片在selector中不tint,设置setItemIconTintList为null就好

from bottomnavigationviewex.

ittianyu avatar ittianyu commented on July 26, 2024

把这两个属性删掉,就不会改颜色了

app:itemIconTint="@color/selector_item_gray_color"
app:itemTextColor="@color/selector_item_gray_color"

menu 里面用 selector 实现选中和未选中使用两张图片,请参考 https://github.com/ittianyu/BottomNavigationViewEx/blob/master/app/src/main/res/menu/menu_navigation_selector.xml

渐变好像没办法实现,现在多种状态图片切换一般都是用 selector,如果你能实现就试试吧。

from bottomnavigationviewex.

drowtram avatar drowtram commented on July 26, 2024

selector切换没有问题,但是我去掉那两个属性,貌似也会给我的icon默认渲染一层colorPrimary这个色值

from bottomnavigationviewex.

ittianyu avatar ittianyu commented on July 26, 2024

那是背景颜色,去掉 backgroundColor 就行

from bottomnavigationviewex.

drowtram avatar drowtram commented on July 26, 2024

算了,我已经说服UI给把渐变去了,就这样也能满足要求了,😄😄😄

from bottomnavigationviewex.

panyy avatar panyy commented on July 26, 2024

@Hi-Mike 谢谢

from bottomnavigationviewex.

Related Issues (20)

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.