简体   繁体   English

网站文字颜色因平台而异

[英]Website text color differs across platforms

I have a website with text that I've set to #666666 in CSS. 我有一个网站,其文字在CSS中设置为#666666 This color persists just fine across browsers- however, when I view the site on a Windows machine, the text appears a much lighter shade of gray, despite my using the same browsers (Firefox and Chrome). 这种颜色在各种浏览器上都可以很好地保持不变-但是,当我在Windows计算机上查看该网站时,尽管我使用相同的浏览器(Firefox和Chrome),但文本显示的灰度却要浅得多。 This problem only occurs within the content elements- the nav bar is also set to #666666 and it behaves as desired. 仅在内容元素内会发生此问题-导航栏也设置为#666666并且其行为符合预期。

The CSS for the nav bar: 导航栏的CSS:

a.nav {
    color: #666666;
    font-size: 48px;
    font-family: 'Raleway';
    text-align: center;
    text-decoration: none;
    margin-top: -50px;
}

The CSS for my content (this is the stuff that changes color): 我的内容的CSS(这是会改变颜色的东西):

#content {
    color: #666666;
    font-size: 18px;
    font-family: 'Raleway';
    width: 470px;
    margin: 0 auto;
    margin-top: 15px;
    line-height: 128%;
    text-align: justify;
}

Any ideas about why this might be happening and what I can do to remedy it? 关于为什么会发生这种情况以及我可以采取什么补救措施的任何想法?

可能是rgb颜色,因为它可能会更一致地应用于不同的元素。

color: rgb(102,102,102); 

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

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