Re: Eclips, .string files, and default encoding
Re: Eclips, .string files, and default encoding
- Subject: Re: Eclips, .string files, and default encoding
- From: Chuck Hill <email@hidden>
- Date: Tue, 23 Jan 2007 10:13:44 -0800
Hi François,
The WOResourceManager can't (usually can't) distinguish between UTF-8
and MacRoman (and others). The two solutions that I know of are
1. Use UTF-16
2. Use Project Wonder which has a replacement localization scheme
that actually works with UTF-8.
Chuck
On Jan 23, 2007, at 1:35 AM, François Reboursier wrote:
Hi folks,
I'm in the processing of making my app multi-lingual, using
'WOApplication.application().resourceManager().stringForKey()' .
My .strings files are encoded in UTF-8, so are my .java files and
my Eclipse project (alt-enter on the root of my project: UTF-8 is
everywhere). I've triple-checked this with BBEdit.
But when using strings returned by stringForKey(), an extra
garbage character is inserted before each accented or special
character: my .strings file seem not to be read as UTF-8.
When running the following piece of code:
OutputStreamWriter out = new OutputStreamWriter(new
ByteArrayOutputStream());
System.out.println("DEFAULT ENCODING: "+ out.getEncoding());
I see that my default encoding is 'MacRoman'. Is there a way to
change this via a javac setting in Eclipse (and how ? ), or in code ?
Regards,
François
--
François Reboursier - Software Engineer - Mauna Kea Technologies
This message and any attached documents are CONFIDENTIAL and
intended only for the use of the intended recipient.
Ce message et tous les documents attachés sont CONFIDENTIELS et à
la seule attention du destinataire pour lequel ils ont été écrits.
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
40global-village.net
This email sent to email@hidden
--
Practical WebObjects - for developers who want to increase their
overall knowledge of WebObjects or who are trying to solve specific
problems.
http://www.global-village.net/products/practical_webobjects
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden