【发布时间】:2017-03-08 10:33:11
【问题描述】:
我想在 WKWebView 加载带有自定义字体系列和文本颜色的 html 字符串,我尝试将此 CSS 嵌入 HTML 但它不起作用:( .
[NSString stringWithFormat:@"<html> \n"
"<head> \n"
"<style type=\"text/css\"> \n"
"body {font-family: \"%@\"; font-size: %d;}\n"
"</style> \n"
"</head> \n"
"<body>%@</body> \n"
"</html>", @"DINNextLTW23Regular", self.fontSize,@"Text"];
【问题讨论】:
标签: ios objective-c webkit wkwebview