Bug 13949 - DBCS: bogus at text compare
Summary: DBCS: bogus at text compare
Status: RESOLVED DUPLICATE of bug 5399
Alias: None
Product: Platform
Classification: Eclipse Project
Component: Compare (show other bugs)
Version: 2.0   Edit
Hardware: PC Windows All
: P1 critical (vote)
Target Milestone: 2.0 F3   Edit
Assignee: Andre Weinand CLA
QA Contact:
URL:
Whiteboard:
Keywords:
: 12855 (view as bug list)
Depends on:
Blocks:
 
Reported: 2002-04-16 17:51 EDT by Masayuki Fuse CLA
Modified: 2002-09-03 14:04 EDT (History)
6 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Masayuki Fuse CLA 2002-04-16 17:51:32 EDT
Text compare for .project xml file display bogus for DBCS name. The compare 
function will not manage the file encoding to display.

STEPS
1) create a project with DBCS name
2) right crick and select Share Project, then select proper cvs
3) Workspace file: .profile will be displayed
4) The DBCS name referred by the name tag displays bogus. UTF-8 encoding should 
be considered properly to display the DBCS.
Comment 1 Andre Weinand CLA 2002-04-24 08:37:19 EDT
Eclipse editors in general don't interpret the encoding tag of xml files. As a 
consequence double byte strings are not shown correctly.

Moving to UI.
Comment 2 Nick Edgar CLA 2002-04-24 12:19:20 EDT
As part of the encoding work, we are looking at how to properly handle UTF 
encoded files, in addition to having a global encoding preference.
XML files are another case where the encoding is indicated by the file itself.
All components in Eclipse should process text files similarly, not just the 
editors.
Comment 3 Masayuki Fuse CLA 2002-04-24 14:21:02 EDT
Although flat file encoding depends on platform locale, the set of file should 
be portable in eclipse family.
There is a encoding option in JBuilder when we create a project. I assume that 
it might be used runtime locale encoding for the default and we can set other 
encoding for the project if we need. For example we can use set of files on 
Windows that were created on Linux at the project by setting encoding properly. 
CVS does not have encoding conversion at any operations. We need an absorbed 
function in eclipse.
Comment 4 Nick Edgar CLA 2002-04-24 14:36:48 EDT
The current plan is to have a single global preference for the encoding, rather 
than a per-project preference.
Comment 5 Masayuki Fuse CLA 2002-04-25 15:34:52 EDT
prioritised must fix for 2.0 release
Comment 6 Nick Edgar CLA 2002-04-27 21:32:02 EDT
Please clarify whether the issue here is with the file name or the file 
contents.  The initial description refers to the name.  The rest of the 
comments refer to the contents.
In general, editors which know nothing about XML cannot parse it to determine 
the encoding.
If there is an issue with the file name, that is more critical and may involve 
Core behaviour.
Comment 7 Masayuki Fuse CLA 2002-04-27 22:22:27 EDT
It's about contents. The initial description is about DBCS project name in a 
<name> tag in .profile, it's about contents of xml file encoded by UTF-8.
Comment 8 Nick Edgar CLA 2002-05-14 14:39:27 EDT
Will the recent encoding changes address this problem?
Comment 9 Kai-Uwe Maetzel CLA 2002-06-05 05:10:55 EDT
The problem is addressed only partially. Compare will respect the workbench 
encoding preference. Thus, files written with this encoding will correctly be 
presented.

However, this does not solve the issue in general. Still open:
- dealing with xml files that are self describing in respect to encoding
- support for file specific encodings when saving
- encoding display option for the compare view

The general issue can not be solved for 2.0 as it requires Core to open up for 
the encoding issue. 

Reassign Compare to ensure that all files are read honoring the workbench 
encoding preference.
Comment 10 Andre Weinand CLA 2002-06-06 06:23:55 EDT
Fixed for 20020606
The Compare plugin now respects the workbench encoding preference.
Comment 11 Andre Weinand CLA 2002-06-06 06:26:05 EDT
Fix reviewed by Dirk Baeumer
Comment 12 Andre Weinand CLA 2002-06-06 08:55:41 EDT
*** Bug 12855 has been marked as a duplicate of this bug. ***
Comment 13 Masayuki Fuse CLA 2002-06-06 11:13:52 EDT
I've just download the integration build 20020606, but it didn't fix at all.
Could you tell me the fixed build to verify? or anything I have to configure 
to display correctly?
Comment 14 Andre Weinand CLA 2002-06-06 11:31:01 EDT
Did you set the 'Text File Encoding' in Preferences/Workbench/Editors to UTF-8?
As mentioned before the platform does not yet look into xml-files for 
determining the encoding.
Comment 15 Masayuki Fuse CLA 2002-06-06 21:54:46 EDT
Once changing the editor encoding to UTF-8, all of files even java program file 
will be treated as UTF-8 file. This will lose interoperability. In general, 
java program file encoding should be platform encoding. I don't accept the 
current fix.
Comment 16 Kevin Haaland CLA 2002-09-03 14:04:33 EDT

*** This bug has been marked as a duplicate of 5399 ***