[darcs-users] Re: Can I disable \xx quoting in record --interactive?

Nigel Rowe rho at swiftdsl.com.au
Mon Mar 21 09:30:54 UTC 2005


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Mon, 21 Mar 2005 19:41, Thomas Zander wrote:
> On Sunday 20 March 2005 21:35, Tommy Pettersson wrote:
> > > You would probably need "show human readable without munging"
> > > even in the apply case as an option (it should not be the
> > > default in the apply case for safety).  Maybe the list of "what
> > > do you want to do with this hunk" choice can include "view it
> > > without hex munging"?
> >
> > This is a terrific work-around until we get proper i18n,
> > I think.
>
> OTOH; the control codes you worry about are all in the really low scales of
> the ascii range (they typically begin with an escape, which is < '0').
> Just like you would escape html with nothing but escaping the '<' and '>'
> chars, you can limit this escaping to just everything lower then '0'.
> More on a full solution below.
>
> > I found a description of EUC-JP and it looks like all multi
> > byte combinations use only bytes in the range 0x80-0xFF.  So it
> > would be easy to make something similar to DARCS_USE_ISPRINT,
> > maybe a DARCS_USE_8BIT.  But I also found some other encodings
> > that use multibytes in the range 0x20-0xFF, and all control
> > chars is below 0x20, so maybe we should just as well allow
> > everything in that range.  I'll think some more about it.
>
<snip>Thomas' comments about encodings</snip>

I think you will also need to \xx quote bytes in the range
0x80-0x9f as well.  For example on ansi/VTxxx style terminals (eg. linux 
console, xterm etc) 0x9b (ESC with bit 8 set) is treated as '0x1b[', ie one 
of the escape code lead-ins.  Eg either 0x1b[2J or 0x9b2J will clear screen.

I'm unsure what other hi-bit control codes may be used.

- -- 
	Nigel Rowe
	rho at swiftdsl.com.au


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.4 (GNU/Linux)

iD8DBQFCPpRcBbmcM2pfckkRAqlbAJ9xxsqr/itQDc6kEIwuSIpmcdU6ewCghsKD
+PZK4lfHjTMoYey5rHNdzTw=
=nX1j
-----END PGP SIGNATURE-----




More information about the darcs-users mailing list