|
SciTE Ru-Board Kernel
|
Text editor SciTE RU-Board 1.76 .56
All modifications of original SciTE editor has been developed by persons from Ru-Board community.
This document described all changes and extensions from original version of editor.
All modifications in source code marked by special tags to allow apply it to original separately.
You can examine updated editor with all of his expanded characteristics by downloading the package SciTE-Ru
List of modifications split in three parts to be more sense:
Interface
new
[ReadOnlyTabMarker] (Authors: Midas, VladVRO)
Added possibility to show Readonly status by additional symbols in tab name, which can be setup by property tabbar.readonly.marker, for example:
tabbar.readonly.marker= R/O
new
[HighlightCurrFolder] (Author: VladVRO)
Added current text fold highlighting on fold margin.
New property for setup highlight color:
fold.highlight.colour=#0099FF
if color is not set then highlighting is off.
new
[TrueTextSelMargin] (Author: VladVRO)
Changed cursor image over left margin (line number, marker and fold margins).
Cursor is set as inverse arrow when we realy can to select text otherwise used default cursor.
[SubMenu] (Author: HSolo, Updated by: Dmitry Maslov)
User's commands in menu Tools separated from other commands now by line.
And you can insert separator between any new commands in menu Tools.
For example, command.separator.34.*=1 adding separator before command 34.
Added possibility of a set check before command item of the menu.
For example: command.checked.34.*=1.
Added possibility of creation submenu in Tools menu.
All submenu items located on top of menu and separated by line from other.
For define submenu you should set up name first:
command.submenu.name.2.*=Insert from Text
If it is part of another menu then you should setup parent's menu number:
command.submenu.parent.2.*=4
And next for all subitems of this menu you should setup parent's menu number:
command.parent.6.*=2
command.name.6.*=Date and Time
All menu items text can be localized same as other menu command by file locale.properties.
[ToolsMax] (Authors: Moon_aka_Sun, VladVRO)
Extended amount of line in Tools menu till 300.
For creation of the user commands in user.context.menu it is necessary to use the formula:
User command = 9000 + number of this command in menu Tools
[ExtendedContextMenu] (Author: Dmitry Maslov)
You can setup each context menu now by using new parameters in .properties file:
user.context.menu - editor context menu
user.tabcontext.menu - tabbar context menu
user.outputcontext.menu - output context menu
And you can create submenus there by using tags POPUPBEGIN and POPUPEND!
Format:
user.context.menu=\
Command name1|IDM_COMMAND1|\
Command name2|IDM_COMMAND2|...
you can add separator by leaving both fields empty:
user.context.menu=\
Command name1|IDM_COMMAND1|\
||\
Command name2|IDM_COMMAND2|...
If parameter absent or empty then context menu will standard.
[user.toolbar] (Author: Dmitry Maslov)
You can setup toolbar now by using new parameter user.toolbar in .properties file:
Format:
user.toolbar=\
Hint1|IDM_COMMAND1|icon number1|\
Hint2|IDM_COMMAND2|icon number2|...
you can add separator by leaving fields empty:
user.toolbar=\
Hint1|IDM_COMMAND1|icon number1|\
|||\
Hint2|IDM_COMMAND2|icon number2|...
If parameter absent or empty then toolbar will standard.
[FindResultListStyle] (Authors: VladVRO, Dmitry Maslov)
Internal search (Ctrl+Shift+F) result text looks more better now:
- each line colorized by two colors: file path and line number by one color and other by second color.
- all tabs in result replaced by spaces, start spaces removed, double spaces replaced by single.
- searched string can be highlighted by setup new style parameter in properties:
style.errorlist.30=fore:#000000 ,bold
You can switch off this feature by setup new parameter in properties:
lexer.errorlist.findliststyle=0
new
[close.find.window] (Author: Dmitry Maslov)
New variable in properties files
find.replace.closefind=<number value>
Set to 0 to prevent the Find dialog from closing when "Find" pressed.
update
[TabsMoving] (Authors: VladVRO, Dmitry Maslov)
You can move tabs now. In editor added two new commands IDM_MOVETABLEFT and IDM_MOVETABRIGHT for shift current tab left or right and added identical commands in menu Buffers.
And also you can move tab by mouse now.
[TabbarTitleMaxLength] (Author: VladVRO)
New variable in properties files
tabbar.title.maxlength=<number value>
set limit of tab text length (file name). If text length greater than setup value then text will cut off and finalized with "…"
[NewBufferPosition] (Author: VladVRO)
New variable in properties files
buffers.new.position=<number value>
0 - new tab should be opened at last position in buffers list (default), 1 - next the current tab, 2 - first in list.
new
[warning.couldnotopenfile.disable] (Author: mozers)
New variable in properties files
warning.couldnotopenfile.disable=1
1 - removes warning "Could not open file", which is shown at opening a nonexistent file. The new buffer with the set name will be silently created.
[ZorderSwitchingOnClose] (Author: VladVRO)
Modification variable in properties files
buffers.zorder.switching=1
if option is present then after closing buffer current buffer will be next in buffers stack.
[new_on_dbl_clk] (Author: Dmitry Maslov)
You can open new buffer now by double click on empty space on right of tabs (a-la FireFox).
new
[close_on_dbl_clk] (Author: Dmitry Maslov, Moon_aka_Sun, VladVRO)
You can close current buffer now by double click on tabs.
[SetBookmark] (Author: Midas)
You can set bookmark by single click on Bookmark's bar now.
And you can switch off this feature by setup new parameter in .properties:
margin.bookmark.by.single.click=0
[position.autosave] (Author: Dmitry Maslov)
New variable in properties files
save.settings.path= set to file, which, at the close of SciTE will automatically save the current size and position of window.
[NewFind-MarkerDeleteAll] (Author: Dmitry Maslov)
New variable in properties files
find.mark.delete=1
If 1, then pressing the button "Mark all" removed any earlier bookmarks.
[output.caret] (Author: VladVRO)
New variables in properties files
output.caret.fore
output.caret.line.back
output.caret.line.back.alpha
Sets caret style of the output window.
[NewIcons] (Author: VladVRO)
New icons for the files associated with SciTE and for sessions files.
[AbbrevRefactoring] (Author: VladVRO)
Using of char '|' identical for Insert Abbreviation (Ctrl+Shift+R) and for Expand Abbreviation (Ctrl+B).
[VarAbbrev] (Authors: mimir, VladVRO)
It is possible to add user variables into list of abbreviation (abbrev).
- %SEL% - selected text
- %CLP% - text from clipboard
- %[var_name]% - value of internal variable SciTE (for example , CurrentSelection, FileNameExt, SciteDefaultHome etc.)
- %GUID% - unique GUID of new object (suggested by codewarlock1101)
For example, add that string into abbrev file:
<a+=<a href="%CLP%" title="|">%SEL%</a>
Copy string "http://scite.ruteam.ru/" to clipboard (Ctrl+C)
Type '<a+My Site' and select 'My Site'. Then pushing Ctrl+B - have got a completed construction:
<a href="http://scite.ruteam.ru/" title="|">My Site</a>
and caret have position of first meeting of '|'.
The same action: Type 'My Site' and select 'My Site'. Then press Ctrl+Shift+R and to choose "<a+" from a drop-down list.
New variable in properties files
abbrev.preserve.selection=1
allows to insert selected text without using %SEL% variable.
In this case selected text is inserted instead of last char '|'.
[abbrev.always.update] (Author: mimir)
If there is only one abbreviation file in use, without
abbrev.always.update=1
it will be renewed after Scite restart only.
[AbbrevExpandIncremental] (Author: VladVRO)
New variable in properties files
abbrev.expand.incremental=1
Changing expanding method to incremental for expand abbreviation by Ctrl+B, in other words new method to expand abbreviation is taking one char first, then two and so on.
[AbbrevMaxLength] (Author: VladVRO)
New variable in properties files
abbrev.maximum.length=[value]
Set value of length limit for expand abbreviation by Ctrl+B, in other words it is the maximum length of text for comparing with abbreviations set
update
[import] (Author: mimir, VladVRO)
Changed rules for import file in properties files. In first case trying to load file with name as is, if file not found then adding extension ".properties" and repeat trying to open file.
It is possible to use import instruction in *.abbrev files.
[selection.hide.on.deactivate] (Author: mozers)
The parameter selection.hide.on.deactivate=0 allows to not hide selection from the text when window SciTE loses focus.
[scite.userhome] (Authors: gansA, mozers, VladVRO)
New variable in properties files
scite.userhome let you assign path to directory $SciteUserHome for user data saving.
(SciTE.recent, SciTE.ses, SciTEUser.properties)
Possible to use in the path internal variables of SciTE, for instance:
scite.userhome=$(SciteDefaultHome)\home
[IncrementalSearch.AddHotkeys] (Author: Midas)
Add on "Incremental Search" (Ctrl+Alt+I) Hotkeys:
- Enter or F3 - Find Next
- Shift+Enter or Shift+F3 - Find Previous
[WarningMessage] (Author: VladVRO)
Now can to set up alert with warning message for each warning type:
warning.findwrapped.message=alert's text
warning.notfound.message=alert's text
warning.wrongfile.message=alert's text
warning.executeok.message=alert's text
warning.executeko.message=alert's text
warning.nootherbookmark.message=alert's text
update [AutoComplete] (Author: mimir, VladVRO)
Autocomplete function (Ctrl+I, Ctrl+Space) takes variants of end of a word not only from appropriate ".api" a file (as in original SciTE), but also from the edited text.
[oem2ansi] (Author: gansA)
Parameter output.code.page.oem2ansi=1 turn on console output text encoding from OEM to ANSI.
It let to edit script in win1251 codepage and see it output in console in dos866 codepage without switching codepages.
[caret] (Author: mimir)
Added possibility to customize the width and the color of cursor for every lexer individually, i.e. like this:
caret.fore.$(file.patterns.cpp)=#FF0000
caret.width.$(file.patterns.cpp)=3
It is not convenient when there are different colors and backgrounds for different languages but there is only one color for cursor.
[BetterCalltips] (Author: chupakabra)
New variable in properties files
calltip.lexer.automatic
calltip.*.automatic
Setting this option to 0 disables automatic calltip popup display but leaves user with possibility to invoke calltip manually. The * form is used if there is no lexer specific setting.
calltip.lexer.show.per.page
calltip.*.show.per.page
This option specifies number of definitions displayed per page in calltip window (default 1). Use arrow buttons to switch to next/previous page. The * form is used if there is no lexer specific setting.
calltip.lexer.word.wrap
calltip.*.word.wrap
This option enables word wrapping of calltip lines. Specify maximum number of characters allowed per line. Specify 0 to disable this feature (default). The * form is used if there is no lexer specific setting.
Calltip horizontal position is adjusted to maximize amount of information displayed. This is useful when cursor is located closely to right window border for example.
New Scintilla commands to support several highlight regions inside calltip window (SCI_CALLTIPADDHLT, SCI_CALLTIPCLEARHLT, SCI_CALLTIPUPDATEHLT).
new
[TextSizeMax for Dialog] (Author: dB6)
Increased buffer size for dialog box text conversions up to 1024.
Extensions
new
[ABAP] (Author: VladVRO)
Added new lexer for ABAP/4 language.
new
[EditorUnicodeMode] (Author: VladVRO)
Added new property editor.unicode.mode for editor unicode mode which has been assigned by editor and can be one from next states:
IDM_ENCODING_DEFAULT, IDM_ENCODING_UCS2BE, IDM_ENCODING_UCS2LE, IDM_ENCODING_UTF8, IDM_ENCODING_UCOOKIE.
[macro] (Author: VladVRO)
Support of record and play macro using LUA.
[OnMenuCommand] (Author: VladVRO)
Added new SciTE event - OnMenuCommand (msg, source)
msg - function id (SCI_constant)
source - input parameter of editor's internal function MenuCommand.
It can be equal to IDM_SRCWIN (350) - editor's window, or IDM_RUNWIN (351) - output window, or something else where the focus is.
[OnSendEditor] (Author: VladVRO)
Added new event to SciTE - OnSendEditor (msg, wp, lp)
Parameters the same as SendEditor.
msg - function id (SCI_constant)
wp and lp - input parameters, wp - numeric, lp - string. According to function they can be used or not.
OnSendEditor called for command that available for macro recording only and for SCI_SETREADONLY.
Example of letter case changing macro:
function OnSendEditor (msg)
if msg == SCI_UPPERCASE then
ChangeCase("U")
elseif msg == SCI_LOWERCASE then
ChangeCase("L")
end
end
new
[OnClick] (Author: Dmitry Maslov)
Added new event to SciTE OnClick(). Event arises from a single click on the mouse left button in the editing pane or the output pane.
Receives the state of key modifiers (Shift, Ctrl, Alt):
function OnClick(shift, ctrl, alt)
[OnDoubleClick] (Author: mimir, Dmitry Maslov)
Event OnDoubleClick() is expanded, now it is returned to the state of key modifiers (Shift, Ctrl, Alt):
function OnDoubleClick(shift, ctrl, alt)
[OnKey] (Author: Dmitry Maslov)
Function OnKey is expanded, now in it the pressed symbol is passed also:
function OnKey(key, shift, ctrl, alt, char)
new
[OnMouseButtonUp] (Author: VladVRO)
Added new event to SciTE OnMouseButtonUp(). Event arises from a mouse button up in the editing pane or the output pane.
Receives the state of Ctrl:
function OnMouseButtonUp(ctrl)
new
[MouseClickHandled] (Author: VladVRO)
Added new message SCI_SETMOUSECAPTURE to the Scintilla for change mouse cuptured state.
This message let to inform the Scintilla that mouse click handled.
Example: SendEditor(SCI_SETMOUSECAPTURE, 0)
And this message will be sent if OnClick() or OnDoubleClick() returns true.
[Perform] (Author: VladVRO)
In SciTE Lua Scripting Extension added new command
scite.Perform(actionList) - execute commands SciTE Director Interface
with actionList - one or several commands separated by a symbol of a new line.
new
[ReloadStartupScript] (Author: VladVRO)
In SciTE Lua Scripting Extension added new command
scite.ReloadStartupScript() - this function initializes Lua startup script reloading.
[GetLexerLanguage] (Author: Dmitry Maslov)
Added Scitilla message allowing to receive a name current lexers:
Now editor.LexerLanguage - allows both to set lexer, and to receive current
[GetAPIPath] (Author: dB6)
APIPath - new SciTE environment variable. Contains a meaning full path of the current api file.
[GetAbbrevPath] (Author: dB6)
AbbrevPath - new SciTE environment variable. Contains a meaning full path of the current abbrev file.
[AbbrevRefactoring] (Author: Dmitry Maslov)
In SciTE Lua Scripting Extension added new command
InsertAbbreviation(string)
where "string" - is a text, on a format similar to abbreviation, for example:
scite.InsertAbbreviation("<a href="|" title="">%SEL%</a>")
[os.run] (Author: mimir)
In SciTE Lua Scripting Extension added new command
os.run(Command, [WindowStyle], [WaitOnReturn])
which allows to set windows appearance of started external command and pause script execution for time of command execution and get return code.
[MsgBox] (Author: Midas, mimir)
In SciTE Lua Scripting Extension added new command:
- os.msgbox (Text, [Title], [Options]) - Message Box. Return select button.
[FileAttr] (Author: Midas)
In SciTE Lua Scripting Extension added new commands:
- os.getfileattr (FileName) - return File Attribute as number;
- os.setfileattr (FileName, FileAttr) - Set File Attribute.
[ParametersDialogFromLua] (Author: VladVRO)
In SciTE Lua Scripting Extension added new command for show "Parameters" dialog (Shift+F8)
scite.ShowParametersDialog(text)
text - short comment for window.
Return false if the user has refused (has pressed a Cancel or Escape) differently true.
Sample:
function Dialog()
props["1"]=props["CurrentSelection"]
props["2"]=props["SciteDefaultHome"]
if scite.ShowParametersDialog("Please set params") then
print ("1="..props["1"].."\n2="..props["2"].."\n3="..props["3"].."\n4="..props["4"])
else
print ("Cancel")
end
end
[FileAttr in PROPS] (Author: Midas)
Now accessible from scripts additional file properties
FileAttr, FileTime, FileDate.
[CalltipBreaks] (Author: Mitchell Foral)
Long bubble helps can be carried on the next line (by adding symbol \n at appropriate line in api-file)
[Euphoria] (Author: Midas)
Add new lexer Euphoria
[C_Word] (Author: mimir)
Added 3 new classes for LexCpp's keywords (i.e. now you can set up to 4 additional vocabularies with different highlight)
[PropsKeysSets] (Author: VladVRO)
Added 4 classes for LexProps's keywords (i.e. now you can set up to 4 additional vocabularies with different highlight)
And words can contain symbol ~, meaning a random set of characters. For example block.start.~ or braces.~.style
[PropsKeywords] (Author: VladVRO)
Added colorizing for "import" and "if" keywords in properties file.
[GetApplicationProps] (Author: VladVRO)
New function SciTEBase::GetProps() (for developers) allows to get access to properties of the editor in any place of a code of the editor.
[Zoom] (Author: Dmitry Maslov)
Now OnSendEditor can trace event SCI_SETZOOM arising at change of the size of a font.
Bug fix
new
[PropsColouriseFix] (Author: VladVRO)
Fixed coloring of syntax in properties files for long lines (more then 1024 chars) and for lines with division of words.
new
[LuaLexerImprovement] (Author: VladVRO)
Changed lexer for language Lua.
Simbols ":" and "." processed as separator for object now. You can setup lexer keywords as string.sub or editor:append as before and you can setup object function or property as :GetText or .Cursor now.
new
[GoMessageImprovement] (Author: VladVRO)
Made the editor window focused after uses double-click in console on message with file name and line number.
For implementation used [OnMouseButtonUp] improvement.
[English_KeyCode] (Author: Dmitry Maslov)
Bug fixed at which keyboard shortcut ceased to work after switching keyboard layout. (details)
[InputErr] (Author: mimir)
Bug fixed in deadlock of SciTE on using command.input.
If user forget to select text before running script it cause deadlock.
[SelectionErr] (Author: mimir)
Bug fixed in text output on command.input and $(CurrentSelection) in UTF-8 code page only.
It prevent from transfer Russian text into external script or program.
[StyleDefault] (Authors: VladVRO, Dmitry Maslov)
Are removed default values of symbols color (black) and a background (white), that allows to not set them obviously in files of adjustment in all styles for set of a corresponding background at export of a file.
If the style.*.32 do not raised characters and the background color, these parameters are collected from your Windows, i.e. equal system Window Text/Background.
[LowerUpperCase] (Author: Midas, VladVRO)
Correct working with national characters
- for Make Lower / Upper Case,
- for Search without match case,
- for Search with Regular expression
[FindInFiles] (Author: dB6)
Selected text inserted into FindInFiles dialog solely in the UTF-8, thus Russian letter turned out unreadable.
[FileReaderUnlimitedLen] (Author: VladVRO)
Removed the restriction on the length of lines in the internal Find in Files. Earlier in long lines only to find worked 1,001 characters, the rest ignored.
[AbbrevFixCaretPos] (Author: VladVRO)
Fixed positioning of caret in insert abbreviation action.
Bug was in case when abbreviation body has one simbol '|' and in action was not selection text.
[no_wornings] (Author: Dmitry Maslov)
Added compatibility with the compiler Visual C++ 6.0
Eliminated some of warnings in the compilation of Visual C++ 6.0
warning C4702: unreachable code
[SQLcase] (Author: mimir)
The word "case" added into LexSQL to start folding
On the found inaccuracies in the description I ask to report to mozers(@)mail.ru