Use actualy screen size instead of frame size for font scaling

This commit is contained in:
Benau 2018-11-17 13:50:50 +08:00
parent e6dadeb980
commit 9c3bae5a87

View File

@ -350,9 +350,9 @@ void FontWithFace::dumpGlyphPage()
*/
void FontWithFace::setDPI()
{
const int screen_width = irr_driver->getFrameSize().Width;
const int screen_height = irr_driver->getFrameSize().Height;
const int screen_width = irr_driver->getActualScreenSize().Width;
const int screen_height = irr_driver->getActualScreenSize().Height;
if (UserConfigParams::m_hidpi_enabled)
{
float scale = screen_height / 480.0f;