Add custom cursor color for script editor, clean up orphaned prototype from lltexteditor.h

Cinders 2013-05-18 07:50:42 -06:00
parent e06773fcb9
commit 8f73e3da3e
10 changed files with 85 additions and 42 deletions

View File

@ -192,12 +192,7 @@ public:
const std::vector<std::string>& funcs,
const std::vector<std::string>& tooltips,
const LLColor3& func_color);
// NaCl - LSL Preprocessor
void addToken(LLKeywordToken::TOKEN_TYPE type,
const std::string& key,
const LLColor3& color,
const std::string& tool_tip = LLStringUtil::null);
// NaCl End
LLKeywords::keyword_iterator_t keywordsBegin() { return mKeywords.begin(); }
LLKeywords::keyword_iterator_t keywordsEnd() { return mKeywords.end(); }

View File

@ -1180,6 +1180,9 @@
<color
name="ScriptBackground"
reference="White" />
<color
name="ScriptCursorColor"
reference="Black" />
<color
name="SyntaxSection"
value=".5 .1 .3 1" />

View File

@ -1180,6 +1180,9 @@
<color
name="ScriptBackground"
reference="White" />
<color
name="ScriptCursorColor"
reference="Black" />
<color
name="SyntaxSection"
value=".5 .1 .3 1" />

View File

@ -1121,6 +1121,9 @@
<color
name="ScriptBackground"
reference="White" />
<color
name="ScriptCursorColor"
reference="Black" />
<color
name="SyntaxSection"
value=".5 .1 .3 1" />

View File

@ -49,6 +49,36 @@
top_delta="5"
width="100">
Text
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="cursor"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="ScriptCursorColor" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="ScriptCursorColor" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="cursor_label"
top_delta="5"
width="100">
Cursor
</text>
<color_swatch
can_apply_immediately="true"
@ -177,9 +207,39 @@
label_height="0"
layout="topleft"
left="15"
name="string_literal"
name="comment"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxComment" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxComment" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="comment_label"
top_delta="5"
width="100">
Comment
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="170"
name="string_literal"
top="45"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxStringLiteral" />
@ -209,7 +269,7 @@
layout="topleft"
left="170"
name="i_constant"
top="45"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
@ -350,36 +410,6 @@
top_delta="5"
width="100">
Flow Control
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="170"
name="comment"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxComment" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxComment" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="comment_label"
top_delta="5"
width="100">
Comment
</text>
<color_swatch
can_apply_immediately="true"

View File

@ -330,6 +330,7 @@
bg_focus_color="ScriptBackground"
text_readonly_color="ScriptText"
bg_readonly_color="ScriptBackground"
cursor_color="ScriptCursorColor"
width="487"
show_line_numbers="true"
enable_tooltip_paste="true"

View File

@ -354,6 +354,7 @@
bg_focus_color="ScriptBackground"
text_readonly_color="DkGray"
bg_readonly_color="TextBgWriteableColor"
cursor_color="ScriptCursorColor"
width="487"
show_line_numbers="true"
enable_tooltip_paste="true"
@ -389,6 +390,7 @@
bg_focus_color="ScriptBackground"
text_readonly_color="ScriptText"
bg_readonly_color="ScriptBackground"
cursor_color="ScriptCursorColor"
width="487"
show_line_numbers="true"
word_wrap="true">

View File

@ -848,6 +848,9 @@
<color
name="ScriptBackground"
reference="White" />
<color
name="ScriptCursorColor"
reference="Black" />
<color
name="SyntaxSection"
value=".5 .1 .3 1" />

View File

@ -330,8 +330,9 @@
default_color="ScriptText"
bg_writeable_color="ScriptBackground"
bg_focus_color="ScriptBackground"
text_readonly_color="DkGray"
bg_readonly_color="TextBgWriteableColor"
text_readonly_color="ScriptText"
bg_readonly_color="ScriptBackground"
cursor_color="ScriptCursorColor"
show_line_numbers="true"
enable_tooltip_paste="true"
width="487"

View File

@ -354,6 +354,7 @@
bg_focus_color="ScriptBackground"
text_readonly_color="DkGray"
bg_readonly_color="TextBgWriteableColor"
cursor_color="ScriptCursorColor"
width="487"
show_line_numbers="true"
enable_tooltip_paste="true"
@ -387,8 +388,9 @@
default_color="ScriptText"
bg_writeable_color="ScriptBackground"
bg_focus_color="ScriptBackground"
text_readonly_color="DkGray"
bg_readonly_color="TextBgWriteableColor"
text_readonly_color="ScriptText"
bg_readonly_color="ScriptBackground"
cursor_color="ScriptCursorColor"
width="487"
show_line_numbers="true"
word_wrap="true">