Linux Archive

Linux Archive (http://www.linux-archive.org/)
-   Debian User (http://www.linux-archive.org/debian-user/)
-   -   What does stty's iutf8 actually do (effect)? (http://www.linux-archive.org/debian-user/695194-what-does-sttys-iutf8-actually-do-effect.html)

"Dan B." 08-17-2012 11:47 PM

What does stty's iutf8 actually do (effect)?
 
The manual page for stty says that the input setting "iutf8" controls
whether to "assume [that] input characters are UTF-8 encoded."

What does setting actually do?

(I understand UTF-8 and its mapping between byte sequences and characters.
What I don't know is where character decoding and encoding are done in
Linux input and output components (virtual consoles, xterm/etc., tty
devices).)

What does that iutf8 setting actually affect?

Is the terminal (tty?) driver involved in decoding the input byte stream
into characters for the process attached to the tty device?

Or does the driver decode bytes into characters only for its own
checking for special characters (e.g., for stty intf CHAR)?

Thanks,
Daniel


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org

Archive: 502ED815.9000900@kempt.net">http://lists.debian.org/502ED815.9000900@kempt.net

Camaleón 08-19-2012 04:59 PM

What does stty's iutf8 actually do (effect)?
 
On Fri, 17 Aug 2012 19:47:33 -0400, Dan B. wrote:

> The manual page for stty says that the input setting "iutf8" controls
> whether to "assume [that] input characters are UTF-8 encoded."
>
> What does setting actually do?
>
> (I understand UTF-8 and its mapping between byte sequences and
> characters. What I don't know is where character decoding and encoding
> are done in Linux input and output components (virtual consoles,
> xterm/etc., tty devices).)
>
> What does that iutf8 setting actually affect?

As I see it, this concerns the kernel and how it handles the data flaw
input/output coming from pipes redirection between programs or even from
a simple echo/cat command you execute when you're on a tty.

By turning that flag "on" (by default is "on") you are telling the kernel
it has to expect UTF-8 enconding and my guess is that this setting is
aimed to normalize the way console input/output is managed to avoid
problems coming from wrong character encoding transformations.

> Is the terminal (tty?) driver involved in decoding the input byte stream
> into characters for the process attached to the tty device?
>
> Or does the driver decode bytes into characters only for its own
> checking for special characters (e.g., for stty intf CHAR)?

My two cents for the former :-)

Greetings,

--
Camaleón


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: http://lists.debian.org/k0r61p$da2$7@ger.gmane.org


All times are GMT. The time now is 07:43 AM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.