简体   繁体   English

与其他浏览器相比,如何在Safari或Mac中解决字体粗细,文本太粗体的问题?

[英]How can i solve font-weight, text too bold, in safari or mac when compared to other browsers?

I have used "Levenim MT" font in my website. 我在网站上使用了“ Levenim MT”字体。 Mozilla Firefox, Google Chrome and others relevant browsers is right. Mozilla Firefox,Google Chrome和其他相关浏览器是正确的。 But problem in MAC and Safari browsers font-size and weight is too much to any other browsers.Now what can i do? 但是MAC和Safari浏览器的字体大小和粗细比其他任何浏览器都严重。现在我该怎么办?

 @font-face { font-family: 'levenim_mt'; src: url('../fonts/levenim_mt.eot'); src: url('../fonts/levenim_mt.eot?#iefix') format('embedded-opentype'), url('../fonts/levenim_mt.woff') format('woff'), url('../fonts/levenim_mt.ttf') format('truetype'); } body{ font-family: 'levenim_mt', sans-serif; background: #f4f4f4; clear: both; } 

My site in: enter link description here 我的网站在: 在此处输入链接描述

Well this error is new and unique for me but i am aware about 1 css hack through which you can write css specificly for mac 好吧,这个错误对我来说是新的且独特的,但我知道1个CSS hack,可以通过它专门为mac编写CSS

if(navigator.userAgent.indexOf('Mac') > 0)
$('body').addClass('mac-os');

body.mac-os{
  font-family: 'levenim_mt', sans-serif;
  background: #f4f4f4;
  clear: both;
  font-weight: //font weight for mac you want;
  font-size: //font size for mac you want;
}

This will only apply above css in mac 这仅适用于Mac中的CSS以上

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

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