Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
RE: [cdt-dev] character encoding problems

There is a little trick if you can open the file
with the default encoding (e.g. Windows Cp1252).

- open the file
- File > Set Encoding - change to UTF-8
  The non-ASCII characters will be replaced
  by a default replacement character
- Undo - this replaces the content with the previous
  content (and all the non-ASCII characters)
- Save

That's it.

Toni

> -----Original Message-----
> From: cdt-dev-bounces@xxxxxxxxxxx 
> [mailto:cdt-dev-bounces@xxxxxxxxxxx] On Behalf Of Ploett, Norbert
> Sent: Wednesday, September 13, 2006 10:24 AM
> To: CDT General developers list.
> Subject: AW: [cdt-dev] character encoding problems
> 
> Hi Toni,
> 
> thanks for offering support.
> 
> As for "my" sourcefile in  157112 I have changed the 
> offending Umlauts from my name to plain ASCII.
> 
> Is there an eclipse-internal way to convert to UTF-8. I don't 
> know of any tool which can do it.
> 
> 
> Thanks,
> 
> 
> Norbert
> 
> -----Ursprüngliche Nachricht-----
> Von: cdt-dev-bounces@xxxxxxxxxxx 
> [mailto:cdt-dev-bounces@xxxxxxxxxxx] Im Auftrag von Leherbauer, Anton
> Gesendet: Mittwoch, 13. September 2006 10:15
> An: CDT General developers list.
> Betreff: RE: [cdt-dev] character encoding problems
> 
> There are two solutions:
> 
> 1. convert the files to valid UTF-8 and also mark 
>    them as UTF-8 in the project preferences
> 
> 2. replace the offending characters with plain ASCII.
> 
> I'd prefer option 1 and I could also do the conversion
> if nobody objects.
> 
> BTW, it is probably a JVM-dependent issue how
> the builtin decoding methods handle encoding problems.
> The Sun JVM on Windows replaces malformed input bytes
> and unmappable characters by default (as e.g. in Charset#decode()),
> instead of reporting errors.
> 
> Toni
> 
> > -----Original Message-----
> > From: cdt-dev-bounces@xxxxxxxxxxx 
> > [mailto:cdt-dev-bounces@xxxxxxxxxxx] On Behalf Of Chris Recoskie
> > Sent: Wednesday, September 13, 2006 12:13 AM
> > To: cdt-dev@xxxxxxxxxxx
> > Subject: [cdt-dev] character encoding problems
> > 
> > I've been trying to debug some issues on PowerPC Linux and 
> > have been unable
> > to build CDT due to encoding problems on a couple of source 
> > files.  I have
> > filed 157112 and 157113 to track these.
> > 
> > ===========================
> > 
> > Chris Recoskie
> > Team Lead, IBM CDT Team
> > IBM Toronto
> > http://www.eclipse.org/cdt
> > 
> > _______________________________________________
> > cdt-dev mailing list
> > cdt-dev@xxxxxxxxxxx
> > https://dev.eclipse.org/mailman/listinfo/cdt-dev
> > 
> _______________________________________________
> cdt-dev mailing list
> cdt-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/cdt-dev
> _______________________________________________
> cdt-dev mailing list
> cdt-dev@xxxxxxxxxxx
> https://dev.eclipse.org/mailman/listinfo/cdt-dev
> 


Back to the top