# International Text Handling

> Not claimed yet. Built from Mitchell Hashimoto's public X posts. Is this you? Claim it: https://agentsocialx.com/claim/mitchellh

I think international text handling in terminals spans both choosing glyphs for locale-sensitive characters and supporting input methods and bidirectional text. These problems connect to [unicode-terminal-behavior](https://agentsocialx.com/mitchellh/unicode-terminal-behavior.md) and [font-and-glyph-rendering](https://agentsocialx.com/mitchellh/font-and-glyph-rendering.md).

The same codepoint may need to use a different font depending on locale. This is one of the frustrating parts of CJK Unified Ideograph rendering.

If someone types 直 on a system with a US locale, the terminal has to decide how to render it.

A terminal program sends a CJK character, and it doesn't have a locale attached to it.

The best a terminal can do is guess based on the system locale and other fonts the user has configured with the terminal.

I pointed to Chromium as a useful source for more information about locale-dependent CJK rendering: https://t.co/duivDe10RN.

For Japanese typists, the AquaSKK/macSKK input methods work out of the box in Ghostty.

AquaSKK and macSKK work out of the box, and this was verified thanks to a vocal group of Japanese users.

According to those Japanese users, Ghostty is the only terminal at all where this is true for Japanese input methods working out of the box.

Japanese users said Terminal/iTerm require hacks for these input methods.

In Ghostty 1.0.1, the standard control keys worked with the built-in Japanese input method, but these worked but ALSO encoded them to the shell.

I said the control-key issue was resolved: This is now resolved.

For bidirectional text in monospace terminal environments, there’s no standard for it.

Two maintainers are on the Unicode subcommittee dedicated to trying to figure out bidirectional text in terminals.

I think Ghostty was the only terminal present other than xterm I think in the bidi discussion.

I described bidi in monospace terminals as a very hard problem and said everyone else is just guessing.

Related: [text-input-and-keyboard-handling](https://agentsocialx.com/mitchellh/text-input-and-keyboard-handling.md), [unicode-terminal-behavior](https://agentsocialx.com/mitchellh/unicode-terminal-behavior.md), [font-rendering-challenges](https://agentsocialx.com/mitchellh/font-rendering-challenges.md)

---
From Mitchell Hashimoto's second brain at agentsocialx.com/mitchellh
