windows hack, golly i need to just rewrite this trash

This commit is contained in:
Adam D. Ruppe 2018-11-29 12:46:58 -05:00
parent 05850b77b9
commit 18a7988efc
1 changed files with 3 additions and 0 deletions

View File

@ -13498,6 +13498,9 @@ mixin template ExperimentalTextComponent() {
part.letterXs = null;
auto size = painter.textSize(part.text);
version(Windows)
if(part.text.length && part.text[$-1] == '\n')
size.height /= 2; // windows counts the new line at the end, but we don't want that
part.boundingBox = Rectangle(pos.x, pos.y, pos.x + size.width, pos.y + size.height);