Re: [PATCH]console:UTF-8 mode compatibility fixes

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, Feb 19, 2006 at 09:24:26AM +0500, Alexander E. Patrakov wrote:
> Adam Tlałka wrote:
> 
> >Maybe I should remember all bytes of the UTF-sequence to use their 
> >values as a last resort char in case of malformed sequence and 0xfffd
> >not defined?
> 
> Please don't do that. Display question marks instead in the case when 
> 0xfffd is not defined.

Look at the original code. If conv_uni_to_pc fails and there is no replacement
char (after a clear_unimap for example) and we using US-ASCII we rather
should see something then sequences of '?' chars.
Maybe I could change this to:

if (tc == -4) {
	if (c < 128)
		tc = c;
	else
		tc = '?';
}

What about that?

Remembering of original bytes is needed if we could then remember
them in a way so paste from screen gives us the same sequence as it was
in input. With current console design it is impossible is case
of correct UTF-8 sequences containing undisplayable glyphs or malformed
sequences. So I can remove that part of patch and it will wait until
this functionality will be implemented - not so easy but can
be done IMHO and worth it to obtain properly working selection
and copying in UTF-8 mode.

Regards
-- 
Adam Tla�ka      mailto:[email protected]    ^v^ ^v^ ^v^
System  & Network Administration Group           ~~~~~~
Computer Center,  Gda�University of Technology, Poland
PGP public key:   finger [email protected]
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to [email protected]
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

[Index of Archives]     [Kernel Newbies]     [Netfilter]     [Bugtraq]     [Photo]     [Stuff]     [Gimp]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Video 4 Linux]     [Linux for the blind]     [Linux Resources]
  Powered by Linux