Noob here, I want to remove the multiple headers(?) of the app(screenshot attached). The blue one came by default, I was able to remove it once but now I am not sure how did it. When I removed the blue one, I made a custom one to my liking. I'd want to know the best practice in this case, and also how to. I want the Logo of the app on the header(app title) along with the name. How can I do that?
Asked
Active
Viewed 101 times
2 Answers
0
The blue one
is actually ActionBar
or now you can say Toolbar
, and to remove that you add it to your styles.xml file located inside values
folder, for e.g :
<!-- Base application theme. -->
<style name="AppTheme" parent="Theme.AppCompat.Light.DarkActionBar">
<!-- Customize your theme here. -->
<item name="windowActionBar">false</item>
<item name="windowNoTitle">true</item>
</style>

Satyen Udeshi
- 3,223
- 1
- 19
- 26
-
That seems to be working. Is there a way by which I could add an image to it? Like the one I did with the second/custom Action Bar. I'd also like to change the color of notification bar so I guess using the default ActionBar would be a better choice. – shashankj May 31 '16 at 04:24
-
Yes you can do that, but for that you will have to set a `CustomView` to your `ActionBar` so i would suggest to go with `ToolBar` – Satyen Udeshi May 31 '16 at 04:27
-
-
and just FYI, changing **StatusBar** or **NotificationBar** color will be applicable from **API 21** for more info you can see this thread on SO http://stackoverflow.com/questions/22192291/how-to-change-the-status-bar-color-in-android – Satyen Udeshi May 31 '16 at 04:35
-
-
0
Use android:theme
<activity
android:name=".ABC"
android:label="@string/app_name"
android:theme="@android:style/Theme.Black.NoTitleBar" >
</activity>

D T
- 3,522
- 7
- 45
- 89