Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » ServerTools (WTP) » .html files always Shift_JIS regardless of preferences or content
.html files always Shift_JIS regardless of preferences or content [message #227305] Tue, 27 January 2009 06:44 Go to next message
Ed Wright is currently offline Ed WrightFriend
Messages: 11
Registered: July 2009
Junior Member
Hi,

Originally posted on eclipse.platform and was advised to post here.

Eclipse 3.4 on Linux (was also true in 3.3):

If I create a new *empty* .html file, it is always created with a file
encoding of Shift_JIS, "determined from content". It doesn't matter how
I create the file... I can create an empty, 0 byte file outside of
Eclipse and Eclipse still sets the encoding to Shift_JIS "determined
from content".

If I copy an existing file, containing an html snippet (no headers),
which has UTF-8 content, for which I have manually set the encoding to
UTF-8, to another location, the encoding is reset to Shift_JIS on the copy.

An annoying side note is that when I do reset the encoding type (in
Navigator/Properties), Eclipse tells me UTF-8 conflicts with the content
type *even if the file is empty or contains UTF-8 content*.

This is a major headache for me (apart from the need to manually reset
the content type on every such file) because editing and saving a file
with UTF-8 content, that Eclipse thinks is Shift_JIS, results in
permanently corrupted Japanese text.

Related issue: Somehow in the last few days all of the files (hundreds)
I had painstakingly set to UTF-8 have reverted to Shift_JIS. Don't know
how this happened, but maybe when I was messing with preferences. Is
there any way I can reset the encoding on all the files, rather than
one-by-one?

settings:
---------
env var LANG = ja_JP.utf8

parent folder text file encoding set to UTF-8

preferences:web:html files encoding set to UTF-8

preferences:general:content types:text:html default encoding for all
file associations set to UTF-8

In <project>/.settings/org.eclipse.core.resources.prefs ALL the file
encodings show as UTF-8..... nevertheless, in Navigator/Properties they
show as Shift_JIS.

Am I missing something somewhere? Is this a bug? (Ain't no feature in my
book :) )

Any help much appreciated.

Thanks,
Ed
Re: .html files always Shift_JIS regardless of preferences or content [message #227386 is a reply to message #227305] Tue, 27 January 2009 19:39 Go to previous messageGo to next message
Nick Sandonato is currently offline Nick SandonatoFriend
Messages: 126
Registered: July 2009
Senior Member
Hi Ed,

This may be related to https://bugs.eclipse.org/bugs/show_bug.cgi?id=237567.


Ed Wright wrote:
> Hi,
>
> Originally posted on eclipse.platform and was advised to post here.
>
> Eclipse 3.4 on Linux (was also true in 3.3):
>
> If I create a new *empty* .html file, it is always created with a file
> encoding of Shift_JIS, "determined from content". It doesn't matter how
> I create the file... I can create an empty, 0 byte file outside of
> Eclipse and Eclipse still sets the encoding to Shift_JIS "determined
> from content".
>
> If I copy an existing file, containing an html snippet (no headers),
> which has UTF-8 content, for which I have manually set the encoding to
> UTF-8, to another location, the encoding is reset to Shift_JIS on the copy.
>
> An annoying side note is that when I do reset the encoding type (in
> Navigator/Properties), Eclipse tells me UTF-8 conflicts with the content
> type *even if the file is empty or contains UTF-8 content*.
>
> This is a major headache for me (apart from the need to manually reset
> the content type on every such file) because editing and saving a file
> with UTF-8 content, that Eclipse thinks is Shift_JIS, results in
> permanently corrupted Japanese text.
>
> Related issue: Somehow in the last few days all of the files (hundreds)
> I had painstakingly set to UTF-8 have reverted to Shift_JIS. Don't know
> how this happened, but maybe when I was messing with preferences. Is
> there any way I can reset the encoding on all the files, rather than
> one-by-one?
>
> settings:
> ---------
> env var LANG = ja_JP.utf8
>
> parent folder text file encoding set to UTF-8
>
> preferences:web:html files encoding set to UTF-8
>
> preferences:general:content types:text:html default encoding for all
> file associations set to UTF-8
>
> In <project>/.settings/org.eclipse.core.resources.prefs ALL the file
> encodings show as UTF-8..... nevertheless, in Navigator/Properties they
> show as Shift_JIS.
>
> Am I missing something somewhere? Is this a bug? (Ain't no feature in my
> book :) )
>
> Any help much appreciated.
>
> Thanks,
> Ed
Re: .html files always Shift_JIS regardless of preferences or content [message #227392 is a reply to message #227386] Wed, 28 January 2009 03:14 Go to previous message
Ed Wright is currently offline Ed WrightFriend
Messages: 11
Registered: July 2009
Junior Member
Hi Nick,

On 2009/01/28 04:39, Nick Sandonato wrote:
> Hi Ed,
>
> This may be related to
> https://bugs.eclipse.org/bugs/show_bug.cgi?id=237567.

That does indeed look like the same beastie.

Gets my vote!

Thanks,
Ed
Previous Topic:Can Ganymede generate a build.xml for an ear file?
Next Topic:WSDL Editor error
Goto Forum:
  


Current Time: Tue Mar 19 02:11:34 GMT 2024

Powered by FUDForum. Page generated in 0.01105 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top