Bug 362604

Summary: Kate on Windows doesn't recognize UTF-8 encoding, even using BOM
Product: [Applications] kate Reporter: Cristian Adam <cristian.adam>
Component: encodingAssignee: KWrite Developers <kwrite-bugs-null>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Microsoft Windows   
OS: Microsoft Windows   
Latest Commit: Version Fixed In:

Description Cristian Adam 2016-05-02 20:25:58 UTC
Installed Kate version 16.07.70 on Windows 10 and opened an UTF-8 encoded text file.

File  was showing the pretty UTF-8 characters in ISO-8859-1 encoding.

Set the fallback encoding to UTF-8. Reopened the file, same story.

Clicked on adding the UTF-8 BOM to the file. Reopened the file, same story.

UTF-8 files are default also on Windows. I've created that text file using Notepad++. I was at least expecting BOM to work. It didn't.
Comment 1 Dominik Haumann 2016-05-07 17:45:36 UTC
Hi Christian, could you please attach a demo file before and after the save? It would help us to reproduce and see what happens.

Usually, Kate should detect the BOM (see Tools > Add Byte Order Mark for current file, or general settings in Settings > Configure Kate > Open/Save > in the General tab "Enable byte order mark".

If you play around with these settings, does anything change?

Also, could you please attach a screenshot of your Open/Save config page? It contains all the Encoding stuff that is used.
Comment 2 Christoph Cullmann 2016-05-28 18:41:42 UTC
Git commit 0c5c19f1cf618adfa151f0951a082c7228ccd53f by Christoph Cullmann.
Committed on 28/05/2016 at 18:41.
Pushed by cullmann into branch 'master'.

Fix default encoding to UTF-8

REVIEW: 128036

M  +4    -1    src/utils/kateconfig.cpp

http://commits.kde.org/ktexteditor/0c5c19f1cf618adfa151f0951a082c7228ccd53f