[Github-comments] [geany/geany] File save issue (#2542)

elextr notifications at xxxxx
Sat Jul 4 09:35:36 UTC 2020


@mdziczkowski my comment was in response to your "The problem is that I'm unable to open this file as UTF-8 because there is no possibility to choose the encoding of the opened file in the "file open" dialog" pointing out that you can in fact choose the encoding to read the file in the open dialog instead of Geany using heuristics to decide the encoding to read the file.  Heuristics can be wrong.

As @codebrainz said, the Geany buffer is always UTF-8, the open dialog gives you the choice to select the encoding of the file which is converted into UTF-8 in the buffer, and you can add any UTF-8 character to the buffer.

Looking at your OP, perhaps you meant the "File Save" dialog?  In which case you are correct, the selection is not in the save dialog, the setting in `Menu->Document->Set Encoding` sets the encoding to write the UTF-8 from the buffer to the file.  It defaults to the encoding used to read the file into the buffer but can be changed by the user.

As @codebrainz said, if the encoding at `Menu->Document->Set Encoding` cannot encode a character in the buffer you will get the error in your OP.  He suggested you select ISO-8859-2 which contains the character you added, or UTF-8 to be able to save any character Geany can add to the buffer.



-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/issues/2542#issuecomment-653744617
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.geany.org/pipermail/github-comments/attachments/20200704/e923f6ba/attachment.htm>


More information about the Github-comments mailing list