Ansi escape sequences as bytes

别来无恙 提交于 2019-12-02 08:12:37

问题


Could someone run me through the bytes in the ansi escape sequences... I'm coding with pen and paper at the moment, and all the ansi tutorials list the codes as ESC[.... I need to see the actual bytes in the stream. Would one of you gurus with unlimited amount of time devoted to retards like me like to exemplify one or two sequences in bytes? Big thanks!


回答1:


The first Google image hit for "ascii table". You're welcome. Just match the characters in the tutorial with the red characters, and take the corresponding hex value!




回答2:


Escape is 0x1B and [ is 0x5B, so you want 1B5B.




回答3:


You may look for ANSI Sequences to color a terminal (maybe telnet?). I only got a Link for it: Ansisequences...



来源:https://stackoverflow.com/questions/6555995/ansi-escape-sequences-as-bytes

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!