loaoao@gmail.com (aoao) 发表于 2009年01月04日 02:01 | Hits: 1949
Tag: Web开发 | color | CSS

直接调用系统的颜色显示在网页上本来是件很好玩滴事,但是,也有个缺点,就是可用的色太少 比如Bindows在它的启动画面一点点应用。

=。= 上次本来想在某个产品上应用,结果给人BS了,原因是色不好看 囧rz

在css21 中System Colors也有相关描述,CSS3还加了超链接的色,还有个flavor


附各色显示效果,如果看不到文字部分就像刮彩票一半刮开看一下,其中,Background 这个在safari 比较神奇,是透明哦。

CSS2.1中的System Colors

ActiveBorderActive window border.ActiveCaptionActive window caption.AppWorkspaceBackground color of multiple document interface.BackgroundDesktop background.» test color:Background @aoaoButtonFaceFace color for three-dimensional display elements.ButtonHighlightHighlight color for three-dimensional display elements (for edges facing away from the light source).ButtonShadowShadow color for three-dimensional display elements.ButtonTextText on push buttons.CaptionTextText in caption, size box, and scrollbar arrow box.GrayTextGrayed (disabled) text. This color is set to #000 if the current display driver does not support a solid gray color.HighlightItem(s) selected in a control.HighlightTextText of item(s) selected in a control.InactiveBorderInactive window border.InactiveCaptionInactive window caption.InactiveCaptionTextColor of text in an inactive caption.InfoBackgroundBackground color for tooltip controls.InfoTextText color for tooltip controls.MenuMenu background.MenuTextText in menus.ScrollbarScroll bar gray area.ThreeDDarkShadowDark shadow for three-dimensional display elements.ThreeDFaceFace color for three-dimensional display elements.ThreeDHighlightHighlight color for three-dimensional display elements.ThreeDLightShadowLight color for three-dimensional display elements (for edges facing the light source).ThreeDShadowDark shadow for three-dimensional display elements.WindowWindow background.WindowFrameWindow frame.WindowTextText in windows.

CSS3 新加的 User preferences for hyperlink colors

ActiveHyperlinkActive hyperlink background.ActiveHyperlinkTextText of an active hyperlink.HoverHyperlinkHover hyperlink background.HoverHyperlinkTextText of a hyperlink in the hover state.HyperlinkHyperlink background.HyperlinkTextHyperlink text.VisitedHyperlinkVisited hyperlink background.VisitedHyperlinkTextText of a visited hyperlink.
flavorAn accent color (typically chosen by the user) to customize the user interface of the user agent itself. User agents may default the ‘flavor’ color to the dominant accent color used on the physical machine/mechanism that the user is interacting with (frequently a mouse, keyboard, monitor and computer case, often just a laptop), if the UA is able to retrieve that information from the platform and machine. It is not expected that this value will make sense on all platforms and machines.

原文链接: http://www.aoao.org.cn/blog/2009/01/css-system-colors/

0     0