Properly test whether maximum_width_ is set.

Fixes bug #14565.
This commit is contained in:
Mark de Wever 2009-10-21 17:52:41 +00:00
parent 572c2eba61
commit 5a1a8ccf40

View File

@ -472,7 +472,7 @@ void ttext::recalculate(const bool force) const
<< " result " << rect_
<< ".\n";
if(rect_.width > maximum_width_) {
if(maximum_width_ != -1 && rect_.width > maximum_width_) {
ERR_GUI_L << "ttext::" << __func__
<< " text '" << gui2::debug_truncate(text_)
<< " ' width " << rect_.width