Encoding issue for French text

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
1
down vote

favorite












My problem: With my Emacs 26.1 on my 10.13.6 Mac, I have a opened a third-party text file, and it turns out I have the wrong encoding set : the text is in French , and the accentuated characters are displayed incorrectly (thus "é" is displayed as a brown 216, "î" as a brown 224, etc).



What I tried : I tried



M-x revert-buffer-with-coding-system latin-1 and
M-x revert-buffer-with-coding-system utf-8 emacs
and nothing changed in the display.



I also tried (and failed) to guess the encoding : it must be an encoding in which "é" is the 216th character. Now é is U+00E9 in Unicode, which gives 233 in decimal. Also é is number 130 in extended ASCII.










share|improve this question





















  • That 216 is in octal => 142 decimal (but I have no clue which encoding it's using). It's not cp863 either.
    – rpluim
    2 hours ago














up vote
1
down vote

favorite












My problem: With my Emacs 26.1 on my 10.13.6 Mac, I have a opened a third-party text file, and it turns out I have the wrong encoding set : the text is in French , and the accentuated characters are displayed incorrectly (thus "é" is displayed as a brown 216, "î" as a brown 224, etc).



What I tried : I tried



M-x revert-buffer-with-coding-system latin-1 and
M-x revert-buffer-with-coding-system utf-8 emacs
and nothing changed in the display.



I also tried (and failed) to guess the encoding : it must be an encoding in which "é" is the 216th character. Now é is U+00E9 in Unicode, which gives 233 in decimal. Also é is number 130 in extended ASCII.










share|improve this question





















  • That 216 is in octal => 142 decimal (but I have no clue which encoding it's using). It's not cp863 either.
    – rpluim
    2 hours ago












up vote
1
down vote

favorite









up vote
1
down vote

favorite











My problem: With my Emacs 26.1 on my 10.13.6 Mac, I have a opened a third-party text file, and it turns out I have the wrong encoding set : the text is in French , and the accentuated characters are displayed incorrectly (thus "é" is displayed as a brown 216, "î" as a brown 224, etc).



What I tried : I tried



M-x revert-buffer-with-coding-system latin-1 and
M-x revert-buffer-with-coding-system utf-8 emacs
and nothing changed in the display.



I also tried (and failed) to guess the encoding : it must be an encoding in which "é" is the 216th character. Now é is U+00E9 in Unicode, which gives 233 in decimal. Also é is number 130 in extended ASCII.










share|improve this question













My problem: With my Emacs 26.1 on my 10.13.6 Mac, I have a opened a third-party text file, and it turns out I have the wrong encoding set : the text is in French , and the accentuated characters are displayed incorrectly (thus "é" is displayed as a brown 216, "î" as a brown 224, etc).



What I tried : I tried



M-x revert-buffer-with-coding-system latin-1 and
M-x revert-buffer-with-coding-system utf-8 emacs
and nothing changed in the display.



I also tried (and failed) to guess the encoding : it must be an encoding in which "é" is the 216th character. Now é is U+00E9 in Unicode, which gives 233 in decimal. Also é is number 130 in extended ASCII.







character-encoding






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked 2 hours ago









Ewan Delanoy

1124




1124











  • That 216 is in octal => 142 decimal (but I have no clue which encoding it's using). It's not cp863 either.
    – rpluim
    2 hours ago
















  • That 216 is in octal => 142 decimal (but I have no clue which encoding it's using). It's not cp863 either.
    – rpluim
    2 hours ago















That 216 is in octal => 142 decimal (but I have no clue which encoding it's using). It's not cp863 either.
– rpluim
2 hours ago




That 216 is in octal => 142 decimal (but I have no clue which encoding it's using). It's not cp863 either.
– rpluim
2 hours ago










1 Answer
1






active

oldest

votes

















up vote
3
down vote



accepted










This is the MacRoman encoding, a legacy encoding from the pre-OSX days of Mac OS. It is available in Emacs as mac-roman.



C-x RET r mac-roman RET yes RET



You may need to select mac-roman-mac, mac-roman-dos or mac-roman-unix explicitly if Emacs doesn't automatically detect the representation of line endings. The mac-roman part is for the encoding of non-ASCII characters.






share|improve this answer




















    Your Answer







    StackExchange.ready(function()
    var channelOptions =
    tags: "".split(" "),
    id: "583"
    ;
    initTagRenderer("".split(" "), "".split(" "), channelOptions);

    StackExchange.using("externalEditor", function()
    // Have to fire editor after snippets, if snippets enabled
    if (StackExchange.settings.snippets.snippetsEnabled)
    StackExchange.using("snippets", function()
    createEditor();
    );

    else
    createEditor();

    );

    function createEditor()
    StackExchange.prepareEditor(
    heartbeatType: 'answer',
    convertImagesToLinks: false,
    noModals: false,
    showLowRepImageUploadWarning: true,
    reputationToPostImages: null,
    bindNavPrevention: true,
    postfix: "",
    onDemand: true,
    discardSelector: ".discard-answer"
    ,immediatelyShowMarkdownHelp:true
    );



    );













     

    draft saved


    draft discarded


















    StackExchange.ready(
    function ()
    StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2femacs.stackexchange.com%2fquestions%2f45129%2fencoding-issue-for-french-text%23new-answer', 'question_page');

    );

    Post as a guest






























    1 Answer
    1






    active

    oldest

    votes








    1 Answer
    1






    active

    oldest

    votes









    active

    oldest

    votes






    active

    oldest

    votes








    up vote
    3
    down vote



    accepted










    This is the MacRoman encoding, a legacy encoding from the pre-OSX days of Mac OS. It is available in Emacs as mac-roman.



    C-x RET r mac-roman RET yes RET



    You may need to select mac-roman-mac, mac-roman-dos or mac-roman-unix explicitly if Emacs doesn't automatically detect the representation of line endings. The mac-roman part is for the encoding of non-ASCII characters.






    share|improve this answer
























      up vote
      3
      down vote



      accepted










      This is the MacRoman encoding, a legacy encoding from the pre-OSX days of Mac OS. It is available in Emacs as mac-roman.



      C-x RET r mac-roman RET yes RET



      You may need to select mac-roman-mac, mac-roman-dos or mac-roman-unix explicitly if Emacs doesn't automatically detect the representation of line endings. The mac-roman part is for the encoding of non-ASCII characters.






      share|improve this answer






















        up vote
        3
        down vote



        accepted







        up vote
        3
        down vote



        accepted






        This is the MacRoman encoding, a legacy encoding from the pre-OSX days of Mac OS. It is available in Emacs as mac-roman.



        C-x RET r mac-roman RET yes RET



        You may need to select mac-roman-mac, mac-roman-dos or mac-roman-unix explicitly if Emacs doesn't automatically detect the representation of line endings. The mac-roman part is for the encoding of non-ASCII characters.






        share|improve this answer












        This is the MacRoman encoding, a legacy encoding from the pre-OSX days of Mac OS. It is available in Emacs as mac-roman.



        C-x RET r mac-roman RET yes RET



        You may need to select mac-roman-mac, mac-roman-dos or mac-roman-unix explicitly if Emacs doesn't automatically detect the representation of line endings. The mac-roman part is for the encoding of non-ASCII characters.







        share|improve this answer












        share|improve this answer



        share|improve this answer










        answered 1 hour ago









        Gilles♦

        12.5k43274




        12.5k43274



























             

            draft saved


            draft discarded















































             


            draft saved


            draft discarded














            StackExchange.ready(
            function ()
            StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2femacs.stackexchange.com%2fquestions%2f45129%2fencoding-issue-for-french-text%23new-answer', 'question_page');

            );

            Post as a guest













































































            Comments

            Popular posts from this blog

            What does second last employer means? [closed]

            List of Gilmore Girls characters

            Confectionery