[Lazarus] Change file Encode codepage?

Mattias Gaertner nc-gaertnma at netcologne.de
Thu Aug 18 19:19:01 CEST 2011


On Thu, 18 Aug 2011 18:06:50 +0300
Zaher Dirkey <parmaja at gmail.com> wrote:

> Hi,
> 
> I want to change the file codepage, i do it inside the IDE: "File
> Setting"->"Encoding"-> "UTF8 with BOM"
> We have dialog asked (Change File) (Reopen with another encode),
> 
> 1 - What the different between that options?.

When the IDE opens a file it tries to guess what encoding it is. It
then converts the file in memory to UTF-8.
If you think the IDE guessed right and you
want to convert the file to another encoding, use "Change File".
If you think the IDE guessed wrong and it should open it with another
encoding use the "Reopen".


> 2 - When (Reopen with another encode) it is add strange chars in the first
> line of the file, is that bug?.

That's pretty normal if you open a file and use the wrong encoding
to convert it to UTF-8.

 
> I used last svn Lazarus 0.9.31 with FPC 2.4.4


Mattias




More information about the Lazarus mailing list