Which attribute is used to define the font type
void setConsoleFont(short width, short height) //width and height are size of letters
{
HANDLE hConsole = GetStdHandle(STD_OUTPUT_HANDLE);
CONSOLE_FONT_INFOEX fontInfo = {};
GetCurrentConsoleFontEx(hConsole, FALSE, &fontInfo);
fontInfo.dwFontSize = { width, height };
fontInfo.cbSize = sizeof(fontInfo);
wcscpy_s(fontInfo.FaceName, L"ISOCTEUR"); //L"ISOCTEUR" is name of style for example
SetCurrentConsoleFontEx(hConsole, FALSE, &fontInfo);
}
Comments
Leave a comment