summaryrefslogtreecommitdiff
path: root/indra/llui/lltextbase.cpp
diff options
context:
space:
mode:
authorVadim Savchuk <vsavchuk@productengine.com>2009-11-19 16:14:19 +0200
committerVadim Savchuk <vsavchuk@productengine.com>2009-11-19 16:14:19 +0200
commit5725b04b084f5ad2699e834421b12795af351975 (patch)
tree61c78a2a715717c172cc94f9fdd8bd80161991d7 /indra/llui/lltextbase.cpp
parent88cce61b09d225df0bcd8aab9dbd2c5a01ee7e19 (diff)
parent884a9887a7a9e833478d266ddf8a7808cdba2ae6 (diff)
Merge from default branch
--HG-- branch : product-engine
Diffstat (limited to 'indra/llui/lltextbase.cpp')
-rw-r--r--indra/llui/lltextbase.cpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/indra/llui/lltextbase.cpp b/indra/llui/lltextbase.cpp
index caaf47240f..cd795282f9 100644
--- a/indra/llui/lltextbase.cpp
+++ b/indra/llui/lltextbase.cpp
@@ -2380,6 +2380,14 @@ bool LLNormalTextSegment::getDimensions(S32 first_char, S32 num_chars, S32& widt
width = mStyle->getFont()->getWidth(text.c_str(), mStart + first_char, num_chars);
// if last character is a newline, then return true, forcing line break
llwchar last_char = text[mStart + first_char + num_chars - 1];
+
+ LLUIImagePtr image = mStyle->getImage();
+ if( image.notNull())
+ {
+ width += image->getWidth();
+ height = llmax(height, image->getHeight());
+ }
+
return num_chars >= 1 && last_char == '\n';
}