物化图标在JavaFX浏览器中不起作用 [英] Materialize Icons doesn't work in JavaFX Browser

查看:88
本文介绍了物化图标在JavaFX浏览器中不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用webEngine在JavaFx WebBrowser上显示 MaterialIcons 图标.图标在IE和Safari上也不起作用.有人知道如何使其可读吗?

I'm trying to show MaterialIcons on my JavaFx WebBrowser using webEngine, but it just shows the description of the icon. Icons doesn't work also on IE and Safari. Does anyone know how to make it readable?

推荐答案

我也为此而苦苦挣扎,因此对于那些感兴趣的人来说,JavaFX仅与使用数字字符引用编写的MaterialIcons兼容,如James_D所述,而与连字格式.

I also struggle on that one, so for those who are intersted to know, JavaFX is only compatible with MaterialIcons written with numerical character references as James_D stated and not with ligatures format.

如此着迷:<i class="material-icons">add</i> 您应该输入:<i class="material-icons">&#xE145;</i>

So insted of writing : <i class="material-icons">add</i> You should write : <i class="material-icons">&#xE145;</i>

这里是备忘单链接,用于将材质图标"连字转换为它们各自的数字字符参考: https://github.com/google/material-design-icons/blob/master/iconfont/codepoints

Here is cheatsheet link for converting Material Icon ligatures to their respective numerical character reference : https://github.com/google/material-design-icons/blob/master/iconfont/codepoints

这篇关于物化图标在JavaFX浏览器中不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆