Search code examples
windowsterminalcurses

Programming text user interfaces on modern Windows


Is there any Windows way to go about creating text user interfaces via a terminal control library on modern Windows operating systems ? (7/8/10 etc) I am aware of the curses family of libraries have been ported from their Unix-like systems to work on Windows. But outside of that I can't find anything. Does Windows just assume you are either going to make a program handled by simple input / output to command prompt or make a full blown GUI application?


Solution

  • You can program this sort of functionality using the Windows console API. Which is as simple as #include <windows.h> and making the appropriate API calls. The documentation for the console API is available here: https://learn.microsoft.com/en-us/windows/console/console-functions

    You don't actually need an additional library on top of this to be able to easily program interactive console programs.