From 97abe323c460c678aa1fe6e20a5749cfd66ed2ee Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Thu, 26 Dec 2019 17:47:58 +0100 Subject: GRAPHICS: MACGUI: Sanity check for empty lines --- graphics/macgui/mactext.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'graphics') diff --git a/graphics/macgui/mactext.cpp b/graphics/macgui/mactext.cpp index 5963d1ed67..14eb411a23 100644 --- a/graphics/macgui/mactext.cpp +++ b/graphics/macgui/mactext.cpp @@ -392,7 +392,7 @@ int MacText::getLineWidth(int line, bool enforce) { } if (!hastext) - height -= 3; + height = height > 3 ? height - 3 : 0; _textLines[line].width = width; _textLines[line].height = height; -- cgit v1.2.3