Search code examples
androidandroid-titlebar

How do I remove the title bar of my app?


I want to remove the title bar of the application, that is run out of that bar black with the name of the App.

Have followed the examples but always gives error initializing:
Example 1

 <application 
        android:icon="@drawable/icon" 
        android:label="@string/app_name" 
        android:theme="@android:style/Theme.NoTitleBar.Fullscreen">

Example 2

android:theme="@android:style/Theme.DeviceDefault.NoActionBar.Fullscreen"

My XML

  <application
        android:allowBackup="true"
        android:icon="@mipmap/ic_launcher"
        android:label="@string/app_name"
        android:theme="@style/AppTheme" >

Solution

  • this works for me:

    in style.xml:

    <style name="AppTheme" parent="android:Theme.NoTitleBar">
    </style>
    

    in AndroidManifest.xml

    <application
        android:theme="@style/AppTheme" 
        ...>