How to change textcolor of tab text in Android
TabHost tabs = (TabHost)findViewById(R.id.TabHost01);
tabs.setup(getLocalActivityManager());
TabHost.TabSpec search = tabs.newTabSpec("tag1");
search.setContent(new Intent(this,Searchgurbani.class));
search.setIndicator("Find Me");
tabs.addTab(search);
TabHost.TabSpec pref = tabs.newTabSpec("tag5");
pref.setContent(new Intent(this,Preferencegurbani.class));
pref.setIndicator("Settings");
tabs.addTab(pref);
TabHost.TabSpec favorite = tabs.newTabSpec("tag6");
favorite.setContent(new Intent(this,Favroite.class));
favorite.setIndicator("BookMark");
tabs.addTab(favorite);
for(int i=0;i<tabs.getTabWidget().getChildCount();i++)
{
TextView tv = (TextView) tabs.getTabWidget().getChildAt(i).findViewById(android.R.id.title);
tv.setTextColor(Color.parseColor("#ffffff"));
}
tabs.setup(getLocalActivityManager());
TabHost.TabSpec search = tabs.newTabSpec("tag1");
search.setContent(new Intent(this,Searchgurbani.class));
search.setIndicator("Find Me");
tabs.addTab(search);
TabHost.TabSpec pref = tabs.newTabSpec("tag5");
pref.setContent(new Intent(this,Preferencegurbani.class));
pref.setIndicator("Settings");
tabs.addTab(pref);
TabHost.TabSpec favorite = tabs.newTabSpec("tag6");
favorite.setContent(new Intent(this,Favroite.class));
favorite.setIndicator("BookMark");
tabs.addTab(favorite);
for(int i=0;i<tabs.getTabWidget().getChildCount();i++)
{
TextView tv = (TextView) tabs.getTabWidget().getChildAt(i).findViewById(android.R.id.title);
tv.setTextColor(Color.parseColor("#ffffff"));
}
Excellent information, I like your post.
ReplyDeleteBest Software Development Company in Kolkata
Best Android Application Development Company in kolkata
Best Web Design Company in kolkata