Is is possible to set an item with two colors on the tab bar?
(I'm a beginner in swift)
What I want to achieve:
I want to have something-like a white background for each item in both active and inactive states.
What I have tried so far:
I've been trying by using a png with transparency, white color and black color but it seems that anyhing that is not a transparent pixel is taken as the same color. (The asset I've working with is rendered as a whole color image instead of differentiating black and white)
-> The asset I thought it would work
What I think its the way but don't know how:
(This is an assumption)
I think this could be done by setting an inactive item in the background (first layer, white color) and an active item (second layer, black color) in the same coordinates with the color I want to change:
-> Two assets for Layer 1 and layer 2
I'm using an storyboard with storyboard references to set initial configuration for the assets of both active an inactive states.
I'm setting active state color programatically.
Suggestions to achive this in more elegant ways are welcome.
Thank you :)