Gmail 没有显示正确的字体 [英] Gmail not showing correct font

查看:24
本文介绍了Gmail 没有显示正确的字体的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试更改电子邮件的字体以打开 sans,但是,我在 Gmail 呈现正确字体时遇到问题.我设法找到了解决前景问题的方法.这就是我所拥有的:

I am trying to change the font of my emails to open sans, however, I am having issues with Gmail rendering the correct font. I managed to find a way to solve the issue for outlook. This is what I have:

身体{

        @font-face {
                font-family: 'Open Sans';
                font-style: normal;
                font-weight: 300;
                src: local('Open Sans'), local('OpenSans'), url(http://themes.googleusercontent.com/static/fonts/opensans/v6/cJZKeOuBrn4kERxqtaUH3bO3LdcAZYWl9Si6vvxL-qU.woff) format('woff');
            }
        }

我还尝试了其他方法,例如将所有文本声明为开放式:

I have also tried other things such as declaring all text to be open sans:

<link href='http://fonts.googleapis.com/css?family=Open+Sans:300'rel='stylesheet'type='text/css'>
     <style type="text/css">
    .stylealltext { font-family: 'Open Sans', sans-serif;}
    .stylealltextbold {font-weight: bold; font-family: 'Open Sans', sans-serif; }

但是,Gmail 决定显示 Arial,而 Google Inbox 决定显示 Helvetica.看起来 Google 的邮件服务只是覆盖了我提供的任何内容.有人可以帮忙吗?

However, Gmail decides to show Arial, while Google Inbox decides to show Helvetica.. It looks like Google's mailing services just overrides whatever I feed it. Can anyone help?

解决方案

Salvimatus 的解决方案奏效了:

Salvimatus's solution worked:

<span style="font-family: your-chosen-font">your text</span>

span需要手动添加.

The span needs to manually added.

推荐答案

Gmail 不支持@font-face.

Gmail does not support @font-face.

如果您自定义字体,您应该在您拥有的每个文本块中写入内联:

For you customize the font, you should write inline in each block of text that you have:

<代码><span style="font-family: your-chosen-font">你的文字</span>

注意:必须是我们在 Windows 或 Mac 上自带的字体.

Note: must be a font we have natively on Windows or Mac.

这篇关于Gmail 没有显示正确的字体的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆