In my experience, cat does not perform any translations between file encoding and display encoding. In vim you can view these settings using :set fenc and :set enc. The editor vim can detect some encodings in files and will translate from a file encoding ( fenc) into a display encoding ( enc) set by environment variables (LOCALE, LANG etc). Personally I would set the encoding explicitly, but perhaps there are niche use-cases where it is necessary to use an encoding determined by a special font. The available values for "Script" depend on the font selected. Set "Font used in the terminal Window" to, say, Lucida Console and in that dialog change "script" from Western to Greek and notice the effect this has in both the "Sample" in the dialog and in your cat output after the settings have been applied. You can explore this a bit, set "Remote Character Set" to Use Font Encoding. I guess, by selecting "use font encoding" rather than setting an explicit value, you are telling Putty to use the inherent mappings in the font to find the glyph to use for any received byte values. Normally I would do this by explicitly setting the "remote character set" to "CP437".Įvery font also has an implicit encoding. PuTTY has to be configured to turn 188 into ╝ instead of ¼. If you communicate with a server application that emits characters in say CP437, Putty needs to know that so that it can perform the correct translation into a common encoding that it can use to select appropriate glyphs from available fonts. For example code point 188 is ╝ in CP437, but is ¼ in Unicode. As I expect you know, before Unicode and UTF8 became widespread, there were many different encodings such as CP850 and CP437.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |