简体   繁体   English

在黑暗的背景的黑暗的文本在与Theme.Sherlock.Light的AlertDialog

[英]Dark text on dark background on AlertDialog with Theme.Sherlock.Light

I'm using Theme.Sherlock.Light theme for my application and I'm creating a DialogFragment with an underlying AlertDialog . 我使用Theme.Sherlock.Light主题为我的申请,我创建一个DialogFragment与下面AlertDialog It works just fine on Android 3.x and 4.x, but on Android 2.x I see dark text on dark background, which is hardly readable. 它在Android 3.x和4.x上运行得很好,但在Android 2.x上我看到深色背景上的深色文本,这几乎不可读。 Am I doing something wrong and do I need to force light background by creating a custom style? 我做错了什么,是否需要通过创建自定义样式强制浅色背景? Thanks in advance. 提前致谢。

I found solution here : 我找到的解决方案在这里

builder.setInverseBackgroundForced(true)

Also, as I see here , Jake Warton suggests fix it by the same way and he doesn't know any better solution because of AlertDialogs implementation. 此外,正如我在这里看到的,Jake Warton建议以同样的方式修复它,因为AlertDialogs的实现,他不知道任何更好的解决方案。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM