wxFont font(12, wxFONTFAMILY_DEFAULT, wxFONTSTYLE_NORMAL, wxFONTWEIGHT_LIGHT); dc->SetFont(font);
wxFont font2 = wxSystemSettings::GetFont(wxSYS_DEFAULT_GUI_FONT); dc.SetFont(font2);In this example, we get the default system GUI font using GetFont method from SystemSettings class of wx and set it as a current font for the device context dc. Package Library: wxWidgets Library.