2 * PROJECT: ReactOS Console Utilities Library
3 * LICENSE: GPL-2.0+ (https://spdx.org/licenses/GPL-2.0+)
4 * PURPOSE: Provides basic abstraction wrappers around CRT streams or
5 * Win32 console API I/O functions, to deal with i18n + Unicode
7 * COPYRIGHT: Copyright 2017-2018 ReactOS Team
8 * Copyright 2017-2018 Hermes Belusca-Maito
15 * @brief Console I/O utility API -- Output
18 #ifndef __OUTSTREAM_H__
19 #define __OUTSTREAM_H__
24 * Enable this define if you want to only use CRT functions to output
25 * UNICODE stream to the console, as in the way explained by
26 * http://archives.miloush.net/michkap/archive/2008/03/18/8306597.html
28 /** NOTE: Experimental! Don't use USE_CRT yet because output to console is a bit broken **/
32 #error The ConUtils library at the moment only supports compilation with _UNICODE defined!
39 // Shadow type, implementation-specific
40 typedef struct _CON_STREAM CON_STREAM
, *PCON_STREAM
;
42 // typedef INT (__stdcall *CON_READ_FUNC)(IN PCON_STREAM, IN PTCHAR, IN DWORD);
44 typedef INT (__stdcall
*CON_WRITE_FUNC
)(IN PCON_STREAM
, IN PTCHAR
, IN DWORD
);
50 IN PCON_STREAM Stream
,
56 IN PCON_STREAM Stream
,
62 IN PCON_STREAM Stream
,
67 IN PCON_STREAM Stream
,
74 IN PCON_STREAM Stream
,
80 IN PCON_STREAM Stream
,
81 IN HINSTANCE hInstance OPTIONAL
,
83 IN LANGID LanguageId
);
87 IN PCON_STREAM Stream
,
92 IN PCON_STREAM Stream
,
93 IN HINSTANCE hInstance OPTIONAL
,
100 IN PCON_STREAM Stream
,
107 IN PCON_STREAM Stream
,
108 IN HINSTANCE hInstance OPTIONAL
,
110 IN LANGID LanguageId
,
116 IN PCON_STREAM Stream
,
122 IN PCON_STREAM Stream
,
124 IN LPCVOID lpSource OPTIONAL
,
125 IN DWORD dwMessageId
,
126 IN DWORD dwLanguageId
);
130 IN PCON_STREAM Stream
,
132 IN LPCVOID lpSource OPTIONAL
,
133 IN DWORD dwMessageId
,
134 IN DWORD dwLanguageId
,
139 IN PCON_STREAM Stream
,
141 IN LPCVOID lpSource OPTIONAL
,
142 IN DWORD dwMessageId
,
143 IN DWORD dwLanguageId
,
144 IN
va_list *Arguments OPTIONAL
);
149 IN PCON_STREAM Stream
,
151 IN LPCVOID lpSource OPTIONAL
,
152 IN DWORD dwMessageId
,
153 IN DWORD dwLanguageId
,
158 IN PCON_STREAM Stream
,
159 IN HINSTANCE hInstance OPTIONAL
,
162 IN LANGID LanguageId
,
163 IN
va_list *Arguments OPTIONAL
);
167 IN PCON_STREAM Stream
,
170 IN
va_list *Arguments OPTIONAL
);
175 IN PCON_STREAM Stream
,
176 IN HINSTANCE hInstance OPTIONAL
,
179 IN LANGID LanguageId
,
185 IN PCON_STREAM Stream
,
193 ConClearLine(IN PCON_STREAM Stream
);
200 #endif /* __OUTSTREAM_H__ */