[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: Encoding in our APIs

From: Peter N. Lundblad <peter_at_famlundblad.se>
Date: 2005-05-02 14:17:17 CEST

On Mon, 2 May 2005, [UTF-8] Branko Ä^Libej wrote:

> Peter N. Lundblad wrote:
>
> >Maybe this isn't a very big deal after all. Most people on Windows is use
> >a GUI, which will want consistent encodings. Maybe we should just use the
> >locale encoding and later use the file's encoding if that's known.
> >
> >
> Actually, for GUIs, it would be a lot better if the headers _were_ in
> UTF-8, just not part of the output stream but passed along in some other

Since I'm changing svn_client_diff and svn_client_diff_peg, adding an
header_encoding argument, that's actually possible with the new APIs.

> way. That would be best for the command-line client, too, it would just
> use svn_cmdline_printf to output the headers, and the conversion would
> be automatic.
>

> >I don't know, since I don'"t know how this afects people on Windows in
> >reality. What I *do* know, however, is that just outputting UTF8 is wrong
> >and I'd like to fix that.
> >
> >
> Yup.
>
> >Any input from Windows people is appreciated.
> >
> >
> As I said, I don't think I have a good answer myself, except "stay away
> from Windows command line if you value your sanity"...
>
Heh.

> One of the reasons I'd like to see headers sent to the client
> out-of-band is that I want to convert the Windows console I/O to use
> wide-character functions (on Windows variants that support them),
> because then we'd get Unicode<->console conversion for free (*and* it
> would include transliteration on output, no bad thing). This would
> already work for all commands except "diff" and "blame", but can't work
> for those because the annotations are mixed with the file data.
>

Seems like that would be an improvement. I'm not doing that now, however.
I just fix #1533 making it consistent with our other output.

But, if we change to wchar_t-based functions on Windows, how do we handle
the catual file contents, then?

> I do think that the output from our internal diff can (and should) be
> different than the output from external diffs.
>
this is why I don't want to go down tis route currently.

Regards,
//Peter

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Mon May 2 14:11:25 2005

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.