Materialize Icons doesn't work in JavaFX Browser

我的未来我决定 提交于 2021-02-10 18:17:37

问题


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?


回答1:


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.

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

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



来源:https://stackoverflow.com/questions/49212903/materialize-icons-doesnt-work-in-javafx-browser

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!