Collectives™ on Stack Overflow
Find centralized, trusted content and collaborate around the technologies you use most.
Learn more about Collectives
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
Learn more about Teams
It's been many years since I've looked into this. Maybe when I was just getting into C++. But is it still possible to achieve MS-DOS like graphics on a command line interface? Obviously with some small hacks that you can achieve the color scheme. However I'm looking more into menu options. I.e. radio controls menu select.
And yes I know you can also achieve this probably a little bit easier using SDL. But I was just curious if anyone else has accomplish this and has some details posted on the Internet or can possibly point me in the right direction. If this is not as easy to achieve anymore on windows 10 I'll just go on and find something else to do for fun.
Thanks.
–
–
–
Yes, absolutely. You can either use functions such as
Set/GetConsoleScreenBufferInformationEx
or you can enable VT-100 escape sequences and use those (you'll remember this as
ANSI.sys
in DOS).
That's the more portable method, as the only windows-specific part should be enabling VT-100 mode, everything else should be the same on Linux.
SetConsoleMode:
https://msdn.microsoft.com/en-us/library/windows/desktop/ms686033(v=vs.85).aspx
Or to read and write the console buffer directly:
Console APIs:
https://msdn.microsoft.com/en-us/library/windows/desktop/ms682073(v=vs.85).aspx
Thanks for contributing an answer to Stack Overflow!
-
Please be sure to
answer the question
. Provide details and share your research!
But
avoid
…
-
Asking for help, clarification, or responding to other answers.
-
Making statements based on opinion; back them up with references or personal experience.
To learn more, see our
tips on writing great answers
.