Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

如何修改字体的unicode编码? #38

Open
webkonglong opened this issue Apr 29, 2020 · 1 comment
Open

如何修改字体的unicode编码? #38

webkonglong opened this issue Apr 29, 2020 · 1 comment

Comments

@webkonglong
Copy link

`var fontCarrier = require('font-carrier')
var transFont = fontCarrier.transfer('./PingFang-SC-Regular.ttf')
var font = fontCarrier.create()
var gs = transFont.getGlyph('我是谁?')

font.setGlyph(gs)

font.output({
path: './ttf'
})

console.log(font)`
我想把 "我是谁?"这四个字符的unicode编码修改掉,然后在导出字体,我在web HTML用我自定义编码,  谢谢您.去回复

@Machaing
Copy link

我不是作者,不过我可以建议你下一个fontForce软件(Free),用该软件打开你导出的ttf文件,然后就可以重新编码(Unicode),编码操作很简单,你可以youtube找相应的教程,就是改glyphInfo,最后重新导出ttf文件即可。

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants