Open the start menu on the taskbar (the 4 blue squares)
settings
system
For developers
In the terminal drop down list choose Windows Console Host.
Tester code:
Code: Select all
#include "windows.bi"
Shell "color f0"
Sub changefontsize(w As Long, h As Long,ftype As String="consolas")
Dim As _CONSOLE_FONT_INFOEX x
With x
.cbsize=Sizeof(_CONSOLE_FONT_INFOEX)
.nfont=0
.dwfontsize=Type(w,h)
.fontfamily=0
.fontweight=100
.facename=ftype
End With
setcurrentconsolefontex(GetStdHandle(STD_OUTPUT_HANDLE),1, @x )
End Sub
Sub changeconsolesize(cols As Long,lines As Long)
Shell "MODE CON: COLS="+Str(cols)+ "LINES="+Str(lines)
End Sub
Sub getfontsize(x as _CONSOLE_FONT_INFOEX)
x.cbsize=Sizeof(_CONSOLE_FONT_INFOEX)
getcurrentconsolefontex(GetStdHandle(STD_OUTPUT_HANDLE),false, @x )
End Sub
dim as _CONSOLE_FONT_INFOEX f
getfontsize(f)
print "Initial font size = ";f.dwFontSize.x;" by";f.dwFontSize.y
'====================
Print "Press a key"
Sleep
changefontsize(13,28)
Print "new font size this session = 13 by 28"
Dim As String asci
For n As Long=0 To 255
asci+=Chr(n) 'create a string
Next
Locate 10
Print asci
Print "Now change the console size again, press a key"
Sleep
Cls
changefontsize(15,30)
changeconsolesize(50,4)
Print "New console size = COLS=50 LINES=4"
Print "Font size 15 by 30"
Print "Press a key to end . . . "
Sleep