Merge pull request #2394 from krixano/master

Add SetConsoleCursorInfo and GetConsoleCursorInfo to sys/windows package
This commit is contained in:
Jeroen van Rijn
2023-03-18 21:57:14 +01:00
committed by GitHub
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