aboutsummaryrefslogtreecommitdiff
path: root/graphics/macgui/mactext.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'graphics/macgui/mactext.cpp')
-rw-r--r--graphics/macgui/mactext.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/graphics/macgui/mactext.cpp b/graphics/macgui/mactext.cpp
index 9a5de39dd2..1c80e55358 100644
--- a/graphics/macgui/mactext.cpp
+++ b/graphics/macgui/mactext.cpp
@@ -295,6 +295,9 @@ void MacText::render() {
}
void MacText::render(int from, int to) {
+ if (_textLines.empty())
+ return;
+
reallocSurface();
from = MAX<int>(0, from);
@@ -373,6 +376,9 @@ void MacText::setInterLinear(int interLinear) {
}
void MacText::recalcDims() {
+ if (_textLines.empty())
+ return;
+
int y = 0;
_textMaxWidth = 0;