#include <windows.h>
#include <stdio.h>
#include <stdarg.h>
#include "../console.h"
#include "../../common/platform.h"
#include "../../common/common_utils.h"
#include "../../string/wtstring.h"

Functions | |
| PUBLIC wtBoolean | ConsoleWindow_Init (void) |
| Initialize hooks to console window. | |
| PUBLIC void | ConsoleWindow_Shutdown (void) |
| Remove hooks to console window. | |
| PUBLIC void | CWaitForConsoleKeyInput (void) |
| Wait for user input on console window. | |
| PUBLIC void | CPrintMsg (W32 textColour, const char *msg,...) |
| Print formatted output to the console output stream. | |
| PUBLIC void | CProgressBar (void) |
| Print progress spinner to console output stream. | |
Variables | |
| PRIVATE HANDLE | hConsoleScrnBuffer = INVALID_HANDLE_VALUE |
| PRIVATE HANDLE | hStdin = INVALID_HANDLE_VALUE |
| PRIVATE char | oldConsoleTitle [MAX_PATH] |
| PRIVATE DWORD | nOldTitleSize |
| WORD | wBGColourAttribute = 0 |
| DWORD | saveOldMode |
| const char * | APPLICATION_STRING |
| const char * | VERSION_STRING |
| PRIVATE const char | progressText [4] = { '|', '/', '-', '\\' } |
| PRIVATE W32 | index = 0 |
Interface to console window [Windows].
| PUBLIC wtBoolean ConsoleWindow_Init | ( | void | ) |
Initialize hooks to console window.


| PUBLIC void ConsoleWindow_Shutdown | ( | void | ) |
Remove hooks to console window.

| PUBLIC void CPrintMsg | ( | W32 | textColour, | |
| const char * | msg, | |||
| ... | ||||
| ) |
Print formatted output to the console output stream.
| [in] | textColour | Text colour [ TC_RED, TC_GREEN, TC_BLUE, TC_WHITE, TC_CYAN, TC_YELLOW, TC_MAGENTA ] |
| [in] | msg | Format control. |
| [in] | ... | Optional arguments. |

| PUBLIC void CProgressBar | ( | void | ) |
Print progress spinner to console output stream.
| PUBLIC void CWaitForConsoleKeyInput | ( | void | ) |
Wait for user input on console window.
