Skip to content

Commit

Permalink
Fixed measure string not behaving correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
Kevin Scholz committed Aug 10, 2015
1 parent 7de8128 commit 4106545
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Sharpex2D/Rendering/SpriteFont.cs
Expand Up @@ -150,7 +150,7 @@ public Vector2 MeasureString(string text)
offsetWidth = 0;
}

return new Vector2(maxWidth, offsetHeight + charHeight + heightPadding);
return new Vector2(maxWidth, offsetHeight == 0 ? offsetHeight + charHeight + heightPadding : offsetHeight);
}

/// <summary>
Expand Down

0 comments on commit 4106545

Please sign in to comment.