字体看起来在窗口中扭曲 [英] Font looks distorted in windows

查看:231
本文介绍了字体看起来在窗口中扭曲的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Iam在ubuntu做一个网站,并完成UI部分。一切都在ubuntu工作顺利,但是当我打开到Windows所有的字体扭曲。我尝试下面的代码

Iam doing a website in ubuntu and finished with UI part. Everything was working smoothly in ubuntu but when i switched on to windows all the fonts are distorted. I tried the following code

@font-face {
    font-family: 'garrisonsb';
    src: url('../fonts/garrisons-bold.eot');
    src: url('../fonts/garrisons-bold.eot?#iefix') format('embedded-opentype'),
         url('../fonts/garrisons-bold.woff') format('woff'),
         url('../fonts/garrisons-bold.ttf') format('truetype'),
         url('../fonts/garrisons-bold.svg#garrison_sansbold') format('svg');
    font-weight: bold;
    font-style: normal;

}

@font-face {
    font-family: 'garrisons';
    src: url('../fonts/garrisons-regular.eot');
    src: url('../fonts/garrisons-regular.eot?#iefix') format('embedded-opentype'),
         url('../fonts/garrisons-regular.woff') format('woff'),
         url('../fonts/garrisons-regular.ttf') format('truetype'),
         url('../fonts/garrisons-regular.svg#garrison_sansregular') format('svg');
    font-weight: normal;
    font-style: normal;

}

@font-face {
    font-family: 'rupee';
    src: url('../fonts/Rupee.eot');
    src: url('../fonts/Rupee.eot?#iefix') format('embedded-opentype'),
         url('../fonts/Rupee.woff') format('woff'),
         url('../fonts/Rupee.ttf') format('truetype'),
         url('../fonts/Rupee.svg#rupeeregular') format('svg');
    font-weight: normal;
    font-style: normal;

}

指定的代码是使用鼠标生成器生成的。我试图将font-smooth属性设置为always,并且将-webkit-font-smoothing设置为antialiased,并且font-weight也被指定为700为常规,900为粗体而不是'normal',但没有任何作用。

the specified code is been generated using squirrel-generator. I tried with font-smooth property set to 'always' and also with -webkit-font-smoothing set to antialiased and the font-weight was also specified as 700 for regular and 900 for bold instead of 'normal', but nothing worked.

请提出最佳解决方案......

please suggest optimum solution......

推荐答案

当说的问题停留在所有的浏览器它弹出的问题,是错误的字体或可能是别的什么?
你可以尝试使用Windows中的另一个自定义字体来查看结果吗?

When saying the problem stays within all the browsers it pops the question, is something wrong with your font or maybe something else? Can you try to do that with another custom font in Windows to see the result?

虽然解决方案@Madhu Rox提供的是相当尖端的。

Though the solution @Madhu Rox provided is pretty cutting edge.

这篇关于字体看起来在窗口中扭曲的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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