summaryrefslogtreecommitdiff
path: root/indra/llui
diff options
context:
space:
mode:
Diffstat (limited to 'indra/llui')
-rw-r--r--indra/llui/llkeywords.cpp4
-rw-r--r--indra/llui/llmenugl.cpp4
-rw-r--r--indra/llui/llmenugl.h7
3 files changed, 11 insertions, 4 deletions
diff --git a/indra/llui/llkeywords.cpp b/indra/llui/llkeywords.cpp
index 56e0c4f0f8..341ddb83f3 100644
--- a/indra/llui/llkeywords.cpp
+++ b/indra/llui/llkeywords.cpp
@@ -501,7 +501,7 @@ void LLKeywords::findSegments(std::vector<LLTextSegmentPtr>* seg_list, const LLW
{
if( *cur == '\n' )
{
- LLTextSegmentPtr text_segment = new LLLineBreakTextSegment(cur-base);
+ LLTextSegmentPtr text_segment = new LLLineBreakTextSegment(style, cur-base);
text_segment->setToken( 0 );
insertSegment( *seg_list, text_segment, text_len, style, editor);
cur++;
@@ -712,7 +712,7 @@ void LLKeywords::insertSegments(const LLWString& wtext, std::vector<LLTextSegmen
insertSegment( seg_list, text_segment, text_len, style, editor);
}
- LLTextSegmentPtr text_segment = new LLLineBreakTextSegment(pos);
+ LLTextSegmentPtr text_segment = new LLLineBreakTextSegment(style, pos);
text_segment->setToken( cur_token );
insertSegment( seg_list, text_segment, text_len, style, editor);
diff --git a/indra/llui/llmenugl.cpp b/indra/llui/llmenugl.cpp
index 33c4b6ec73..99dbdcf775 100644
--- a/indra/llui/llmenugl.cpp
+++ b/indra/llui/llmenugl.cpp
@@ -1777,7 +1777,8 @@ LLMenuGL::LLMenuGL(const LLMenuGL::Params& p)
mNeedsArrange(FALSE),
mAlwaysShowMenu(FALSE),
mResetScrollPositionOnShow(true),
- mShortcutPad(p.shortcut_pad)
+ mShortcutPad(p.shortcut_pad),
+ mFont(p.font)
{
typedef boost::tokenizer<boost::char_separator<char> > tokenizer;
boost::char_separator<char> sep("_");
@@ -3636,6 +3637,7 @@ BOOL LLMenuBarGL::appendMenu( LLMenuGL* menu )
p.disabled_color=LLUIColorTable::instance().getColor("MenuItemDisabledColor");
p.highlight_bg_color=LLUIColorTable::instance().getColor("MenuItemHighlightBgColor");
p.highlight_fg_color=LLUIColorTable::instance().getColor("MenuItemHighlightFgColor");
+ p.font = menu->getFont();
LLMenuItemBranchDownGL* branch = LLUICtrlFactory::create<LLMenuItemBranchDownGL>(p);
success &= branch->addToAcceleratorList(&mAccelerators);
diff --git a/indra/llui/llmenugl.h b/indra/llui/llmenugl.h
index 9d3be8d94f..8194501f79 100644
--- a/indra/llui/llmenugl.h
+++ b/indra/llui/llmenugl.h
@@ -555,7 +555,9 @@ public:
// add a context menu branch
BOOL appendContextSubMenu(LLMenuGL *menu);
-protected:
+ const LLFontGL *getFont() const { return mFont; }
+
+ protected:
void createSpilloverBranch();
void cleanupSpilloverBranch();
// Add the menu item to this menu.
@@ -587,6 +589,9 @@ protected:
BOOL mKeepFixedSize;
BOOL mNeedsArrange;
+ // Font for top menu items only
+ const LLFontGL* mFont;
+
private: