Call the correct DPI getter

See also https://github.com/FlaxEngine/FlaxEngine/pull/267
This commit is contained in:
stefnotch
2021-03-15 15:40:32 +01:00
parent afea02d92f
commit 85ab871d48
2 changed files with 8 additions and 8 deletions
+2 -2
View File
@@ -107,7 +107,7 @@ namespace FlaxEngine.GUI
return Vector2.Zero;
}
height = font.Height / Platform.DpiScale;
height = font.Height / RootWindow.DpiScale;
return font.GetCharPosition(_text, index, ref _layout);
}
@@ -159,7 +159,7 @@ namespace FlaxEngine.GUI
{
Vector2 leftEdge = font.GetCharPosition(_text, SelectionLeft, ref _layout);
Vector2 rightEdge = font.GetCharPosition(_text, SelectionRight, ref _layout);
float fontHeight = font.Height / Platform.DpiScale;
float fontHeight = font.Height / RootWindow.DpiScale;
// Draw selection background
float alpha = Mathf.Min(1.0f, Mathf.Cos(_animateTime * BackgroundSelectedFlashSpeed) * 0.5f + 1.3f);