Customizing action bar in android shows default action bar first -
I am new to Android, while while customizing the action bar, I saw that it was the first old (default) action bar Shows first, it shows the customized action bar. Also, I want to set the text color for the title of action bar. My code snippet is
public class MainActivity ActionBarActivity Extension (MenuItem searchItem; Search View Searchview; @ Override Protected Zero to Create (Bundle Saved Instantstate) {Super.Nocrat (Saved Instantstate); Actionbar AB = MillSport ActionBar (); ab.setTitle ("Amendment"); ab.setIcon (R.drawable.ap); Ab.setBackgroundDrawable (New ColorDrawable (Color.parseColor ("# 00AA00")); ab.setSubtitle (" Amendment "); setContentView (R.layout.activity_main);
I think there should be some stupid mistake.
please
Try it out ..
Create a Theme.xml as
Comments
Post a Comment