Add SetConsoleCursorInfo and GetConsoleCursorInfo to sys/windows package

This commit is contained in:
Christian Seibold
2023-03-18 15:43:31 -05:00
parent 582a72574e
commit 852c8b533c
2 changed files with 8 additions and 0 deletions

View File

@@ -393,6 +393,8 @@ foreign kernel32 {
GetConsoleScreenBufferInfo :: proc(hConsoleOutput: HANDLE, lpConsoleScreenBufferInfo: PCONSOLE_SCREEN_BUFFER_INFO) -> BOOL ---
SetConsoleScreenBufferSize :: proc(hConsoleOutput: HANDLE, dwSize: COORD) -> BOOL ---
SetConsoleWindowInfo :: proc(hConsoleOutput: HANDLE, bAbsolute : BOOL, lpConsoleWindow: ^SMALL_RECT) -> BOOL ---
GetConsoleCursorInfo :: proc(hConsoleOutput: HANDLE, lpConsoleCursorInfo: PCONSOLE_CURSOR_INFO) -> BOOL ---
SetConsoleCursorInfo :: proc(hConsoleOutput: HANDLE, lpConsoleCursorInfo: PCONSOLE_CURSOR_INFO) -> BOOL ---
GetDiskFreeSpaceExW :: proc(
lpDirectoryName: LPCWSTR,

View File

@@ -3941,8 +3941,14 @@ CONSOLE_SCREEN_BUFFER_INFO :: struct {
dwMaximumWindowSize: COORD,
}
CONSOLE_CURSOR_INFO :: struct {
dwSize: DWORD,
bVisible: BOOL,
}
PCONSOLE_SCREEN_BUFFER_INFO :: ^CONSOLE_SCREEN_BUFFER_INFO
PCONSOLE_CURSOR_INFO :: ^CONSOLE_CURSOR_INFO
//
// Networking