Search code examples
matlabutf-8utf-16

Set MATLAB's default character set to UTF-16 accidentally, now it seems broken


I did this in MATLAB

feature('DefaultCharacterSet','UTF-16');

I was trying to see if that would allow me to display an overscore in some text, which always displayed as a ?.

So now everything errors. I do feel a little dumb, but there should have a warning or a confirmation dialog. I can reinstall, if that is my only option, but do I have any another options?


Solution

  • Restart.

    It seems to be a temporary setting, what threw errors then, is fine now.

    Also never run this:

    feature('DefaultCharacterSet','UTF-16');
    

    This will not work if you do run the above :

    feature('DefaultCharacterSet','UTF-8');