android中的style

来源:互联网 发布:主流的c语言开发工具 编辑:程序博客网 时间:2024/05/22 22:40

android中的style属性值,平时没怎么在意,这次积累下吧。
Android平台定义的主题样式:
android:theme=”@android:style/Theme.Dialog” // 将一个Activity显示为对话框模式
android:theme=”@android:style/Theme.NoTitleBar” // 不显示应用程序标题栏
android:theme=”@android:style/Theme.NoTitleBar.Fullscreen” // 不显示应用程序标题栏,并全屏
android:theme=”@android:style/Theme.Light” // 背景为白色
android:theme=”@android:style/Theme.Light.NoTitleBar” // 白色背景并无标题栏
android:theme=”@android:style/Theme.Light.NoTitleBar.Fullscreen” // 白色背景,无标题栏,全屏
android:theme=”@android:style/Theme.Black” // 背景黑色
android:theme=”@android:style/Theme.Black.NoTitleBar” // 黑色背景并无标题栏
android:theme=”@android:style/Theme.Black.NoTitleBar.Fullscreen” // 黑色背景,无标题栏,全屏
android:theme=”@android:style/Theme.Wallpaper” // 用系统桌面为应用程序背景
android:theme=”@android:style/Theme.Wallpaper.NoTitleBar” // 用系统桌面为应用程序背景,且无标题栏
android:theme=”@android:style/Theme.Wallpaper.NoTitleBar.Fullscreen” // 用系统桌面为应用程序背景,无标题栏,全屏
android:theme=”@android:style/Translucent” // 半透明效果
android:theme=”@android:style/Theme.Translucent.NoTitleBar” // 半透明并无标题栏
android:theme=”@android:style/Theme.Translucent.NoTitleBar.Fullscreen” // 半透明效果,无标题栏,全屏

window 属性

<item name="android:windowFrame">@null</item> :Dialog的windowFrame框为无<item name="android:windowIsFloating">true</item>:是否浮现在activity之上<item name="android:windowIsTranslucent">false</item>:是否半透明<item name="android:windowNoTitle">true</item>:是否显示title<item name="android:windowBackground">@drawable/dia_bg</item>:设置dialog的背景<item name="android:backgroundDimEnabled">false</item>: 背景是否模糊显示
0 0
原创粉丝点击