Setting console cursor and font color
How can I set console cursor and its font color without including 开发者_Python百科windows.h
? is there any alternative way available?
There is no platform-independent method for doing this.
Since it seems you are using windows you can use the console calls
see http://msdn.microsoft.com/en-us/library/ms685032(v=vs.85).aspx
alternatively you can use the old ANSI.SYS to color the text, but you would need to load the driver in config.sys for your console.
精彩评论