Hi !
The implementation used to open file for searching is
TextFile.Open(filePath, wxConvFile)
Solution was provided by Tiwag in this thread (http://forums.codeblocks.org/index.php/topic,6149.0.html) and is for now the best I've found.
Problem is that I don't know any way to find file encoding.
Did you try to set the "default encoding when opening file" to UTF-8 in editor settings ?
With this, I have no problem searching ASCII and UTF-8 files.
Dje
The implementation used to open file for searching is
TextFile.Open(filePath, wxConvFile)
Solution was provided by Tiwag in this thread (http://forums.codeblocks.org/index.php/topic,6149.0.html) and is for now the best I've found.
Problem is that I don't know any way to find file encoding.
You should use C::B's built-in mechanism to read unicode file. Please follow the following steps-
#include "encodingdetector.h"
....
wxString fooFileContent;
EncodingDetector fooFile(_T("foo.cpp"));
if (fooFile.IsOK())
{
fooFileContent = fooFile.GetWxStr();
}
Encoding detection and conversion will be done by C::B automatically. :)