Gmail无法显示正确的字体

Gmail无法显示正确的字体

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

问题描述

我正在尝试将电子邮件的字体更改为sans,但是Gmail呈现正确的字体时出现问题.我设法找到一种解决Outlook问题的方法.这就是我所拥有的:

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>

需要手动添加跨度.

推荐答案

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">your text< /span>

注意:必须是Windows或Mac上的本地字体.

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

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

08-23 10:35