Short answer is horribly. Chinese is not one word per character. Not even close. Most words you encounter on a regular basis are two-char compounds, but individually each character would tell you less about the whole than ‘camp’ and ‘ground.’ Many words are four-char compounds.
You could potentially design ligatures for every word in the dictionary, but given the vastly different grammar, you wouldn’t be able to understand what a sentence said. You might be able to glean ‘this sentence involves a dog.’ Even google translate makes such poor translations, that it can really only assist in understanding. It usually doesn’t understand the subject of the sentence and confuses all the pronounced into ‘I.’
Re:Cantonese Font with Pronunciation
by keyboard_smash on Tuesday May 09, 2023 @12:14AM
(#35870105)
Like with any language, there’s gonna be a lot of context-dependent words/phrases with multiple meanings that are hard to segment/parse/translate correctly. Things like DeepL or GTranslate take into account probabilities for segmentation and grammar (or use ICU libraries); but that’s harder to do from a context of using ligatures and basic font engine features.
e.g. The classic example is 大麻煩 - is it 大|麻煩 (a big inconvenience), or is it 大麻|煩 (marijuana annoyance)? Is 粉絲 fan, or vermicelli? Is 早唞! “good night!” or “go fuck yourself!”?
Marijuana literally means "big numb" in Chinese? Or "big horse" if I mispronounce it?
Re:Cantonese Font with Pronunciation
by keyboard_smash on Tuesday May 09, 2023 @01:10AM
(#35870392)
Haha, yeah, works that way for Cantonese and Mandarin. 大麻 daai6 maa4/dà má (marijuana, literally ‘big numb’) vs 大馬 daai6 maa5/dà mǎ (big horse).
Bonus: 大媽 daai6 maa1/dà mā (auntie or father’s elder brother’s wife, literally ‘big mother’).
麻 isn’t always numb. It’s also a genetic term for all kinds of flax or fiberous plants like hemp. For example sesame is 芝麻.
Re:Cantonese Font with Pronunciation
by bobbylarrybobby on Tuesday May 09, 2023 @12:14AM
(#35870107)
Iirc, opentype font tables are Turing complete so... you could put an AI translator in a font! The sky's the limit.
Especially given modern font ligatures letting you change the meanings displayed based on context (the way things like Fira code do).
Maybe don't even show the Chinese characters, just their meaning in English? It's obviously not going to be perfect, but I think there's potential there for a fun project.