Changeset 142 for Include/api_console.sbp
- Timestamp:
- Mar 9, 2007, 10:15:34 PM (18 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
Include/api_console.sbp
r141 r142 3 3 #ifndef _INC_CONSOLE 4 4 #define _INC_CONSOLE 5 6 #ifdef UNICODE 7 Const _FuncName_PeekConsoleInput = "PeekConsoleInputW" 8 Const _FuncName_ReadConsoleInput = "ReadConsoleInputW" 9 Const _FuncName_WriteConsoleInput = "WriteConsoleInputW" 10 Const _FuncName_ReadConsoleOutput = "ReadConsoleOutputW" 11 Const _FuncName_WriteConsoleOutput = "WriteConsoleOutputW" 12 Const _FuncName_ReadConsoleOutputCharacter = "ReadConsoleOutputCharacterW" 13 Const _FuncName_WriteConsoleOutputCharacter = "WriteConsoleOutputCharacterW" 14 Const _FuncName_FillConsoleOutputCharacter = "FillConsoleOutputCharacterW" 15 Const _FuncName_ScrollConsoleScreenBuffer = "ScrollConsoleScreenBufferW" 16 Const _FuncName_GetConsoleTitle = "GetConsoleTitleW" 17 Const _FuncName_SetConsoleTitle = "SetConsoleTitleW" 18 Const _FuncName_ReadConsole = "ReadConsoleW" 19 Const _FuncName_WriteConsole = "WriteConsoleW" 20 #else 21 Const _FuncName_PeekConsoleInput = "PeekConsoleInputA" 22 Const _FuncName_ReadConsoleInput = "ReadConsoleInputA" 23 Const _FuncName_WriteConsoleInput = "WriteConsoleInputA" 24 Const _FuncName_ReadConsoleOutput = "ReadConsoleOutputA" 25 Const _FuncName_WriteConsoleOutput = "WriteConsoleOutputA" 26 Const _FuncName_ReadConsoleOutputCharacter = "ReadConsoleOutputCharacterA" 27 Const _FuncName_WriteConsoleOutputCharacter = "WriteConsoleOutputCharacterA" 28 Const _FuncName_FillConsoleOutputCharacter = "FillConsoleOutputCharacterA" 29 Const _FuncName_ScrollConsoleScreenBuffer = "ScrollConsoleScreenBufferA" 30 Const _FuncName_GetConsoleTitle = "GetConsoleTitleA" 31 Const _FuncName_SetConsoleTitle = "SetConsoleTitleA" 32 Const _FuncName_ReadConsole = "ReadConsoleA" 33 Const _FuncName_WriteConsole = "WriteConsoleA" 34 #endif 5 35 6 36 Type COORD … … 153 183 Const ENABLE_WRAP_AT_EOL_OUTPUT = &H0002 154 184 155 Declare Function PeekConsoleInput Lib "kernel32" Alias "PeekConsoleInputA"(hConsoleInput As HANDLE, ByRef lpBuffer As INPUT_RECORD, nLength As DWord, ByRef lpNumberOfEventsRead As DWord) As BOOL156 Declare Function ReadConsoleInput Lib "kernel32" Alias "ReadConsoleInputA"(hConsoleInput As HANDLE, ByRef lpBuffer As INPUT_RECORD, nLength As DWord, ByRef lpNumberOfEventsRead As DWord) As BOOL157 Declare Function WriteConsoleInput Lib "kernel32" Alias "WriteConsoleInputA"(hConsoleInput As HANDLE, ByRef lpBuffer As INPUT_RECORD, nLength As DWord, ByRef lpNumberOfEventsWritten As DWord) As BOOL158 Declare Function ReadConsoleOutput Lib "kernel32" Alias "ReadConsoleOutputA"(hConsoleOutput As HANDLE, lpBuffer As *CHAR_INFO, ByRef dwBufferSize As COORD, ByRef dwBufferCoord As COORD, ByRef lpReadRegion As SMALL_RECT) As BOOL159 Declare Function WriteConsoleOutput Lib "kernel32" Alias "WriteConsoleOutputA"(hConsoleOutput As HANDLE, lpBuffer As *CHAR_INFO, ByRef dwBufferSize As COORD, ByRef dwBufferCoord As COORD, ByRef lpWriteRegion As SMALL_RECT) As BOOL160 Declare Function ReadConsoleOutputCharacter Lib "kernel32" Alias "ReadConsoleOutputCharacterA"(hConsoleOutput As HANDLE, lpCharacter As LPSTR, nLength As DWord, ByRef dwReadCoord As COORD, ByRef lpNumberOfCharsRead As DWord) As BOOL185 Declare Function PeekConsoleInput Lib "kernel32" Alias _FuncName_PeekConsoleInput (hConsoleInput As HANDLE, ByRef lpBuffer As INPUT_RECORD, nLength As DWord, ByRef lpNumberOfEventsRead As DWord) As BOOL 186 Declare Function ReadConsoleInput Lib "kernel32" Alias _FuncName_ReadConsoleInput (hConsoleInput As HANDLE, ByRef lpBuffer As INPUT_RECORD, nLength As DWord, ByRef lpNumberOfEventsRead As DWord) As BOOL 187 Declare Function WriteConsoleInput Lib "kernel32" Alias _FuncName_WriteConsoleInput (hConsoleInput As HANDLE, ByRef lpBuffer As INPUT_RECORD, nLength As DWord, ByRef lpNumberOfEventsWritten As DWord) As BOOL 188 Declare Function ReadConsoleOutput Lib "kernel32" Alias _FuncName_ReadConsoleOutput (hConsoleOutput As HANDLE, lpBuffer As *CHAR_INFO, ByRef dwBufferSize As COORD, ByRef dwBufferCoord As COORD, ByRef lpReadRegion As SMALL_RECT) As BOOL 189 Declare Function WriteConsoleOutput Lib "kernel32" Alias _FuncName_WriteConsoleOutput (hConsoleOutput As HANDLE, lpBuffer As *CHAR_INFO, ByRef dwBufferSize As COORD, ByRef dwBufferCoord As COORD, ByRef lpWriteRegion As SMALL_RECT) As BOOL 190 Declare Function ReadConsoleOutputCharacter Lib "kernel32" Alias _FuncName_ReadConsoleOutputCharacter (hConsoleOutput As HANDLE, lpCharacter As LPSTR, nLength As DWord, ByRef dwReadCoord As COORD, ByRef lpNumberOfCharsRead As DWord) As BOOL 161 191 Declare Function ReadConsoleOutputAttribute Lib "kernel32" (hConsoleOutput As HANDLE, lpAttribute As *Word, nLength As DWord, ByRef dwReadCoord As COORD, ByRef lpNumberOfAttrsRead As DWord) As BOOL 162 Declare Function WriteConsoleOutputCharacter Lib "kernel32" Alias "WriteConsoleOutputCharacterA"(hConsoleOutput As HANDLE, lpCharacter As LPSTR, nLength As DWord, ByRef dwWriteCoord As COORD, ByRef lpNumberOfCharsWritten As DWord) As BOOL192 Declare Function WriteConsoleOutputCharacter Lib "kernel32" Alias _FuncName_WriteConsoleOutputCharacter (hConsoleOutput As HANDLE, lpCharacter As LPSTR, nLength As DWord, ByRef dwWriteCoord As COORD, ByRef lpNumberOfCharsWritten As DWord) As BOOL 163 193 Declare Function WriteConsoleOutputAttribute Lib "kernel32" (hConsoleOutput As HANDLE, lpAttribute As *Word, nLength As DWord, ByRef dwWriteCoord As COORD, ByRef lpNumberOfAttrsWritten As DWord) As BOOL 164 Declare Function FillConsoleOutputCharacter Lib "kernel32" Alias "FillConsoleOutputCharacterA"(hConsoleOutput As HANDLE, cCharacter As Char, nLength As DWord, ByRef dwWriteCoord As COORD, ByRef lpNumberOfCharsWritten As DWord) As BOOL194 Declare Function FillConsoleOutputCharacter Lib "kernel32" Alias _FuncName_FillConsoleOutputCharacter (hConsoleOutput As HANDLE, cCharacter As Char, nLength As DWord, ByRef dwWriteCoord As COORD, ByRef lpNumberOfCharsWritten As DWord) As BOOL 165 195 Declare Function FillConsoleOutputAttribute Lib "kernel32" (hConsoleOutput As HANDLE, wAttribute As Word, nLength As DWord, ByRef dwWriteCoord As COORD, ByRef lpNumberOfAttrsWritten As DWord) As BOOL 166 196 Declare Function GetConsoleMode Lib "kernel32" (hConsoleHandle As HANDLE, ByRef lpMode As DWord) As BOOL … … 176 206 Declare Function SetConsoleCursorPosition Lib "kernel32" (hConsoleOutput As HANDLE, dwCursorPosition As DWord) As BOOL 177 207 Declare Function SetConsoleCursorInfo Lib "kernel32" (hConsoleOutput As HANDLE, ByRef lpConsoleCursorInfo As CONSOLE_CURSOR_INFO) As BOOL 178 Declare Function ScrollConsoleScreenBuffer Lib "kernel32" Alias "ScrollConsoleScreenBufferA"(hConsoleOutput As HANDLE, ByRef lpScrollRectangle As SMALL_RECT, lpClipRectangle As *SMALL_RECT, ByRef dwDestinationOrigin As COORD, lpFill As *CHAR_INFO) As BOOL208 Declare Function ScrollConsoleScreenBuffer Lib "kernel32" Alias _FuncName_ScrollConsoleScreenBuffer (hConsoleOutput As HANDLE, ByRef lpScrollRectangle As SMALL_RECT, lpClipRectangle As *SMALL_RECT, ByRef dwDestinationOrigin As COORD, lpFill As *CHAR_INFO) As BOOL 179 209 Declare Function SetConsoleWindowInfo Lib "kernel32" (hConsoleOutput As HANDLE, bAbsolute As BOOL, ByRef lpConsoleWindow As SMALL_RECT) As BOOL 180 210 Declare Function SetConsoleTextAttribute Lib "kernel32" (hConsoleOutput As HANDLE, wAttributes As Word) As BOOL … … 183 213 Declare Function AllocConsole Lib "kernel32" () As BOOL 184 214 Declare Function FreeConsole Lib "kernel32" () As BOOL 185 Declare Function GetConsoleTitle Lib "kernel32" Alias "GetConsoleTitleA"(lpConsoleTitle As LPSTR, nSize As DWord) As DWord186 Declare Function SetConsoleTitle Lib "kernel32" Alias "SetConsoleTitleA"(lpConsoleTitle As LPSTR) As BOOL187 Declare Function ReadConsole Lib "kernel32" Alias "ReadConsoleA"(hConsoleInput As HANDLE, lpBuffer As VoidPtr, nNumberOfCharsToRead As DWord, ByRef lpNumberOfCharsRead As DWord, lpReserved As VoidPtr) As BOOL188 Declare Function WriteConsole Lib "kernel32" Alias "WriteConsoleA"(hConsoleOutput As HANDLE, lpBuffer As VoidPtr, nNumberOfCharsToWrite As DWord, ByRef lpNumberOfCharsWritten As DWord, lpReserved As VoidPtr) As BOOL215 Declare Function GetConsoleTitle Lib "kernel32" Alias _FuncName_GetConsoleTitle (lpConsoleTitle As LPSTR, nSize As DWord) As DWord 216 Declare Function SetConsoleTitle Lib "kernel32" Alias _FuncName_SetConsoleTitle (lpConsoleTitle As LPSTR) As BOOL 217 Declare Function ReadConsole Lib "kernel32" Alias _FuncName_ReadConsole (hConsoleInput As HANDLE, lpBuffer As VoidPtr, nNumberOfCharsToRead As DWord, ByRef lpNumberOfCharsRead As DWord, lpReserved As VoidPtr) As BOOL 218 Declare Function WriteConsole Lib "kernel32" Alias _FuncName_WriteConsole (hConsoleOutput As HANDLE, lpBuffer As VoidPtr, nNumberOfCharsToWrite As DWord, ByRef lpNumberOfCharsWritten As DWord, lpReserved As VoidPtr) As BOOL 189 219 190 220 Const CONSOLE_TEXTMODE_BUFFER = 1
Note:
See TracChangeset
for help on using the changeset viewer.