zsh-workers
 help / color / mirror / code / Atom feed
From: Clint Adams <clint@zsh.org>
To: zsh-workers@sunsite.dk
Subject: UTF-8 FAQs
Date: Sat, 8 Jan 2005 22:33:35 -0500	[thread overview]
Message-ID: <20050109033335.GA18994@scowler.net> (raw)

The number of questions I've been getting about zsh and UTF-8
have skyrocketed over the past couple of weeks.

Perhaps some of these belong in the zsh FAQ.  Corrections to my stock
answers are welcome.

Q: Does zsh support UTF-8?

A: zsh's built-in printf command supports "\u" and "\U" escapes
to output arbitrary Unicode characters.  ZLE (the Zsh Line Editor) has
no concept of character encodings, and is confused by multi-octet
encodings.

Q: Why doesn't zsh have proper UTF-8 support?

A: The code has not been written yet.

Q: What makes UTF-8 support difficult to implement?

A: In order to handle arbitrary encodings the correct way, significant
and intrusive changes must be made to the shell.

Q: Why can't zsh just use readline?

A: ZLE is not encapsulated from the rest of the shell.  Isolating it
such that it could be replaced by readline would be a significant
effort.  Furthermore, using readline would effect a significant loss of
features.

Q: How can I help implement UTF-8 support in zsh?

A: One approach would be to have ZLE use wide characters internally.
Character based widgets could then operate on a single wide character
instead of a single byte, and the proper display width can be calculated
with wcswidth().


             reply	other threads:[~2005-01-09  3:34 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2005-01-09  3:33 Clint Adams [this message]
2005-01-11 17:37 ` Peter Stephenson
2005-01-11 18:23   ` Clint Adams
2005-03-23  0:51   ` Clint Adams

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20050109033335.GA18994@scowler.net \
    --to=clint@zsh.org \
    --cc=zsh-workers@sunsite.dk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://git.vuxu.org/mirror/zsh/

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).