Police personnalisée pour les webview

Je suis en train d'établir une nouvelle police personnalisée (otf fichier) pour ma vue web.

J'ai mis anbaaarabic_bold.otf dans le fichier d'actifs.

Il est de savoir comment je le fais:

String head = "<head><style>@font-face {font-family: 'verdana';src: url('file://"+ getActivity().getFilesDir().getAbsolutePath()+ "/anbaaarabic_bold.otf');}body {font-family: 'verdana';}</style></head>";
String htmlData= "<html>"+head+"<body style=\"font-family: verdana\">"+body+"</body></html>" ;

mBodyArticle.loadDataWithBaseURL("http://nada", htmlData,
                    "text/html", "utf-8", "");

corps : contenir mon code html.

Je ne sais pas pourquoi la police ne fonctionne pas pour mon webview. le corps html de police ne change pas.

  • J'ai une question pour vous???êtes-vous en essayant de ne charger une page en particulier ou vous souhaitez que toutes les pages pour être dans la police personnalisée format?