FreeBASIC  0.91.0
io_screensize.c
Go to the documentation of this file.
1 /* size of the screen buffer */
2 
3 #include "../fb.h"
4 #include "fb_private_console.h"
5 
6 void fb_ConsoleGetScreenSizeEx( HANDLE hConsole, int *cols, int *rows )
7 {
8  CONSOLE_SCREEN_BUFFER_INFO info;
9  if( GetConsoleScreenBufferInfo( hConsole, &info )==0 ) {
10  if( cols != NULL )
11  *cols = FB_SCRN_DEFAULT_WIDTH;
12  if( rows != NULL )
13  *rows = FB_SCRN_DEFAULT_HEIGHT;
14  } else {
15  if( cols != NULL )
16  *cols = info.dwSize.X;
17  if( rows != NULL )
18  *rows = info.dwSize.Y;
19  }
20 }
21 
22 FBCALL void fb_ConsoleGetScreenSize( int *cols, int *rows )
23 {
25 }