Skip to content
Snippets Groups Projects
Commit ec2b00c2 authored by Cinder's avatar Cinder
Browse files

Don't hardcode black as the default color for syntax

parent f697eb37
No related branches found
No related tags found
No related merge requests found
...@@ -172,7 +172,7 @@ std::string LLKeywords::getAttribute(const std::string& key) ...@@ -172,7 +172,7 @@ std::string LLKeywords::getAttribute(const std::string& key)
LLColor4 LLKeywords::getColorGroup(const std::string& key_in) LLColor4 LLKeywords::getColorGroup(const std::string& key_in)
{ {
std::string color_group = "Black"; std::string color_group = "ScriptText";
if (key_in == "constants-float") if (key_in == "constants-float")
{ {
color_group = "SyntaxLslConstantFloat"; color_group = "SyntaxLslConstantFloat";
...@@ -239,7 +239,7 @@ LLColor4 LLKeywords::getColorGroup(const std::string& key_in) ...@@ -239,7 +239,7 @@ LLColor4 LLKeywords::getColorGroup(const std::string& key_in)
} }
else else
{ {
LL_WARNS("SyntaxLSL") << "Color key '" << key_in << "' not recognized!" << LL_ENDL; LL_WARNS("SyntaxLSL") << "Color key '" << key_in << "' not recognized." << LL_ENDL;
} }
return LLUIColorTable::instance().getColor(color_group); return LLUIColorTable::instance().getColor(color_group);
......
...@@ -54,7 +54,6 @@ BOOL LLFloaterScriptEdPrefs::postBuild() ...@@ -54,7 +54,6 @@ BOOL LLFloaterScriptEdPrefs::postBuild()
void LLFloaterScriptEdPrefs::applyUIColor(LLUICtrl* ctrl, const LLSD& param) void LLFloaterScriptEdPrefs::applyUIColor(LLUICtrl* ctrl, const LLSD& param)
{ {
LLUIColorTable::instance().setColor(param.asString(), LLColor4(ctrl->getValue())); LLUIColorTable::instance().setColor(param.asString(), LLColor4(ctrl->getValue()));
// *TODO: Signal all active script editors to change colors on the fly.
mEditor->initKeywords(); mEditor->initKeywords();
mEditor->loadKeywords(); mEditor->loadKeywords();
} }
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment