如何在iOS中完全定制TabBar
我需要在iOS应用程序中自定义如何在iOS中完全定制TabBar,ios,swift,swift3,uitabbar,uitabbaritem,Ios,Swift,Swift3,Uitabbar,Uitabbaritem,我需要在iOS应用程序中自定义选项卡栏,如图所示 我需要更改背景色、未选择的图像着色颜色和选择的图像着色颜色。如何设置uitabar的barTintColor和tintColor属性 self.tabBarController?.tabBar.barTintColor = .blue //Background Color self.tabBarController?.tabBar.tintColor = .yellow //Selected Item tint color 注意:如果两个状态都
选项卡栏
,如图所示
我需要更改背景色、未选择的图像着色颜色和选择的图像着色颜色。如何设置
uitabar
的barTintColor
和tintColor
属性
self.tabBarController?.tabBar.barTintColor = .blue //Background Color
self.tabBarController?.tabBar.tintColor = .yellow //Selected Item tint color
注意:如果两个状态都有图像,则表示默认和选中,然后为其集合设置两个图像,选中可为选项卡项设置选定图像。现在,如果您不知道如何设置该检查,请在“资源”中将两幅图像的渲染模式设置为原始图像
。您尝试过这个吗