- objective-c - iOS 5 : Can you override UIAppearance customisations in specific classes?
- iphone - 如何将 CGFontRef 转换为 UIFont?
- ios - 以编程方式关闭标记的信息窗口 google maps iOS
- ios - Xcode 5 - 尝试验证存档时出现 "No application records were found"
我正在使用旧的 CSS 样式表,其中一些条目类似于:
.calibre18 {
color: windowtext;
font-family: "Book Antiqua", "serif";
font-size: 1.29167em;
line-height: 1.2;
}
这在 color: windowtext;
上不断出错我发现它已被弃用“支持 CSS3 UI appearance
属性”。不幸的是,这似乎也被弃用了。
如何重现作者的初衷?
最佳答案
旧的 CSS2 系统颜色名称已被弃用,原因如下:
These color names have been deprecated, however, as they are insufficient for their original purpose (making website elements look like their native OS counterparts), and represent a security risk, as it makes it easier for a webpage to "spoof" a native OS dialog.
见http://dev.w3.org/csswg/css-color-4/#system-colors
另一条相关引述:
User agents must support these keywords, but should map them to "default" values, not based on the user’s OS settings (for example, mapping all the "background" colors to white and "foreground" colors to black). Authors must not use these keywords.
恕我直言,您不应尝试重现作者的初衷,也不应依赖用户代理的默认支持,而应定义实际颜色。
关于css - 如何替换颜色 : windowtext;,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/28511649/
我正在使用旧的 CSS 样式表,其中一些条目类似于: .calibre18 { color: windowtext; font-family: "Book Antiqua", "serif";
我使用稍微修改过的“cleanlooks”样式创建了一个 Qt 应用程序。我试过使用以下代码设置 WindowText,但更改没有生效。当我打开应用程序时,它会在后台以正确的文本颜色打开,当我单击该应
我编写了一个程序来显示一个带有标签、文本字段和按钮的窗口。当鼠标单击文本字段时,应调用程序 VirtualKeyboardTest.java。 import java.awt.*; import ja
我是一名优秀的程序员,十分优秀!