简体   繁体   中英

How to change background color of bottomnavigationItem?

I tried following code but it does not working

BottomNavigationBarItem(
            icon: SvgPicture.asset("assets/icons/tinpay3.svg"),
            label: "TINPAY",
            backgroundColor: Color.fromRGBO(255, 194, 44, 1.0),
           )

I want to change background color like that. 在此处输入图片说明 . SO How to change background color of bottomnavigationItem?

BottomNavigationBar has these color arguments:

fixedColor: ...,
backgroundColor: ...,
selectedItemColor: ...,
unselectedItemColor: ...,

and BottomNavigationBarItem has:

backgroundColor: ...,

Maybe you should use them?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM