public static void Draw(ScreenRegion region) { region.rect.RefreshSides(); rect = new SmallRect() { Left = (short)region.rect.left, Top = (short)region.rect.top, Right = (short)(region.rect.right + 1), Bottom = (short)(region.rect.bottom + 1) }; WriteConsoleOutput(handle, ConvertToCharInfo(region), new InteropCoord(region.rect.size), new InteropCoord(0, 0), ref rect); }
static extern bool WriteConsoleOutput( SafeFileHandle hConsoleOutput, CharInfo[] lpBuffer, InteropCoord dwBufferSize, InteropCoord dwBufferCoord, ref SmallRect lpWriteRegion);