Search code examples
javascriptiostitaniumappcelerator

Appcelerator - How to change tab button style?


I'm working on Titanium and developing for iOS and I want to know if there's a way to change the style of the tab button in a tab. I want to make it look flat and with a different backgroundColor and remove the gradient it has.

I've tried the following:

var tab2 = Titanium.UI.createTab({

       title:'Members',
       window:peopleInGroup,
       backgroundColor : '#0f0',
       backgroundSelectedColor : '#0f0',
       backgroundFocusedColor : '#0f0'

});

But the backgroundColor didn't change. Also the text in the tab is aligned to the bottom but I want it to be in the center of the button. How can I change the style for the tab button?


Solution

  • In Appcelerator Titanium have no any method for change "TAB" BackgroundColor Change Yet.

    This have only BackgroundImage Change and Image Change,

    You can try custom Tab creation for Changing Color like this.