Skip to content
This repository has been archived by the owner on Jun 2, 2024. It is now read-only.

Incorrectly adjusts encoding when switching between tabs #12

Open
RichardSlater opened this issue Apr 8, 2016 · 4 comments
Open

Incorrectly adjusts encoding when switching between tabs #12

RichardSlater opened this issue Apr 8, 2016 · 4 comments

Comments

@RichardSlater
Copy link

This issue appears only to be observable when switching between tabs in the editor, specifically if a UTF8 file is loaded and crucially it contains a high-order character from the Unicode set when the focus is shifted away from the tab to another tab, in the example below the settings tab and then the original tab is selected the encoding is switched to an inappropriate encoding:

Screenshot showing the encoding changing when switching tabs.

In this example I used only the UTF-8 text 278°C which was then substituted through encoding to 278째C in EUC-KR

Repro Steps

  1. Create a new empty text file
  2. Add the following characters 278°C
  3. Create a new tab with Ctrl-N
  4. Switch back to the original tab with Ctrl-Tab

Expected: Encoding of the original file to be retained as UTF-8
Actual: Encoding of the original file is changed to EUC-KR and the ° symbol is replaced with

Versions

  • Atom: 1.7.0-beta5
  • OS: Microsoft Windows 10 Pro
  • Misc
    • apm 1.9.2
    • npm 2.13.3
    • node 0.10.40
    • python
    • git 2.7.4.windows.1
    • visual studio 2013
@jb-alvarado
Copy link

Here I have a similar problem, with file how have german "Umlaute" like äüö. It change the encoding to EUC-JP, even if I have put this to disallowed encodings.

@martinmahs
Copy link

Having same problem here.
It should either respect an encoding change and maybe store this info in local database (eh?) or maybe it should be possible to add comments to a file, which auto-encoding will recognize.
For example if auto-encoding sees "auto-encoding:utf-8" in a file, it should not try to guess/auto-detect encoding, as the author has forced this encoding.

Makes sense?

And thanks for an otherwise great plugin - by far the best for atom so far :)
Kind regards,
Martin

@JAAdrian
Copy link

I am facing the same issue on Linux Mint 18 and would second @martinmahs suggestions.

Otherwise, great package!
Best regards,
Jens

t-ishii added a commit that referenced this issue Apr 14, 2017
@t-ishii
Copy link
Owner

t-ishii commented Apr 14, 2017

hi.
supported auto-encoding: encoding-type syntax.
56039a5

t-ishii added a commit that referenced this issue Apr 18, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants