Jump to content
Main menu
Main menu
move to sidebar
hide
Navigation
Main page
Recent changes
Random page
Help about MediaWiki
Special pages
Niidae Wiki
Search
Search
Appearance
Create account
Log in
Personal tools
Create account
Log in
Pages for logged out editors
learn more
Contributions
Talk
Editing
ANSI escape code
(section)
Page
Discussion
English
Read
Edit
View history
Tools
Tools
move to sidebar
hide
Actions
Read
Edit
View history
General
What links here
Related changes
Page information
Appearance
move to sidebar
hide
Warning:
You are not logged in. Your IP address will be publicly visible if you make any edits. If you
log in
or
create an account
, your edits will be attributed to your username, along with other benefits.
Anti-spam check. Do
not
fill this in!
== Platform support == [[File:XtermMenus.png|thumb|The Xterm terminal emulator.|alt=Xterm terminal emulator]]In the early 1980s, large amounts of software directly used these sequences to update screen displays. This included everything on [[OpenVMS|VMS]] (which assumed DEC terminals), most software designed to be portable on [[CP/M]] home computers, and even lots of Unix software as it was easier to use than the termcap libraries, such as the shell script examples below in this article. [[Terminal emulator]]s for communicating with remote machines almost always implement ANSI escape codes. This includes anything written to communicate with bulletin-board systems on home and personal computers. On Unix terminal emulators such as [[xterm]] also can communicate with software running on the same machine, and thus software running in X11 under a terminal emulator could assume the ability to write these sequences. As computers got more powerful even built-in displays started supporting them, allowing software to be portable between CP/M systems. There were attempts to extend the escape sequences to support printers<ref>{{cite web |url=http://wiki.amigaos.net/wiki/Printer_Device#Printer_Command_Definitions |title=Amiga Printer Command Definitions |publisher=Commodore |access-date=2013-07-10}}</ref> and as an early PDF-like document storage format, the [[Open Document Architecture]].{{cn|date=November 2023}} === DOS and Windows === The IBM PC, introduced in 1981, did not support these or any other escape sequences for updating the screen. Only a few [[control character]]s ([[BEL (ASCII)|BEL]], [[CR (ASCII)|CR]], [[LF (ASCII)|LF]], [[BS (ASCII)|BS]]) were interpreted by the underlying BIOS.<!-- INT 10h/AH=0Eh --> Any display effects had to be done with BIOS calls, which were notoriously slow, or by directly manipulating the IBM PC hardware. This made any interesting software non-portable and led to the need to duplicate details of the display hardware in [[IBM PC compatible|PC Clone]]s. DOS version 2.0 included an optional [[device driver]] named {{mono|[[ANSI.SYS]]}}. Poor performance, and the fact that it was not installed by default, meant software rarely (if ever) took advantage of it. The [[Windows Console]] did not support ANSI escape sequences, nor did Microsoft provide any method to enable them. Some replacements such as JP Software's [[Take Command Console|TCC]] (formerly 4NT), Michael J. Mefford's ANSI.COM, Jason Hood's {{mono|ANSICON}}<ref name="Ansicon">{{cite web |url=https://github.com/adoxa/ansicon |title=Process ANSI escape sequences for Windows console programs |publisher=Jason Hood's Home page |author-first=Jason |author-last=Hood |date=2005 |access-date=2013-05-09 }}</ref> and Maximus5's [[ConEmu]] enabled ANSI escape sequences. Software such as the Python colorama package<ref>{{cite web |url=https://pypi.python.org/pypi/colorama |title=colorama Β· PyPI |work=Python Package Index |access-date=2022-02-27}}</ref> or [[Cygwin]] modified text in-process as it was sent to the console, extracting the ANSI Escape sequences and emulating them with Windows calls. In 2016, Microsoft released the [[Windows 10]] [[Windows 10 version history#Version 1511 (November Update)|version 1511]] update which unexpectedly implemented support for ANSI escape sequences, over three decades after the debut of Windows.<ref>{{Cite web|url=https://docs.microsoft.com/en-us/windows/console/console-virtual-terminal-sequences|title=Console Virtual Terminal Sequences - Windows Console|last=bitcrazed|website=docs.microsoft.com|language=en-us|access-date=2018-05-30}}</ref> This was done alongside [[Windows Subsystem for Linux]], apparently to allow [[Unix-like]] terminal-based software to use the Windows Console. Windows PowerShell 5.1 enabled this by default, and PowerShell 6 made it possible to embed the necessary ESC character into a string with {{code|`e}}.<ref>{{cite web|url=https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_special_characters?view=powershell-6|title=PowerShell Help: About Special Characters|date=12 January 2023 }}</ref> [[Windows Terminal]], introduced in 2019, supports the sequences by default, and Microsoft intends to replace the Windows Console with Windows Terminal.<ref name="ms-console-roadmap">{{cite web |url = https://docs.microsoft.com/en-us/windows/console/ecosystem-roadmap#roadmap-for-the-future |title = Windows Console and Terminal Ecosystem Roadmap |publisher = Microsoft |date = 2018 |access-date = 2021-03-13 | quote=this includes retiring the classic console host user interface from its default position in favor of Windows Terminal, ConPTY, and virtual terminal sequences. }}</ref>
Summary:
Please note that all contributions to Niidae Wiki may be edited, altered, or removed by other contributors. If you do not want your writing to be edited mercilessly, then do not submit it here.
You are also promising us that you wrote this yourself, or copied it from a public domain or similar free resource (see
Encyclopedia:Copyrights
for details).
Do not submit copyrighted work without permission!
Cancel
Editing help
(opens in new window)
Search
Search
Editing
ANSI escape code
(section)
Add topic