Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 320785 - Encoding is broken for diff in history view
Summary: Encoding is broken for diff in history view
Status: RESOLVED FIXED
Alias: None
Product: EGit
Classification: Technology
Component: UI (show other bugs)
Version: 0.8.1   Edit
Hardware: Macintosh Mac OS X
: P3 normal (vote)
Target Milestone: 0.9.0-M3   Edit
Assignee: Stefan Lay CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-07-24 03:34 EDT by Ilya Klyuchnikov CLA
Modified: 2010-09-02 11:47 EDT (History)
4 users (show)

See Also:


Attachments
screen shot of egit (296.80 KB, image/png)
2010-07-24 03:35 EDT, Ilya Klyuchnikov CLA
no flags Details
screen shot of gitX (294.64 KB, image/png)
2010-07-24 03:35 EDT, Ilya Klyuchnikov CLA
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Ilya Klyuchnikov CLA 2010-07-24 03:34:13 EDT
I have a project with texts in russian (encoding is UTF-8 and workspace default encoding is also UTF-8). The diff widget in egit history view displays russian texts incorrectly.

See 2 attached screen shots - the first one is for egit (incorrect displaying) and the second one is gitX (correct displaying).

PS. I use eclipse Helios with egit 0.8.4
Comment 1 Ilya Klyuchnikov CLA 2010-07-24 03:35:31 EDT
Created attachment 175125 [details]
screen shot of egit
Comment 2 Ilya Klyuchnikov CLA 2010-07-24 03:35:58 EDT
Created attachment 175126 [details]
screen shot of gitX
Comment 3 Stefan Lay CLA 2010-07-27 07:19:50 EDT
Could be reproduced on Windows Vista.
Comment 4 Stefan Lay CLA 2010-08-30 08:15:02 EDT
Fix proposed: http://egit.eclipse.org/r/#change,1457
Comment 5 Matthias Sohn CLA 2010-08-31 10:08:28 EDT
merged as 81014703c6a679b3a9dcc6a0ac496319497e4512
Comment 6 Ilya Klyuchnikov CLA 2010-09-01 02:11:23 EDT
It is fixed partially: now diff view (as I understand) uses default system encoding for rendering diffs.

Just for example: on Mac default encoding is MacRoman, I use UTF-8 as default encoding in the workspace, now egit shows me diffs as if I used MacRoman encoding, - egit doesn't take into account the actual encoding of resource. 

However, there is a dirty workaround: I use -Dfile.encoding=UTF-8 as an extra parameter when starting eclipse, and it works for me.
Comment 7 Stefan Lay CLA 2010-09-01 07:52:10 EDT
I pushed http://egit.eclipse.org/r/#change,1479 for review to take into account eclipse preferences and project property.
Comment 8 Chris Aniszczyk CLA 2010-09-02 11:47:59 EDT
Fixed as 0c90acfe3886ed886f97b3382acbee9aa6c5f2df.

Thanks Stefan.

Hopefully we don't take much of a performance hit.