这是我的英雄应用程序:https://majeddh.herokuapp.com;我现在正在使用它来测试字体。浏览器不能正确显示阿拉伯字体
这是我的HTML代码:
<?php echo 'majed'?><html>
<script src="http://ajax.googleapis.com/ajax/libs/webfont/1/webfont.js"></script>
<style>
@import url('lateef.css');
h1 {
font-family: 'Lateef';
}
.wf-active h1 {
visibility: visible;
}
h2{
font-family:'lateef1';}
</style>
<body>
<h1>This headline will be hidden until Droid Sans is completely loaded.</h1>
<h1>ماجد</h1>
<h2>This headline will be hidden until Droid Sans is completely loaded.</h2>
<h2>ماجد</h2>
</body>
</html>
这是CSS:
@font-face {
/*this is arabic*/
font-family: 'Lateef';
font-style: normal;
font-weight: 400;
src: url(https://majeddh.herokuapp.com/FS_Metal2.TTF) format('truetype');
}
@font-face {
/*this is english*/
font-family: 'Lateef1';
font-style: normal;
font-weight: 400;
src: url(https://majeddh.herokuapp.com/FS_Metal1.ttf) format('truetype');
}
我不知道是哪里的问题;英文字体出现,但阿拉伯文不会,并且我尝试了3种不同的字体,并出现相同的问题。
Lateef1适合我,而Lateef不适合。你确定Lateef有正确的码点吗?阿拉伯语必须在unicode表格中,并且Lateef必须有这些点。 – Rudie 2013-03-26 13:50:29