From 9fdca96f8bd2211a99fe88e57b70cbecefa20b6d Mon Sep 17 00:00:00 2001 From: Ansariel Date: Mon, 8 Jul 2024 20:27:14 +0200 Subject: Re-enable compiler warnings C4244 and C4396 except for lltracerecording.h and llunittype.h for now --- indra/llui/llconsole.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'indra/llui/llconsole.cpp') diff --git a/indra/llui/llconsole.cpp b/indra/llui/llconsole.cpp index 9fbfb3e5fa..fe4f991921 100644 --- a/indra/llui/llconsole.cpp +++ b/indra/llui/llconsole.cpp @@ -80,7 +80,7 @@ void LLConsole::setLinePersistTime(F32 seconds) void LLConsole::reshape(S32 width, S32 height, bool called_from_parent) { S32 new_width = llmax(50, llmin(getRect().getWidth(), width)); - S32 new_height = llmax(llfloor(mFont->getLineHeight()) + 15, llmin(getRect().getHeight(), height)); + S32 new_height = llmax(mFont->getLineHeight() + 15, llmin(getRect().getHeight(), height)); if ( mConsoleWidth == new_width && mConsoleHeight == new_height ) @@ -186,7 +186,7 @@ void LLConsole::draw() LLColor4 color = LLUIColorTable::instance().getColor("ConsoleBackground"); color.mV[VALPHA] *= console_opacity; - F32 line_height = mFont->getLineHeight(); + F32 line_height = (F32)mFont->getLineHeight(); for(paragraph_it = mParagraphs.rbegin(); paragraph_it != mParagraphs.rend(); paragraph_it++) { -- cgit v1.2.3 From 604cb4cb4dd71c0f90633e50d5b0108e3901c4ad Mon Sep 17 00:00:00 2001 From: Rye Mutt Date: Fri, 26 Jul 2024 06:19:34 -0400 Subject: Reduce utf8 to wstring conversion and llwstring temporaries during text draw (#2115) --- indra/llui/llconsole.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'indra/llui/llconsole.cpp') diff --git a/indra/llui/llconsole.cpp b/indra/llui/llconsole.cpp index fe4f991921..4f52f5936d 100644 --- a/indra/llui/llconsole.cpp +++ b/indra/llui/llconsole.cpp @@ -183,7 +183,7 @@ void LLConsole::draw() static LLCachedControl console_bg_opacity(*LLUI::getInstance()->mSettingGroups["config"], "ConsoleBackgroundOpacity", 0.7f); F32 console_opacity = llclamp(console_bg_opacity(), 0.f, 1.f); - LLColor4 color = LLUIColorTable::instance().getColor("ConsoleBackground"); + static LLColor4 color = LLUIColorTable::instance().getColor("ConsoleBackground"); color.mV[VALPHA] *= console_opacity; F32 line_height = (F32)mFont->getLineHeight(); -- cgit v1.2.3 From 874794ea584588457dfde7ef17c447e2a0eb46bb Mon Sep 17 00:00:00 2001 From: Rye Mutt Date: Sun, 4 Aug 2024 21:00:10 -0400 Subject: Add LLUIColorTable debug-settings-like floater for easing skin design --- indra/llui/llconsole.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'indra/llui/llconsole.cpp') diff --git a/indra/llui/llconsole.cpp b/indra/llui/llconsole.cpp index 4f52f5936d..91e6f281da 100644 --- a/indra/llui/llconsole.cpp +++ b/indra/llui/llconsole.cpp @@ -183,7 +183,8 @@ void LLConsole::draw() static LLCachedControl console_bg_opacity(*LLUI::getInstance()->mSettingGroups["config"], "ConsoleBackgroundOpacity", 0.7f); F32 console_opacity = llclamp(console_bg_opacity(), 0.f, 1.f); - static LLColor4 color = LLUIColorTable::instance().getColor("ConsoleBackground"); + static LLUIColor console_color = LLUIColorTable::instance().getColor("ConsoleBackground"); + LLColor4 color = console_color; color.mV[VALPHA] *= console_opacity; F32 line_height = (F32)mFont->getLineHeight(); -- cgit v1.2.3