363 {
364 get
365 {
366 Span<char> initialBuffer = stackalloc char[256];
368 uint num;
369 while (true)
370 {
371 num = 0u;
372 fixed (char* title = valueStringBuilder)
373 {
374 num = global::Interop.Kernel32.GetConsoleTitleW(title, (uint)valueStringBuilder.
Capacity);
375 }
376 if (num == 0)
377 {
379 switch (lastPInvokeError)
380 {
381 case 122:
383 continue;
384 default:
386 case 0:
387 break;
388 }
389 break;
390 }
392 {
393 break;
394 }
396 }
397 valueStringBuilder.Length = (int)num;
398 return valueStringBuilder.
ToString();
399 }
400 set
401 {
402 if (!global::Interop.Kernel32.SetConsoleTitle(
value))
403 {
405 }
406 }
407 }
static Exception GetExceptionForWin32Error(int errorCode, string path="")
static int GetLastPInvokeError()
void EnsureCapacity(int capacity)
override string ToString()