-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
please kindly add some fonts which support Chinese #20342
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
Comments
@story645 |
Unfortunately, this is something you should take up with Dataworks. Bundling more than a minimal set of fonts with Matplotlib is starting to creep into packaging / distribution which is a different (and very hard!) problem than the core problem Matplotlib is solving (plotting!). This is obviously an important issue, however not one that Matplotlib is well situated to solve by its self. While I see how it would be very convenient if Matplotlib shipped a Chinese (or Japanese, Korean, ...) font (as picking up unicode past the latin/latin-1 code page was one of the justifications for moving from vera sans to DejaVu as the default font), however I have several major concerns. The second is the sheer size of the fonts, looking at the noto download page some of these fonts (that still do not cover the full unicode range!) weigh in at 120MB+ and we would probably want to include 4 of them (the JP, SC, TC, and KR versions). In contrast, if you strip out the test images the Matplotlib wheel is ~11M (2-4M of which which is the limited fonts we do ship, researching this response has made me think we should cut-back on those!) and ~35M with the test images. Adding almost half a gigabyte to either the repo or the artifacts on pypi is not really an option. Our repo is already too big, Matplotlib is downloaded 500,000 - 900,000 times per day so greatly expanding the size of artifacts would have significant impact on pypi's bandwidth, and finally there is a 60MB cap on the maxmimum size file that we can put on pypi (without negotiating with the pypa folks). Finally, on the core Matplotlib team I do not think we currently have anyone who frequently works with CJK (my apologies to anyone if I am wrong!) and I do not have faith that we know enough to be confident that, even if we dispensed with the first two concerns, that we would be able to make an informed and correct decision about what font(s) to include. @DaisyLL A practical path forward for you is to download the font of your choice with in Dataworks (using e.g requests or urllib ) and then by passing a |
@tacaswell |
@DaisyLL Thank you for being understanding. |
HI:
I am in China. and we often need to display chinese on our plot. but there is any fonts which can support chinese, usually we can add a font to our computer to support chinese plotting. still there is some case we can't add extra fonts by our own. so
Will you kindly add some fonts which can support chinese in the original package?
lilu
best wish!
The text was updated successfully, but these errors were encountered: