40 [UnsupportedOSPlatform(
"android")]
41 [UnsupportedOSPlatform(
"browser")]
42 [UnsupportedOSPlatform(
"ios")]
43 [UnsupportedOSPlatform(
"tvos")]
64 [UnsupportedOSPlatform(
"android")]
65 [UnsupportedOSPlatform(
"browser")]
66 [UnsupportedOSPlatform(
"ios")]
67 [UnsupportedOSPlatform(
"tvos")]
103 if (encoding ==
null)
116 [UnsupportedOSPlatform(
"android")]
117 [UnsupportedOSPlatform(
"ios")]
118 [UnsupportedOSPlatform(
"tvos")]
195 return strongBox.
Value;
209 return strongBox.
Value;
223 return strongBox.
Value;
234 [UnsupportedOSPlatform(
"android")]
235 [UnsupportedOSPlatform(
"browser")]
236 [UnsupportedOSPlatform(
"ios")]
237 [UnsupportedOSPlatform(
"tvos")]
242 [SupportedOSPlatform(
"windows")]
245 ConsolePal.CursorSize =
value;
249 [SupportedOSPlatform(
"windows")]
252 [SupportedOSPlatform(
"windows")]
255 [UnsupportedOSPlatform(
"android")]
256 [UnsupportedOSPlatform(
"browser")]
257 [UnsupportedOSPlatform(
"ios")]
258 [UnsupportedOSPlatform(
"tvos")]
267 ConsolePal.BackgroundColor =
value;
271 [UnsupportedOSPlatform(
"android")]
272 [UnsupportedOSPlatform(
"browser")]
273 [UnsupportedOSPlatform(
"ios")]
274 [UnsupportedOSPlatform(
"tvos")]
283 ConsolePal.ForegroundColor =
value;
289 [UnsupportedOSPlatform(
"android")]
290 [UnsupportedOSPlatform(
"browser")]
291 [UnsupportedOSPlatform(
"ios")]
292 [UnsupportedOSPlatform(
"tvos")]
297 [SupportedOSPlatform(
"windows")]
300 ConsolePal.BufferWidth =
value;
306 [UnsupportedOSPlatform(
"android")]
307 [UnsupportedOSPlatform(
"browser")]
308 [UnsupportedOSPlatform(
"ios")]
309 [UnsupportedOSPlatform(
"tvos")]
314 [SupportedOSPlatform(
"windows")]
317 ConsolePal.BufferHeight =
value;
327 [SupportedOSPlatform(
"windows")]
330 ConsolePal.WindowLeft =
value;
340 [SupportedOSPlatform(
"windows")]
343 ConsolePal.WindowTop =
value;
349 [UnsupportedOSPlatform(
"android")]
350 [UnsupportedOSPlatform(
"browser")]
351 [UnsupportedOSPlatform(
"ios")]
352 [UnsupportedOSPlatform(
"tvos")]
357 [SupportedOSPlatform(
"windows")]
360 ConsolePal.WindowWidth =
value;
366 [UnsupportedOSPlatform(
"android")]
367 [UnsupportedOSPlatform(
"browser")]
368 [UnsupportedOSPlatform(
"ios")]
369 [UnsupportedOSPlatform(
"tvos")]
374 [SupportedOSPlatform(
"windows")]
377 ConsolePal.WindowHeight =
value;
381 [UnsupportedOSPlatform(
"android")]
382 [UnsupportedOSPlatform(
"browser")]
383 [UnsupportedOSPlatform(
"ios")]
384 [UnsupportedOSPlatform(
"tvos")]
387 [UnsupportedOSPlatform(
"android")]
388 [UnsupportedOSPlatform(
"browser")]
389 [UnsupportedOSPlatform(
"ios")]
390 [UnsupportedOSPlatform(
"tvos")]
395 [SupportedOSPlatform(
"windows")]
400 [UnsupportedOSPlatform(
"android")]
401 [UnsupportedOSPlatform(
"browser")]
402 [UnsupportedOSPlatform(
"ios")]
403 [UnsupportedOSPlatform(
"tvos")]
406 ConsolePal.CursorVisible =
value;
410 [UnsupportedOSPlatform(
"android")]
411 [UnsupportedOSPlatform(
"browser")]
412 [UnsupportedOSPlatform(
"ios")]
413 [UnsupportedOSPlatform(
"tvos")]
426 [UnsupportedOSPlatform(
"android")]
427 [UnsupportedOSPlatform(
"browser")]
428 [UnsupportedOSPlatform(
"ios")]
429 [UnsupportedOSPlatform(
"tvos")]
444 [SupportedOSPlatform(
"windows")]
449 [UnsupportedOSPlatform(
"android")]
450 [UnsupportedOSPlatform(
"browser")]
451 [UnsupportedOSPlatform(
"ios")]
452 [UnsupportedOSPlatform(
"tvos")]
459 [UnsupportedOSPlatform(
"android")]
460 [UnsupportedOSPlatform(
"browser")]
461 [UnsupportedOSPlatform(
"ios")]
462 [UnsupportedOSPlatform(
"tvos")]
471 ConsolePal.TreatControlCAsInput =
value;
475 [UnsupportedOSPlatform(
"android")]
476 [UnsupportedOSPlatform(
"browser")]
477 [UnsupportedOSPlatform(
"ios")]
478 [UnsupportedOSPlatform(
"tvos")]
510 [UnsupportedOSPlatform(
"android")]
511 [UnsupportedOSPlatform(
"browser")]
512 [UnsupportedOSPlatform(
"ios")]
513 [UnsupportedOSPlatform(
"tvos")]
519 [UnsupportedOSPlatform(
"android")]
520 [UnsupportedOSPlatform(
"browser")]
521 [UnsupportedOSPlatform(
"ios")]
522 [UnsupportedOSPlatform(
"tvos")]
536 [UnsupportedOSPlatform(
"android")]
537 [UnsupportedOSPlatform(
"browser")]
538 [UnsupportedOSPlatform(
"ios")]
539 [UnsupportedOSPlatform(
"tvos")]
545 [SupportedOSPlatform(
"windows")]
551 [SupportedOSPlatform(
"windows")]
557 [SupportedOSPlatform(
"windows")]
563 [UnsupportedOSPlatform(
"android")]
564 [UnsupportedOSPlatform(
"browser")]
565 [UnsupportedOSPlatform(
"ios")]
566 [UnsupportedOSPlatform(
"tvos")]
572 [UnsupportedOSPlatform(
"android")]
573 [UnsupportedOSPlatform(
"browser")]
574 [UnsupportedOSPlatform(
"ios")]
575 [UnsupportedOSPlatform(
"tvos")]
581 [SupportedOSPlatform(
"windows")]
582 public static void Beep(
int frequency,
int duration)
587 [SupportedOSPlatform(
"windows")]
588 public static void MoveBufferArea(
int sourceLeft,
int sourceTop,
int sourceWidth,
int sourceHeight,
int targetLeft,
int targetTop)
593 [SupportedOSPlatform(
"windows")]
594 public static void MoveBufferArea(
int sourceLeft,
int sourceTop,
int sourceWidth,
int sourceHeight,
int targetLeft,
int targetTop,
char sourceChar,
ConsoleColor sourceForeColor,
ConsoleColor sourceBackColor)
596 ConsolePal.
MoveBufferArea(sourceLeft, sourceTop, sourceWidth, sourceHeight, targetLeft, targetTop, sourceChar, sourceForeColor, sourceBackColor);
599 [UnsupportedOSPlatform(
"android")]
600 [UnsupportedOSPlatform(
"ios")]
601 [UnsupportedOSPlatform(
"tvos")]
607 [UnsupportedOSPlatform(
"android")]
608 [UnsupportedOSPlatform(
"browser")]
609 [UnsupportedOSPlatform(
"ios")]
610 [UnsupportedOSPlatform(
"tvos")]
613 if (left < 0 || left >= 32767)
617 if (top < 0 || top >= 32767)
624 [UnsupportedOSPlatform(
"android")]
625 [UnsupportedOSPlatform(
"browser")]
626 [UnsupportedOSPlatform(
"ios")]
627 [UnsupportedOSPlatform(
"tvos")]
633 [UnsupportedOSPlatform(
"android")]
634 [UnsupportedOSPlatform(
"browser")]
672 [UnsupportedOSPlatform(
"android")]
673 [UnsupportedOSPlatform(
"browser")]
674 [UnsupportedOSPlatform(
"ios")]
675 [UnsupportedOSPlatform(
"tvos")]
717 [UnsupportedOSPlatform(
"android")]
718 [UnsupportedOSPlatform(
"browser")]
725 [UnsupportedOSPlatform(
"android")]
726 [UnsupportedOSPlatform(
"browser")]
729 return In.ReadLine();
787 [CLSCompliant(
false)]
800 [CLSCompliant(
false)]
856 public static void Write(
string format,
object? arg0,
object? arg1)
862 public static void Write(
string format,
object? arg0,
object? arg1,
object? arg2)
929 [CLSCompliant(
false)]
942 [CLSCompliant(
false)]
963 if (consoleCancelEventHandler !=
null)
966 consoleCancelEventArgs.Cancel = ctx.
Cancel;
967 consoleCancelEventHandler(
null, consoleCancelEventArgs);
968 ctx.Cancel = consoleCancelEventArgs.
Cancel;
static bool TreatControlCAsInput
static bool IsOutputRedirectedCore()
static Encoding InputEncoding
static int int Top GetCursorPosition()
static bool CursorVisible
static void SetBufferSize(int width, int height)
static unsafe string Title
static Stream OpenStandardInput()
static void SetConsoleOutputEncoding(Encoding enc)
static void EnsureConsoleInitialized()
static int LargestWindowHeight
static Stream OpenStandardError()
static unsafe void SetWindowPosition(int left, int top)
static TextReader GetOrCreateReader()
static int LargestWindowWidth
static bool IsErrorRedirectedCore()
static unsafe void SetWindowSize(int width, int height)
static ConsoleColor ForegroundColor
static Stream OpenStandardOutput()
static void SetCursorPosition(int left, int top)
static Encoding OutputEncoding
static bool IsInputRedirectedCore()
static ConsoleKeyInfo ReadKey(bool intercept)
static unsafe void MoveBufferArea(int sourceLeft, int sourceTop, int sourceWidth, int sourceHeight, int targetLeft, int targetTop, char sourceChar, ConsoleColor sourceForeColor, ConsoleColor sourceBackColor)
static void SetConsoleInputEncoding(Encoding enc)
static ConsoleColor BackgroundColor
static void Write(string format, object? arg0)
static void Beep(int frequency, int duration)
static void CheckNonNull(object obj, string paramName)
static void WriteLine(char[]? buffer)
static void Write(bool value)
static int LargestWindowHeight
static void SetWindowPosition(int left, int top)
static ConsoleCancelEventHandler s_cancelCallbacks
static void MoveBufferArea(int sourceLeft, int sourceTop, int sourceWidth, int sourceHeight, int targetLeft, int targetTop, char sourceChar, ConsoleColor sourceForeColor, ConsoleColor sourceBackColor)
static void SetIn(TextReader newIn)
static void SetBufferSize(int width, int height)
static StrongBox< bool > _isStdOutRedirected
static void Write(string? value)
static void Write(double value)
static void WriteLine(long value)
static void Write(char value)
static ConsoleColor ForegroundColor
static TextWriter CreateOutputWriter(Stream outputStream)
static bool IsInputRedirected
static StrongBox< bool > _isStdErrRedirected
static Stream OpenStandardOutput()
static Stream OpenStandardError()
static void Write(uint value)
static void WriteLine(string format, params object?[]? arg)
static ConsoleColor BackgroundColor
static Encoding InputEncoding
static void Write(object? value)
static ConsoleKeyInfo ReadKey()
static void SetError(TextWriter newError)
static void WriteLine(string? value)
static void WriteLine(string format, object? arg0)
static bool IsErrorRedirected
static Encoding OutputEncoding
static void WriteLine(uint value)
static void WriteLine(double value)
static void WriteLine(char value)
static void Write(int value)
static void WriteLine(int value)
static Encoding s_inputEncoding
static void HandlePosixSignal(PosixSignalContext ctx)
static void SetCursorPosition(int left, int top)
static StrongBox< bool > _isStdInRedirected
static Encoding s_outputEncoding
static void WriteLine(bool value)
static void Write(char[] buffer, int index, int count)
static int int Top GetCursorPosition()
static PosixSignalRegistration s_sigIntRegistration
static readonly object s_syncObject
static Stream OpenStandardError(int bufferSize)
static ? string ReadLine()
static void Write(string format, params object?[]? arg)
static bool s_isErrorTextWriterRedirected
static Stream OpenStandardOutput(int bufferSize)
static ConsoleKeyInfo ReadKey(bool intercept)
static void Write(string format, object? arg0, object? arg1)
static ? ConsoleCancelEventHandler CancelKeyPress
static void WriteLine(float value)
static void WriteLine(string format, object? arg0, object? arg1)
static bool CursorVisible
static void Write(char[]? buffer)
static void Write(long value)
static Stream OpenStandardInput()
static void MoveBufferArea(int sourceLeft, int sourceTop, int sourceWidth, int sourceHeight, int targetLeft, int targetTop)
static void WriteLine(object? value)
static void Write(string format, object? arg0, object? arg1, object? arg2)
static void WriteLine(ulong value)
static bool TreatControlCAsInput
static TextWriter s_error
static int LargestWindowWidth
static Stream OpenStandardInput(int bufferSize)
static bool IsOutputRedirected
static void WriteLine(decimal value)
static void SetWindowSize(int width, int height)
static void SetOut(TextWriter newOut)
static PosixSignalRegistration s_sigQuitRegistration
static void WriteLine(char[] buffer, int index, int count)
static void Write(ulong value)
static void WriteLine(string format, object? arg0, object? arg1, object? arg2)
static void Write(decimal value)
static void Write(float value)
static bool s_isOutTextWriterRedirected
static ? Delegate Remove(Delegate? source, Delegate? value)
static ? Delegate Combine(Delegate? a, Delegate? b)
static new readonly StreamWriter Null
static readonly Stream Null
static SyncTextReader GetSynchronizedTextReader(TextReader reader)
static TextWriter Synchronized(TextWriter writer)
static PosixSignalRegistration Create(PosixSignal signal, Action< PosixSignalContext > handler)
static string InvalidOperation_ConsoleKeyAvailableOnFile
static string ArgumentOutOfRange_ConsoleBufferBoundaries
static string ArgumentOutOfRange_NeedNonNegNum
static bool Read(ref bool location)
static void Write(ref bool location, bool value)
delegate void ConsoleCancelEventHandler(object? sender, ConsoleCancelEventArgs e)