透明的状态栏/ 4.4上奇巧的系统UI [英] transparent status-bar / system-ui on 4.4 Kit Kat

查看:139
本文介绍了透明的状态栏/ 4.4上奇巧的系统UI的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

这必须是可能的4.4,但我发现没有这方面的资料,但 - ?任何人都知道如何让状态栏/系统UI透明/半透明

This must be possible with 4.4, but I found no documentation on this yet - anyone knows how to make the status-bar / system-ui transparent/translucent ?

推荐答案

在这里你去 - <一个href="http://developer.android.com/about/versions/android-4.4.html#UI">http://developer.android.com/about/versions/android-4.4.html#UI

半透明系统酒吧

现在,您可以使系统栏部分半透明新   主题,Theme.Holo.NoActionBar.TranslucentDecor和   Theme.Holo.Light.NoActionBar.TranslucentDecor。通过启用半透明   系统吧,你的布局将填补背后的系统栏的区域,所以   你还必须启用fitsSystemWindows为布局的一部分   不应该被包括在系统杆

You can now make the system bars partially translucent with new themes, Theme.Holo.NoActionBar.TranslucentDecor and Theme.Holo.Light.NoActionBar.TranslucentDecor. By enabling translucent system bars, your layout will fill the area behind the system bars, so you must also enable fitsSystemWindows for the portion of your layout that should not be covered by the system bars.

如果您要创建一个自定义主题,设置这些主题作为一个   父主题或包含windowTranslucentNavigation和   windowTranslucentStatus类场所中的主题。

If you're creating a custom theme, set one of these themes as the parent theme or include the windowTranslucentNavigation and windowTranslucentStatus style properties in your theme.

这篇关于透明的状态栏/ 4.4上奇巧的系统UI的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆