ActionBar更改背景颜色(主题)
1.默认是黑色的背景,
2.更改主题theme为Theme.AppCompat.Light即可,清单文件主题如下:
<application
android:name="com.itheima.googleplay.global.GooglePlayApplication"
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
android:theme="@style/Theme.AppCompat.Light" >
<activity
android:name="com.itheima.googleplay.ui.activity.MainActivity"
android:label="@string/app_name" >
<intent-filter>
<action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name="com.itheima.googleplay.ui.activity.HomeDetailActivity" >
</activity>
</application>
也可以单独更改某个activity的theme,清单文件:
<application
android:name="com.itheima.googleplay.global.GooglePlayApplication"
android:allowBackup="true"
android:icon="@drawable/ic_launcher"
android:label="@string/app_name"
>
<activity
android:name="com.itheima.googleplay.ui.activity.MainActivity"
android:label="@string/app_name"
android:theme="@style/Theme.AppCompat.Light" >
<intent-filter>
<action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity android:name="com.itheima.googleplay.ui.activity.HomeDetailActivity" >
</activity>
</application>
效果如下图:

ActionBar更改背景颜色(主题)的更多相关文章
- NotePad++更改背景颜色
白色的编辑框看得眼睛不舒服,怎么样更改NotePad++的背景颜色使眼睛更舒服些? 1.设置--语言格式设置 2.设置背景色 “背景色”一栏,选择背景色颜色 “使用全局背景色”一栏要打上√,否则无 ...
- vs code 的背景颜色主题还有背景图片的自定义方法
先说颜色主题吧: 依次点击文件--->首选项---->颜色主题 你就可以看到不同的颜色主题了 如果你还觉得不好看,不满意,不符合你的审美风格 你还可以在插件库里面下载相关插件: THEME ...
- table tr列 鼠标经过时更改背景颜色
<html> <head> <meta http-equiv="Content-Type" content="text/html; char ...
- eclipse 更改背景颜色字体
原文 切一个自己的图: 废话不说,直接入题. 方式一:替换Eclipse的配置文件 其实Eclipse的各种配置都是在文件设置里的,因此只要用一个配置好的模版来替换默认的配置文件,即可将所有配置克隆到 ...
- Android Studio 中的 button 无法使用 background 更改背景颜色
•解决方案 res/values/themes.xml下的 <style name="Theme.HelloWorld" parent="Theme.Materi ...
- [转]如何在Windows 10中更改文件夹背景颜色
ini文件.我们甚至可以使用相同的技术将图片设置为文件夹背景. 已有工具可以更改Windows 7中Windows资源管理器背景的颜色,并将图像设置为Windows 7中的文件夹背景,但这些工具与Wi ...
- []如何在Windows 10中更改文件夹背景颜色
ini文件.我们甚至可以使用相同的技术将图片设置为文件夹背景. 已有工具可以更改Windows 7中Windows资源管理器背景的颜色,并将图像设置为Windows 7中的文件夹背景,但这些工具与Wi ...
- Pycharm使用中背景颜色和更改项目的Python版本
一.背景颜色 颜色是每一个人都会去更改的,而且可以保护眼睛! 第二步: 选择图中画框的位置,便可以更改背景颜色! 二.项目版本的更改: python2 和 python3 有很大的不同,使用pytho ...
- vscode自定义背景颜色
vscode自定义背景颜色 大概做前端的builder(只会打代码的才是coder,嘻嘻~)一半以上都会使用vscode编辑代码吧,vscode很轻量,支持的文件拖拽加入编辑区功能我个人认为很方便 ...
随机推荐
- Paxos算法简单介绍
一种基于消息传递且具有高度容错特性的一致性算法.解决在存在宕机或者网络异常的集群中对某个数据的值达成一致性,并且保证无论在发生以上任何异常都不会破坏整个系统的一致性,具有容错性. Paxos算法实现的 ...
- Python Data Visualization Cookbook 2.2.2
import csv filename = 'ch02-data.csv' data = [] try: with open(filename) as f://用with语句将数据文件绑定到对象f r ...
- 《JS权威指南学习总结--6.5枚举属性》
内容要点: 一.for/in循环 1.for/in循环可以在循环体中遍历对象中所有可枚举的属性(包括自有属性和继承的属性),把属性名称赋值给循环变量.对象继承的内置方法不可枚举,但在代码中给对象添加的 ...
- createElement创建
定义和用法 createElement() 方法可创建元素节点. 此方法可返回一个 Element 对象. <script type="text/javascript"> ...
- 安卓请求服务器js文件下载到本地,版本号就下载
<?phpreturn array('CJ_V' => 'v0.15',) <script src="/js/reserve.js?<?=C('CJ_V')?> ...
- 【其他】MySql数据库的安装与卸载
一.安装 1.首先下载安装包,包含服务端和客户端 2.添加用户组.用户 secondary1:~ # groupadd mysql secondary1:~ # useradd -g mysql -d ...
- SharePoint2013 Excel导出好的代码
C#Excel操作类ExcelHelper.cs 来源:http://www.hellocsharp.com/article/67.aspx C#源码世界 发布于: 2014-09-12 使用本类之前 ...
- ubuntu下安装BeyondCompare比较工具
在ubuntu12.04下使用比较工具,这里参考了网上的一个方法来安装BeyondCompare3 首先,下载相关软件: 这里选择了BCompare: http://www.scootersoftwa ...
- quicksort快排
废话不多说,上代码: void quicksort(int x[], int lo, int hi){ int i = lo, j = hi; ]; while(i <= j){ while(x ...
- pumping lemma for finite regular language?
some books describe pumping lemma as this: Let L be a regular language. Then there exists an integer ...