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

Sample input and output files? #3

Open
WeileiZeng opened this issue Apr 26, 2020 · 4 comments
Open

Sample input and output files? #3

WeileiZeng opened this issue Apr 26, 2020 · 4 comments

Comments

@WeileiZeng
Copy link

The repo is great and I am trying to use it. Can you give some samples of input and output files?

I am trying to generate some Chinese dot matrix as a replacement for HZK16, but the output file doesn't looks right and doesn't work for my other program yet.

Thanks!

@hmgle
Copy link
Owner

hmgle commented Apr 26, 2020

Hi.
To generate the dot matrix font, you can use any vector font (e.g., 文泉驿).

This command will generate the dot matrix font named out.font, with 32 height:

gendotmatrix.py -o out.font  -s "32x32" "input_vector.ttf"

@hmgle
Copy link
Owner

hmgle commented Apr 26, 2020

This page also lists many other Chinese fonts for free: https://wiki.ubuntu.org.cn/%E5%85%8D%E8%B4%B9%E4%B8%AD%E6%96%87%E5%AD%97%E4%BD%93

@WeileiZeng
Copy link
Author

Thanks. I tried that. But when I print the output file using less, I got pure symbols of the following for the whole file
^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@^@
That looks like an empty file for me.

My goal is to replace HZK16 in this repo. And I expect that your program would convert any ttf file into the same format as the HZK16 file.

@hmgle
Copy link
Owner

hmgle commented Apr 27, 2020

What is the input font file? Make sure that the input input_vector.ttf file contains Chinese characters.

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