Transfer everything from old FS script editor prefs to new script editor preferences from V3 and remove old FS script editor prefs

Ansariel 2015-01-12 15:44:59 +01:00
parent 524662e386
commit eb19075c39
12 changed files with 568 additions and 993 deletions

View File

@ -160,7 +160,6 @@ set(viewer_SOURCE_FILES
fsfloaterposestand.cpp
fsfloaterprofile.cpp
fsfloaterradar.cpp
fsfloaterscripteditorprefs.cpp
fsfloatersearch.cpp
fsfloaterteleporthistory.cpp
fsfloatervoicecontrols.cpp
@ -881,7 +880,6 @@ set(viewer_HEADER_FILES
fsfloaterposestand.h
fsfloaterprofile.h
fsfloaterradar.h
fsfloaterscripteditorprefs.h
fsfloatersearch.h
fsfloaterteleporthistory.h
fsfloatervoicecontrols.h

View File

@ -1,84 +0,0 @@
/*
* @file fsfloaterscripteditorprefs.h
* @brief Script editor preferences
*
* $LicenseInfo:firstyear=2012&license=fsviewerlgpl$
* Phoenix Firestorm Viewer Source Code
* Copyright (C) 2012, Cinder Roxley <cinder.roxley@phoenixviewer.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation;
* version 2.1 of the License only.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
* The Phoenix Firestorm Project, Inc., 1831 Oakwood Drive, Fairmont, Minnesota 56031-3225 USA
* http://www.firestormviewer.org
* $/LicenseInfo$
*/
#include "llviewerprecompiledheaders.h"
#include "fsfloaterscripteditorprefs.h"
#include "llbutton.h"
#include "llcolorswatch.h"
#include "lldirpicker.h"
#include "llviewercontrol.h"
FSFloaterScriptEdPrefs::FSFloaterScriptEdPrefs(const LLSD& key)
: LLFloater(key)
{
mCommitCallbackRegistrar.add("ScriptPref.applyUIColor", boost::bind(&FSFloaterScriptEdPrefs::applyUIColor, this ,_1, _2));
mCommitCallbackRegistrar.add("ScriptPref.getUIColor", boost::bind(&FSFloaterScriptEdPrefs::getUIColor, this ,_1, _2));
mCommitCallbackRegistrar.add("NACL.SetPreprocInclude", boost::bind(&FSFloaterScriptEdPrefs::setPreprocInclude, this));
}
FSFloaterScriptEdPrefs::~FSFloaterScriptEdPrefs()
{
}
BOOL FSFloaterScriptEdPrefs::postBuild()
{
getChild<LLButton>("close_btn")->setClickedCallback(boost::bind(&FSFloaterScriptEdPrefs::closeFloater, this, false));
return TRUE;
}
void FSFloaterScriptEdPrefs::applyUIColor(LLUICtrl* ctrl, const LLSD& param)
{
LLUIColorTable::instance().setColor(param.asString(), LLColor4(ctrl->getValue()));
}
void FSFloaterScriptEdPrefs::getUIColor(LLUICtrl* ctrl, const LLSD& param)
{
LLColorSwatchCtrl* color_swatch = (LLColorSwatchCtrl*) ctrl;
color_swatch->setOriginal(LLUIColorTable::instance().getColor(param.asString()));
}
void FSFloaterScriptEdPrefs::setPreprocInclude()
{
std::string cur_name(gSavedSettings.getString("_NACL_PreProcHDDIncludeLocation"));
std::string proposed_name(cur_name);
LLDirPicker& picker = LLDirPicker::instance();
if (!picker.getDir(&proposed_name ))
{
return; //Canceled!
}
std::string dir_name = picker.getDirName();
if (!dir_name.empty() && dir_name != cur_name)
{
std::string new_top_folder(gDirUtilp->getBaseFileName(dir_name));
gSavedSettings.setString("_NACL_PreProcHDDIncludeLocation", dir_name);
}
}

View File

@ -1,46 +0,0 @@
/*
* @file fsfloaterscripteditorprefs.h
* @brief Script editor preferences
*
* $LicenseInfo:firstyear=2012&license=fsviewerlgpl$
* Phoenix Firestorm Viewer Source Code
* Copyright (C) 2012, Cinder Roxley <cinder.roxley@phoenixviewer.com>
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation;
* version 2.1 of the License only.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
*
* The Phoenix Firestorm Project, Inc., 1831 Oakwood Drive, Fairmont, Minnesota 56031-3225 USA
* http://www.firestormviewer.org
* $/LicenseInfo$
*/
#ifndef FS_FLOATERSCRIPTEDITORPREFS_H
#define FS_FLOATERSCRIPTEDITORPREFS_H
#include "llfloater.h"
class FSFloaterScriptEdPrefs : public LLFloater
{
public:
FSFloaterScriptEdPrefs(const LLSD& key);
BOOL postBuild();
private:
~FSFloaterScriptEdPrefs();
void applyUIColor(LLUICtrl* ctrl, const LLSD& param);
void getUIColor(LLUICtrl* ctrl, const LLSD& param);
void setPreprocInclude();
};
#endif // FS_FLOATERSCRIPTEDITORPREFS_H

View File

@ -30,6 +30,8 @@
#include "llcolorswatch.h"
#include "llscripteditor.h"
#include "lldirpicker.h"
#include "llviewercontrol.h"
LLFloaterScriptEdPrefs::LLFloaterScriptEdPrefs(const LLSD& key)
@ -38,6 +40,8 @@ LLFloaterScriptEdPrefs::LLFloaterScriptEdPrefs(const LLSD& key)
{
mCommitCallbackRegistrar.add("ScriptPref.applyUIColor", boost::bind(&LLFloaterScriptEdPrefs::applyUIColor, this ,_1, _2));
mCommitCallbackRegistrar.add("ScriptPref.getUIColor", boost::bind(&LLFloaterScriptEdPrefs::getUIColor, this ,_1, _2));
// <FS:Ansariel> Port old FS script prefs
mCommitCallbackRegistrar.add("NACL.SetPreprocInclude", boost::bind(&LLFloaterScriptEdPrefs::setPreprocInclude, this));
}
BOOL LLFloaterScriptEdPrefs::postBuild()
@ -48,6 +52,10 @@ BOOL LLFloaterScriptEdPrefs::postBuild()
mEditor->initKeywords();
mEditor->loadKeywords();
}
// <FS:Ansariel> Port old FS script prefs
getChild<LLButton>("close_btn")->setClickedCallback(boost::bind(&LLFloaterScriptEdPrefs::closeFloater, this, false));
return TRUE;
}
@ -63,3 +71,25 @@ void LLFloaterScriptEdPrefs::getUIColor(LLUICtrl* ctrl, const LLSD& param)
LLColorSwatchCtrl* color_swatch = dynamic_cast<LLColorSwatchCtrl*>(ctrl);
color_swatch->setOriginal(LLUIColorTable::instance().getColor(param.asString()));
}
// <FS:Ansariel> Port old FS script prefs
void LLFloaterScriptEdPrefs::setPreprocInclude()
{
std::string cur_name(gSavedSettings.getString("_NACL_PreProcHDDIncludeLocation"));
std::string proposed_name(cur_name);
LLDirPicker& picker = LLDirPicker::instance();
if (!picker.getDir(&proposed_name ))
{
return; //Canceled!
}
std::string dir_name = picker.getDirName();
if (!dir_name.empty() && dir_name != cur_name)
{
std::string new_top_folder(gDirUtilp->getBaseFileName(dir_name));
gSavedSettings.setString("_NACL_PreProcHDDIncludeLocation", dir_name);
}
}
// </FS:Ansariel>

View File

@ -45,6 +45,9 @@ private:
void applyUIColor(LLUICtrl* ctrl, const LLSD& param);
void getUIColor(LLUICtrl* ctrl, const LLSD& param);
// <FS:Ansariel> Port old FS script prefs
void setPreprocInclude();
LLScriptEditor* mEditor;
};

View File

@ -722,7 +722,7 @@ void LLScriptEdCore::updateButtonBar()
//static
void LLScriptEdCore::onBtnPrefs(void* userdata)
{
LLFloaterReg::showInstance("fs_script_editor_prefs");
LLFloaterReg::showInstance("script_colors");
}
// </FS:CR>

View File

@ -175,7 +175,6 @@
#include "fsfloaterposestand.h"
#include "fsfloaterprofile.h"
#include "fsfloaterradar.h"
#include "fsfloaterscripteditorprefs.h"
#include "fsfloatersearch.h"
#include "fsfloaterteleporthistory.h"
#include "fsfloatervoicecontrols.h"
@ -421,7 +420,6 @@ void LLViewerFloaterReg::registerFloaters()
LLFloaterReg::add("fs_posestand", "floater_fs_posestand.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<FSFloaterPoseStand>);
LLFloaterReg::add("fs_placedetails", "floater_fs_placedetails.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<FSFloaterPlaceDetails>);
LLFloaterReg::add("fs_radar", "floater_fs_radar.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<FSFloaterRadar>);
LLFloaterReg::add("fs_script_editor_prefs", "floater_fs_script_editor_prefs.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<FSFloaterScriptEdPrefs>);
LLFloaterReg::add("fs_teleporthistory", "floater_fs_teleporthistory.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<FSFloaterTeleportHistory>);
LLFloaterReg::add("fs_voice_controls", "floater_fs_voice_controls.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<FSFloaterVoiceControls>);
LLFloaterReg::add("fs_volume_controls", "floater_fs_volume_controls.xml", (LLFloaterBuildFunc)&LLFloaterReg::build<FSFloaterVolumeControls>);

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<floater name="floater_fs_script_editor_prefs" title="Einstellungen Skript-Editor">
<floater name="floater_script_colors" title="Einstellungen Skript-Editor">
<text name="color_pickers_label">
Gewünschte Farben auswählen:
</text>

View File

@ -1,585 +0,0 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<floater
legacy_header_height="18"
height="455"
layout="topleft"
name="floater_fs_script_editor_prefs"
help_topic="lsl_editor_preferences"
title="Script Editor Preferences"
save_rect="true"
single_instance="true"
can_resize="false"
width="325">
<text
follows="left|top"
height="15"
layout="topleft"
left="12"
name="color_pickers_label"
top="30"
width="200">
Choose desired colors:
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="text"
top="45"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="ScriptText" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="ScriptText" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="text_label"
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"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="background"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="ScriptBackground" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="ScriptBackground" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="background_label"
top_delta="5"
width="100">
Background
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="section"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslSection" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslSection" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="section_label"
top_delta="5"
width="100">
Sections
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="datatype"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslDataType" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslDataType" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="datatype_label"
top_delta="5"
width="100">
Data Types
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="event"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslEvent" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslEvent" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="event_label"
top_delta="5"
width="100">
Events
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="comment"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslComment" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslComment" />
</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="15"
name="function"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslFunction" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslFunction" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="function_label"
top_delta="5"
width="100">
Function
</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="SyntaxLslStringLiteral" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslStringLiteral" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="string_literal_label"
top_delta="5"
width="100">
String Literals
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="170"
name="i_constant"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslIntegerConstant" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslIntegerConstant" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="i_constant_label"
top_delta="5"
width="100">
Integer Const
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="170"
name="s_constant"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslStringConstant" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslStringConstant" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="s_constant_label"
top_delta="5"
width="100">
String Const
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="170"
name="f_constant"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslFloatConstant" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslFloatConstant" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="f_constant_label"
top_delta="5"
width="100">
Float Const
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="170"
name="c_constant"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslCompoundConstant" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslCompoundConstant" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="c_constant_label"
top_delta="5"
width="100">
Compound
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="170"
name="flow_control"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslControlFlow" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslControlFlow" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="flow_control_label"
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="preprocessor"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslPreprocessor" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslPreprocessor" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="preprocessor_label"
top_delta="5"
width="100">
Preprocessor
</text>
<text
follows="left|top"
height="15"
layout="topleft"
left="12"
name="prefs_label"
top="255"
width="150">
Script Editor Options:
</text>
<check_box
control_name="ExternalEditorConvertTabsToSpaces"
follows="left|top"
layout="topleft"
left_delta="5"
height="12"
name="convert_tabs_to_spaces_checkbox"
top_pad="6"
width="200"
label="Convert tabs to spaces" />
<check_box
control_name="_NACL_LSLPreprocessor"
follows="left|top"
height="16"
top_pad="2"
label="Enable LSL preprocessor"
tool_tip="When checked, the LSL preprocessor is enabled."
name="preproc_checkbox" />
<check_box
control_name="_NACL_PreProcLSLOptimizer"
enabled_control="_NACL_LSLPreprocessor"
follows="left|top"
height="16"
top_pad="2"
left_delta="16"
label="Script optimizer"
tool_tip="When checked, the LSL preprocessor will optimize space used by scripts at the cost of readability."
name="preprocoptimizer_checkbox" />
<check_box
control_name="_NACL_PreProcLSLSwitch"
enabled_control="_NACL_LSLPreprocessor"
follows="left|top"
height="16"
top_pad="2"
label="switch() statement"
tool_tip="When checked, the LSL preprocessor will allow the use of the switch() statement for script flow control."
name="preprocswitch_checkbox" />
<check_box
control_name="_NACL_PreProcLSLLazyLists"
enabled_control="_NACL_LSLPreprocessor"
follows="left|top"
height="16"
top_pad="2"
label="Lazy lists"
tool_tip="When checked, the LSL preprocessor will allow the use of syntax extensions for list handling."
name="preproclazy_checkbox" />
<check_box
control_name="_NACL_PreProcEnableHDDInclude"
enabled_control="_NACL_LSLPreprocessor"
follows="left|top"
top_pad="2"
height="16"
label="#includes from local disk"
tool_tip="When checked, the LSL preprocessor will allow #include statements to reference files on your local disk."
name="preprocinclude_checkbox" />
<text
follows="left|top"
height="16"
type="string"
length="1"
layout="topleft"
name="lslpreprocinclude_textbox"
top_pad="2"
width="256">
Preprocessor include path:
</text>
<line_editor
control_name="_NACL_PreProcHDDIncludeLocation"
border_style="line"
border_thickness="1"
follows="left|top"
height="23"
enabled_control="_NACL_PreProcEnableHDDInclude"
max_length_chars="4096"
name="preprocinclude_location"
top_pad="0"
width="235" />
<button
follows="left|top"
height="23"
enabled_control="_NACL_PreProcEnableHDDInclude"
label="..."
label_selected="Browse"
left_pad="5"
name="SetPreprocInclude"
top_delta="0"
width="30">
<button.commit_callback
function="NACL.SetPreprocInclude" />
</button>
<button
follows="top|left"
height="23"
layout="topleft"
top_pad="6"
left="115"
name="close_btn"
width="100"
label="OK" />
</floater>

View File

@ -2,330 +2,481 @@
<floater
legacy_header_height="18"
can_resize="false"
height="354"
height="630"
layout="topleft"
name="floater_script_colors"
help_topic="script_colors"
help_topic="lsl_editor_preferences"
save_rect="true"
title="SCRIPT COLORS"
title="Script Editor Preferences"
width="320">
<text
follows="left|top"
height="15"
layout="topleft"
left="12"
name="color_pickers_label"
top="30"
width="200">
Choose desired colors:
<text
follows="left|top"
height="15"
layout="topleft"
left="12"
name="color_pickers_label"
top="30"
width="200">
Choose desired colors:
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="text"
top="45"
width="44" >
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="text"
top="45"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="ScriptText" />
function="ScriptPref.getUIColor"
parameter="ScriptText" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="ScriptText" />
function="ScriptPref.applyUIColor"
parameter="ScriptText" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="text_label"
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
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="text_label"
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="background"
top_pad="10"
width="44" >
<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="ScriptBackground" />
function="ScriptPref.getUIColor"
parameter="ScriptCursorColor" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="ScriptBackground" />
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="background_label"
top_delta="5"
width="100">
Background
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"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="datatype"
top_pad="10"
width="44" >
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="background"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslDataType" />
function="ScriptPref.getUIColor"
parameter="ScriptBackground" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslDataType" />
function="ScriptPref.applyUIColor"
parameter="ScriptBackground" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="datatype_label"
top_delta="5"
width="100">
Data Types
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="background_label"
top_delta="5"
width="100">
Background
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="event"
top_pad="10"
width="44" >
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="section"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslEvent" />
function="ScriptPref.getUIColor"
parameter="SyntaxLslSection" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslEvent" />
function="ScriptPref.applyUIColor"
parameter="SyntaxLslSection" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="event_label"
top_delta="5"
width="100">
Events
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="section_label"
top_delta="5"
width="100">
Sections
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="190"
name="string_literal"
top="45"
width="44" >
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="datatype"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslStringLiteral" />
function="ScriptPref.getUIColor"
parameter="SyntaxLslDataType" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslStringLiteral" />
function="ScriptPref.applyUIColor"
parameter="SyntaxLslDataType" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="string_literal_label"
top_delta="5"
width="100">
String Literals
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="datatype_label"
top_delta="5"
width="100">
Data Types
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="190"
name="constant"
top_pad="10"
width="44" >
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="event"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslConstant" />
function="ScriptPref.getUIColor"
parameter="SyntaxLslEvent" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslConstant" />
function="ScriptPref.applyUIColor"
parameter="SyntaxLslEvent" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="constant_label"
top_delta="5"
width="100">
Constant
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="event_label"
top_delta="5"
width="100">
Events
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="190"
name="flow_control"
top_pad="10"
width="44" >
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="comment"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslControlFlow" />
function="ScriptPref.getUIColor"
parameter="SyntaxLslComment" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslControlFlow" />
function="ScriptPref.applyUIColor"
parameter="SyntaxLslComment" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="flow_control_label"
top_delta="5"
width="100">
Flow Control
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="190"
name="function"
top_pad="10"
width="44" >
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="15"
name="function"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslFunction" />
function="ScriptPref.getUIColor"
parameter="SyntaxLslFunction" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslFunction" />
function="ScriptPref.applyUIColor"
parameter="SyntaxLslFunction" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="function_label"
top_delta="5"
width="100">
Function
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="function_label"
top_delta="5"
width="100">
Function
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="190"
name="comment"
top_pad="10"
width="44" >
<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="SyntaxLslComment" />
function="ScriptPref.getUIColor"
parameter="SyntaxLslStringLiteral" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslComment" />
function="ScriptPref.applyUIColor"
parameter="SyntaxLslStringLiteral" />
</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
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="string_literal_label"
top_delta="5"
width="100">
String Literals
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="170"
name="i_constant"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslIntegerConstant" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslIntegerConstant" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="i_constant_label"
top_delta="5"
width="100">
Integer Const
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="170"
name="s_constant"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslStringConstant" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslStringConstant" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="s_constant_label"
top_delta="5"
width="100">
String Const
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="170"
name="f_constant"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslFloatConstant" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslFloatConstant" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="f_constant_label"
top_delta="5"
width="100">
Float Const
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="170"
name="c_constant"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslCompoundConstant" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslCompoundConstant" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="c_constant_label"
top_delta="5"
width="100">
Compound
</text>
<color_swatch
can_apply_immediately="true"
follows="left|top"
height="24"
label_height="0"
layout="topleft"
left="170"
name="flow_control"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslControlFlow" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslControlFlow" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="flow_control_label"
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="preprocessor"
top_pad="10"
width="44" >
<color_swatch.init_callback
function="ScriptPref.getUIColor"
parameter="SyntaxLslPreprocessor" />
<color_swatch.commit_callback
function="ScriptPref.applyUIColor"
parameter="SyntaxLslPreprocessor" />
</color_swatch>
<text
type="string"
length="1"
follows="left|top"
height="10"
layout="topleft"
left_pad="5"
mouse_opaque="false"
name="preprocessor_label"
top_delta="5"
width="100">
Preprocessor
</text>
<script_editor
left="8"
right="-8"
top="176"
bottom="-8"
top="250"
bottom="-208"
type="string"
length="1"
follows="left|top|right|bottom"
@ -356,4 +507,114 @@ default
}
}
</script_editor>
<text
follows="left|top"
height="15"
layout="topleft"
left="12"
name="prefs_label"
top="430"
width="150">
Script Editor Options:
</text>
<check_box
control_name="ExternalEditorConvertTabsToSpaces"
follows="left|top"
layout="topleft"
left_delta="5"
height="12"
name="convert_tabs_to_spaces_checkbox"
top_pad="6"
width="200"
label="Convert tabs to spaces" />
<check_box
control_name="_NACL_LSLPreprocessor"
follows="left|top"
height="16"
top_pad="2"
label="Enable LSL preprocessor"
tool_tip="When checked, the LSL preprocessor is enabled."
name="preproc_checkbox" />
<check_box
control_name="_NACL_PreProcLSLOptimizer"
enabled_control="_NACL_LSLPreprocessor"
follows="left|top"
height="16"
top_pad="2"
left_delta="16"
label="Script optimizer"
tool_tip="When checked, the LSL preprocessor will optimize space used by scripts at the cost of readability."
name="preprocoptimizer_checkbox" />
<check_box
control_name="_NACL_PreProcLSLSwitch"
enabled_control="_NACL_LSLPreprocessor"
follows="left|top"
height="16"
top_pad="2"
label="switch() statement"
tool_tip="When checked, the LSL preprocessor will allow the use of the switch() statement for script flow control."
name="preprocswitch_checkbox" />
<check_box
control_name="_NACL_PreProcLSLLazyLists"
enabled_control="_NACL_LSLPreprocessor"
follows="left|top"
height="16"
top_pad="2"
label="Lazy lists"
tool_tip="When checked, the LSL preprocessor will allow the use of syntax extensions for list handling."
name="preproclazy_checkbox" />
<check_box
control_name="_NACL_PreProcEnableHDDInclude"
enabled_control="_NACL_LSLPreprocessor"
follows="left|top"
top_pad="2"
height="16"
label="#includes from local disk"
tool_tip="When checked, the LSL preprocessor will allow #include statements to reference files on your local disk."
name="preprocinclude_checkbox" />
<text
follows="left|top"
height="16"
type="string"
length="1"
layout="topleft"
name="lslpreprocinclude_textbox"
top_pad="2"
width="256">
Preprocessor include path:
</text>
<line_editor
control_name="_NACL_PreProcHDDIncludeLocation"
border_style="line"
border_thickness="1"
follows="left|top"
height="23"
enabled_control="_NACL_PreProcEnableHDDInclude"
max_length_chars="4096"
name="preprocinclude_location"
top_pad="0"
width="235" />
<button
follows="left|top"
height="23"
enabled_control="_NACL_PreProcEnableHDDInclude"
label="..."
label_selected="Browse"
left_pad="5"
name="SetPreprocInclude"
top_delta="0"
width="30">
<button.commit_callback
function="NACL.SetPreprocInclude" />
</button>
<button
follows="top|left"
height="23"
layout="topleft"
top_pad="6"
left="115"
name="close_btn"
width="100"
label="OK" />
</floater>

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<floater name="floater_fs_script_editor_prefs" title="Preferencias del editor de scripts">
<floater name="floater_script_colors" title="Preferencias del editor de scripts">
<text name="color_pickers_label">
Elige los colores deseados:
</text>

View File

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8" standalone="yes" ?>
<floater name="floater_fs_script_editor_prefs" title="Ustawienia edytora skryptów">
<floater name="floater_script_colors" title="Ustawienia edytora skryptów">
<text name="color_pickers_label">
Wybierz żądane kolory:
</text>