Actionbar not showing in the development preview but showing normally after running the app, minimum api is 15, tried to delete the them from the manifest file, didn't show the actionbar, and can't run the app anymore.
It is a completely new project (tried deleting it and recreating it and creating several other with different minimum api, still not showing in the development)
My theme is blank with a parent "parent="Theme.AppCompat.Light.DarkActionBar""
Trying to use a holo light theme, crashed and got that error "java.lang.IllegalStateException: You need to use a Theme.AppCompat theme (or descendant) with this activity."
Default activity extends actionbaractivity instead of activity, fixed now. Thanks
Android ActionBar is a menu bar that runs across the top of the activity screen in android. Android ActionBar can contain menu items which become visible when the user clicks the “menu” button.
The Toolbar is basically the advanced successor of the ActionBar. It is much more flexible and customizable in terms of appearance and functionality. Unlike ActionBar, its position is not hardcoded i.e., not at the top of an activity.
You may otherwise add the action bar by calling requestFeature(FEATURE_ACTION_BAR) or by declaring it in a custom theme with the windowActionBar property. Beginning with Android L (API level 21), the action bar may be represented by any Toolbar widget within the application layout.
If you can't see the action bar AND also the status bar or buttons, it could be because the "Show Layout Decorations" options is turned off in the Layout Editor. Just check this option and everything should be displayed again. As per Android Studio 3.3:
Check which theme is selected on the top of the XML preview screen.
Even if you're using Eclipse, it will look similar.
Your application is displaying the ActionBar because your AndroidManifest has a theme which displays the ActionBar.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With