summaryrefslogtreecommitdiff
path: root/indra/llui/lltextbase.h
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llui/lltextbase.h')
-rw-r--r--indra/llui/lltextbase.h12
1 files changed, 11 insertions, 1 deletions
diff --git a/indra/llui/lltextbase.h b/indra/llui/lltextbase.h
index 00cf66b134..eb4697da15 100644
--- a/indra/llui/lltextbase.h
+++ b/indra/llui/lltextbase.h
@@ -30,6 +30,7 @@
#include "v4color.h"
#include "lleditmenuhandler.h"
+#include "llfontvertexbuffer.h"
#include "llspellcheckmenuhandler.h"
#include "llstyle.h"
#include "llkeywords.h"
@@ -131,6 +132,7 @@ public:
/*virtual*/ bool getDimensionsF32(S32 first_char, S32 num_chars, F32& width, S32& height) const;
/*virtual*/ S32 getOffset(S32 segment_local_x_coord, S32 start_offset, S32 num_chars, bool round) const;
/*virtual*/ S32 getNumChars(S32 num_pixels, S32 segment_offset, S32 line_offset, S32 max_chars, S32 line_ind) const;
+ /*virtual*/ void updateLayout(const class LLTextBase& editor);
/*virtual*/ F32 draw(S32 start, S32 end, S32 selection_start, S32 selection_end, const LLRectf& draw_rect);
/*virtual*/ bool canEdit() const { return true; }
/*virtual*/ const LLUIColor& getColor() const { return mStyle->getColor(); }
@@ -149,6 +151,7 @@ public:
/*virtual*/ bool handleToolTip(S32 x, S32 y, MASK mask);
protected:
+ virtual bool useFontBuffers() const { return true; }
F32 drawClippedSegment(S32 seg_start, S32 seg_end, S32 selection_start, S32 selection_end, LLRectf rect);
virtual const LLWString& getWText() const;
@@ -161,6 +164,12 @@ protected:
LLKeywordToken* mToken;
std::string mTooltip;
boost::signals2::connection mImageLoadedConnection;
+
+ // font rendering
+ LLFontVertexBuffer mFontBufferPreSelection;
+ LLFontVertexBuffer mFontBufferSelection;
+ LLFontVertexBuffer mFontBufferPostSelection;
+ S32 mLastGeneration = -1;
};
// This text segment is the same as LLNormalTextSegment, the only difference
@@ -432,6 +441,7 @@ public:
// wide-char versions
void setWText(const LLWString& text);
const LLWString& getWText() const;
+ S32 getTextGeneration() const;
void appendText(const std::string &new_text, bool prepend_newline, const LLStyle::Params& input_params = LLStyle::Params());
@@ -475,7 +485,7 @@ public:
LLRect getDocRectFromDocIndex(S32 pos) const;
void setReadOnly(bool read_only) { mReadOnly = read_only; }
- bool getReadOnly() { return mReadOnly; }
+ bool getReadOnly() const { return mReadOnly; }
void setSkipLinkUnderline(bool skip_link_underline) { mSkipLinkUnderline = skip_link_underline; }
bool getSkipLinkUnderline() { return mSkipLinkUnderline; }