SHARE
TWEET

Maximize.Console.C.Jiiro

a guest Sep 16th, 2019 97 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. struct SMALL_RECT {
  2.     SHORT Left;
  3.     SHORT Top;
  4.     SHORT Right;
  5.     SHORT Bottom;
  6. };
  7. void adjustWindowSize(){
  8.     struct SMALL_RECT test;
  9.  
  10.     HANDLE hStdout;
  11.     COORD coord;
  12.     BOOL ok;
  13.  
  14.     hStdout = GetStdHandle(STD_OUTPUT_HANDLE);
  15.     coord.X = 100;
  16.     coord.Y = 50;
  17.     ok = SetConsoleScreenBufferSize(hStdout, coord);
  18.  
  19.     test.Left = 0;
  20.     test.Top = 0;
  21.     test.Right = coord.X-1;
  22.     test.Bottom = coord.Y-1;
  23.  
  24.     SetConsoleWindowInfo(hStdout, ok, &test);
  25.  
  26. } //sets console to full screen by default
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top