300字范文,内容丰富有趣,生活中的好帮手!
300字范文 > android:theme.holo.light. Android: Theme.Holo.Light.NoActionBar vs Theme.Light.NoTitleBar

android:theme.holo.light. Android: Theme.Holo.Light.NoActionBar vs Theme.Light.NoTitleBar

时间:2023-04-13 23:51:04

相关推荐

android:theme.holo.light. Android: Theme.Holo.Light.NoActionBar vs Theme.Light.NoTitleBar

问题

In res/values-v11/styles.xml, I can't use Theme.Holo.Light.NoActionBar because it was added in API level 13. Can I use Theme.Light.NoTitleBar instead, with no visual differences? As far as I can tell, they should both have a white background, status and navigation bars, and nothing else.

回答1:

Theme.Light.NoTitleBar is slightly different. The easiest way to resolve this and stay compatible back to Honeycomb is to create your own style that extends Theme.Holo.Light, but removes the Action Bar. Just create a style with the following definition:

false

true

回答2:

As far as I know, the Theme.Light.NoTitleBar is based on older API level. You will get the style of Android 2.3. But Theme.Holo.Light.NoActionBar can give you the style of 4.0 or upper.

来源:/questions/14061661/android-theme-holo-light-noactionbar-vs-theme-light-notitlebar

本内容不代表本网观点和政治立场,如有侵犯你的权益请联系我们处理。
网友评论
网友评论仅供其表达个人看法,并不表明网站立场。