I have an iPhone application that contains a webview. This webview renders an XHTML file which contains some Arabic text with CSS style. Everything works right with the style else the type of fonts, and if I change the contained text to English, the font type works right.
What is the problem with Arabic fonts?
Example:
@font-face {
font-family: "AHRAM";
font-style: normal;
font-weight: bold;
src:url("../Fonts/andlso.ttf") format("truetype");
}
@font-face {
font-family: "DroidSans";
font-style: normal;
font-weight: normal;
src:url("../Fonts/arabtype.ttf") format("truetype");
}
@font-face {
font-family: "DroidSansFallback";
font-style: normal;
font-weight: normal;
src:url("../Fonts/A_Nefel_Adeti.ttf") format("truetype");
}
p.line1 {
font-family: "AHRAM";
}
p.line2 {
font-family: "DroidSans";
}
p.line3 {
font-family: "DroidSansFallback";
}
<head>
<link href="../Styles/p1.css" rel="stylesheet" type="text/css" />
</head>
<body>
<p class="line1"> أهلاً بكم </p>
<p class="line2"> أهلاً بكم </p>
<p class="line3"> أهلاً بكم </p>
</body>
</html>