【问题标题】:SourceSansPro-Bold font bolder in firefoxFirefox 中的 SourceSansPro-Bold 字体加粗
【发布时间】:2017-02-08 12:53:45
【问题描述】:

在 Firefox 中:

.enum{
font-family: "SourceSansPro-Bold","Source Sans Pro";
font-weight: 700;
}

如果我在做 font-weight: 400 就好了

.enum{
font-family: "SourceSansPro-Bold","Source Sans Pro";
font-weight: 400;
}

但是当用户屏蔽了谷歌字体 CDN 时,它看起来不会变粗体

.enum{
font-family: "Source Sans Pro";
font-weight: 400;
}

【问题讨论】:

    标签: css


    【解决方案1】:

    您也应该下载粗体版本。

    在你的 html 中使用这个标签

    <link href="https://fonts.googleapis.com/css?family=Source+Sans+Pro:400,700,700i" rel="stylesheet">
    

    如果它被阻止,你无能为力

    【讨论】:

      【解决方案2】:

      我认为你可以为 Firefox 那样做。它只会处理Firefox浏览器。您只能为 firefox 浏览器设置此 hack。

      @-moz-document url-prefix() {
      .enum{
            font-family: "Source Sans Pro";
            font-weight: 400;
       }
      }
      

      【讨论】:

        猜你喜欢
        • 2012-09-29
        • 2017-01-17
        • 1970-01-01
        • 2012-11-18
        • 2017-01-20
        • 2012-11-25
        • 2011-08-21
        • 2020-10-19
        • 2013-11-07
        相关资源
        最近更新 更多