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

Re: AW: AW: BUG: TortoiseMerge encoding (UTF-8)

From: Stefan Küng <tortoisesvn_at_gmail.com>
Date: Tue, 12 Aug 2008 19:04:49 +0200

Andreas Schnederle-Wagner - Futureweb.at wrote:
>> Ahem: if there are no utf8 chars in a file, the encoding is the very same as ASCII/ANSI, because in that case the files are identical whether they're in utf8 or not.
>> So: if there are no 'special' chars in your file, it is *not* utf8 encoded but plain ANSI.
>
> Ok now as you say this makes sense! ;-)
> Just made me curious because my Editors always show me that the file is UTF-8 encoded.
>
>> Can you send me the three files you are trying to merge (or ones that show the problem if yours are confidential)?
>
> Files coming in a few Minutes to your E-Mail Adress.
> Since this are original Files I don't want to publish them to the List ;-)

I've changed the encoding detection so it defaults to utf8 now. This
should fix your problem.
Note: there simply is no perfect solution to this: as stated above, a
file can be treated as utf8 or ascii if no special ascii (> 127) or utf8
chars are in the file. And when merging, we also can't assume that the
resulting file should have the encoding of the merge source - that might
not what the user wants either. Who's to say that the user doesn't want
to keep the existing encoding of the file?

But making the default to utf8 is better than ascii I think...

Stefan

-- 
        ___
   oo  // \\      "De Chelonian Mobile"
  (_,\/ \_/ \     TortoiseSVN
    \ \_/_\_/>    The coolest Interface to (Sub)Version Control
    /_/   \_\     http://tortoisesvn.net

Received on 2008-08-12 19:05:12 CEST

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

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