Browse Source

Adjust intrinsic size of text input elements

Michael Ragazzon 1 year ago
parent
commit
0e55f00920
1 changed files with 1 additions and 1 deletions
  1. 1 1
      Source/Core/Elements/InputTypeText.cpp

+ 1 - 1
Source/Core/Elements/InputTypeText.cpp

@@ -112,7 +112,7 @@ void InputTypeText::ProcessDefaultAction(Event& /*event*/) {}
 bool InputTypeText::GetIntrinsicDimensions(Vector2f& dimensions, float& /*ratio*/)
 {
 	dimensions.x = (float)(size * ElementUtilities::GetStringWidth(element, "m"));
-	dimensions.y = element->GetLineHeight() + 2.0f;
+	dimensions.y = Math::Round(element->GetLineHeight());
 
 	return true;
 }