Using Python (Command line version, not IDLE, nor pythonwin)
With Linux, print "\033[33mHello" prints a brown hello. Fine!
With Windows, the VT100 sequence seems to be unknown?
Why? and how can I correct that?
Thanks
Using Python (Command line version, not IDLE, nor pythonwin)
With Linux, print "\033[33mHello" prints a brown hello. Fine!
With Windows, the VT100 sequence seems to be unknown?
Why? and how can I correct that?
(Sigh)
"Why?"
I don't think there ever was a colour VT100, BICBW. I don't know about colour
VT220 either. I once worked with a colour VT320.
Linux consoles simulate some "ANSI" terminal similar to the VT's mentioned above
for historical reasons. It's a quirk maybe; it's not a mandatory feature for
every computer system out there (hint: what was the escape sequence to print a
brown hello on a Macintosh with MacOS 9 and earlier?)
"and how can I correct that?"
Your car does not run on charcoal either, but you don't *correct* that (ie it's
not part of the design of the car).
There was once an ANSI.SYS (on MS DOorS days, that is
that you could load in
your CONFIG.SYS file and then MS-DOS command line recognized ANSI escape
sequences. I don't know if it still exists.
And I just checked on this laptop with Windows XP and it exists! (exclamation
most sincere). Try googling for directions how to load it.
Otherwise, if willing to drop compatibility with escape sequences, you can use
WConio:
http://newcenturycomputers.net/projects/wconio.html
Other related stuff:
http://en.wikipedia.org/wiki/Vt100
http://en.wikipedia.org/wiki/Ansi.sys