12

On a blackbox linux system neither the system or the openjdk had any fonts so this caused issue for my Java application.

So far to get round this I have copied the Lucida fonts from an Oracle Java install into the jre/lib/fonts dir and ran fc-cache -rv jre/lib/fonts and that has worked for me.

But it seems these standard fonts do not support CKJ scripts, what is a font I can copy to fonts that will add support for these scripts for my Java application.

Note I cannot run install or similar on the linux machine I need a font I can just bundle with my application that I can then copy to the jre/lib/fonts folder.

Paul Taylor
  • 13,411
  • 42
  • 184
  • 351
  • 1
    How it is not about programming iM asking what font can I install to provide full Javafunctionality with Open Jdk – Paul Taylor Feb 18 '18 at 19:44

3 Answers3

11

You could take a look at Noto, which will "support all languages with a harmonious look and feel."

RoelN
  • 2,181
  • 13
  • 15
  • 2
    Download all fonts is 1.1GB !, what do I need to have just each symbol covered – Paul Taylor Feb 20 '18 at 18:16
  • 2
    That the download link for _all_ fonts. Why not download only the CJK fonts? Still big files (~100MB) but hey — that's what you get by complete CJK coverage! – RoelN Feb 21 '18 at 12:30
  • Sorry I'm unclear, I want to be able to display any character from any language, when i say CKJ it was because my understanding that this is what was missing form the standard fonts. But I dont need multiple fonts for a particualr character just one, so im confused if I need the whole 1.1GB or not. – Paul Taylor Feb 22 '18 at 07:33
  • 4
    "Any character from any language" means needing a truly immense character set. Noto is the only font that strives to cover _all_ languages encoded in Unicode. So if you want support for _all_ languages, Noto seems like your best fit. – RoelN Feb 22 '18 at 09:05
  • Okay I dont think I fully understand this but things seem to be working – Paul Taylor Feb 26 '18 at 15:04
  • notocjk.ttf works for asian languages. But when using notosans-regular.ttf , nothing works. Anyone has any idea why ? – amitava mozumder Oct 30 '18 at 10:37
  • 4
    There are no .ttf fonts (they are all in ttc or otf) for Noto Sans CJK fonts. Anyone found ttf type? – seokhoonlee Apr 15 '19 at 13:28
  • @seokhoonlee - I found [this SC TTF](https://github.com/jsntn/webfonts/blob/master/NotoSansSC-Regular.ttf), but I'm skeptical of it. – Francis Bartkowiak Apr 09 '21 at 12:01
9

DO NOT combine and create your own CJK fonts, because same Chinese Character (a codepoint in Unicode) may have different glyphs in Chinese Simplified, Chinese Traditional, Japanese and Korean fonts. If you use font designed for one area for users from another area, they will feel that your font is strange, hard to recognize, or even wrong.

Check Noto Serif CJK is here! for an example about glyphs of 述.

Check Source Han Serif, an open source Pan-CJK typeface for an example about glyphs of 曜.

I strongly recommend you to use Noto Sans CJK and Noto Serif CJK family for your purpose, and use Noto Sans/Serif CJK SC when rendering Chinese Simplified text, Noto Sans/Serif CJK TC when rendering Chinese Traditional text, Noto Sans/Serif CJK JP when rendering Japanese text, and Noto Sans/Serif CJK KR when rendering Korean text. Never mix them together.

ChenZheChina
  • 149
  • 6
  • The whole idea of unicode is that each codepoint corresponds to a single character. - This in contrast to the windows codepages. – paul23 Feb 25 '18 at 18:45
  • @paul23: but in deciding that, the Unicode consortium did not take localized preferences into account. For example, it took *years* of lobbying to finally get different Unicode values for `ţ` and `ț` – initially the Unicode experts had decided it was "just a graphic difference". – Jongware Feb 26 '18 at 10:28
  • notocjk only does asian languages, but what if I want to support all languages? how do i go about doing that? – amitava mozumder Oct 30 '18 at 10:35
  • @amitavamozumder Noto is a huge font family with many languages covered. And, they also have different fonts to cover glyph variants like Noto CJK fonts cover glyph variants between China, Japan and Korea. For example, Noto has Arabic and Urdu fonts respectively. Though they both share same Unicode codepoints, they have extremely different looks. So I’d say that the best way to support “all” languages is to use **multiple fonts**, and use them correctly when some different characters share a same codepoint. – ChenZheChina Dec 11 '19 at 00:57
6

I couldn't find a font that supported Chinese, Japanese and Korean so, I had to create my own. Below is a quick program I made to show off this font showing hello in all four languages + English. (I hope that's ok).

Download Link: https://mega.nz/#!Mt5mCJzR!DMVa1usSTV6OEraQQlcF8dGcg5VYkboNB6O_dkQD-QE

Edit:

I found someone else who has done a similar thing to me (combined lots of fonts) The link to their download is here.

Tacodiva
  • 391
  • 2
  • 17
  • how did you combine them? i need a combined version for all languages. how can i do that ? – amitava mozumder Oct 30 '18 at 10:34
  • @amitavamozumder I wouldn't recommend trying to create your own font for all languages, I only created this one so I could only support English, Chinese, Japanese and Korean. If you want every language I would recommend looking at the accepted answer, although it is big it contains every language. – Tacodiva Nov 07 '18 at 10:36
  • 1
    notosans cjk works fine, but notosans all language ones are not working, any idea why ? – amitava mozumder Nov 08 '18 at 11:28
  • @amitava mozumder Sorry for the late reply, it's hard to say whats wrong without any information. If you want to get this solved I would suggest asking a question of your own. – Tacodiva Nov 28 '18 at 21:53
  • 1
    @Tacodude7729 your download link is no longer alive – cYrixmorten Apr 01 '19 at 08:58
  • I'm gonna use this in our production. Googles NotoCJK Has no support for englist so im gonna use this. Thank you. – aRtoo May 04 '21 at 22:50