去掉app的标题

方法一:

当继承自ActivityActionBarActivity时,在setContentView(...)方法前调用

requestWindowFeature(Window.FEATURE_NO_TITLE);

当继承自AppCompatActivity时,就无效了,必须采用方法五。

方法二:在activity节点下设置

theme:android:theme=”@android:style/Theme.Black.NoTitleBar” 黑色背景

android:theme=”@android:style/Theme.Light.NoTitleBar” 白色背景

“android:Theme.Holo.Light.NoActionBar”白底(包含alertDialog)

方法三:所有的value目录下的style文件修改为(不加@也可以)

style name=”AppBaseTheme” parent=”@android:style/Theme.Light.NoTitleBar”

方法四:application节点下的theme替换为:

android:theme=”@android:style/Theme.Black.NoTitleBar”
android:theme=”@android:style/Theme.Light.NoTitleBar”
android:theme=”@android:style/Theme.NoTitleBar”

方法四:

<style name="AppTheme" parent="AppBaseTheme">    -- All customizations that are NOT specific to a particular API-level can go here. -->    <item name="android:windowNoTitle">trueitem>style>

方法五:

//隐藏标题栏ActionBar actionBar = getSupportActionBar();//ActionBar actionBar = getActionBar();actionBar.hide();

更多相关文章

  1. Android Studio 中方法数65536 或超过64K的解决方案
  2. Android SDK使用迅雷下载方法
  3. Android应用程序启动时发生AndroidRuntime : ClassNotFoundExcep
  4. Android的Activity的launchMode与onActivityResult方法的关系
  5. Android DrawerLayout和NavigationView 的使用方法
  6. Android编译本地C++程序方法
  7. Android开发者网站打不开的解决方法
  8. android sdk manager 无法更新解决方法
  9. Delphi XE5 for android 使用 BITMAP STYLE DESIGNER 改变控件背

随机推荐

  1. Android之NDK开发
  2. textView 和 edittext 的一些属性
  3. RelativeLayout各个属性
  4. TextView 实现跑马灯效果
  5. 1. Android(安卓)环境搭建
  6. android:layout_gravity 居中布局
  7. Android(安卓)Web Server
  8. Android录音AudioRecord,AudioTrack学习
  9. Android(安卓)生成keystore,两种方式 【包
  10. 系出名门Android(4) - 活动(Activity),